You are viewing an old version of this page. View the current version.

Compare with Current View Page History

Version 1 Next »

JADE can write a separate log file for each transfer, both when the transfer is started from the console or the chrontab.

1. To specify the log file name

The log file to be used for a particular transfer is defined in the log4j.properties file.

The log4j.properties file can be located in the same folder as the profile.ini file. The parameter defining the location of log4j does not have to be explicitly set in the profil.

A typical log4j.properties file looks like:

log4j.appender.file.layout=org.apache.log4j.PatternLayout
log4j.appender.file.layout.ConversionPattern=%p %t %c - %m%n
log4j.rootCategory=debug, stdout, file
log4j.appender.stdout=org.apache.log4j.ConsoleAppender
log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
log4j.appender.stdout.layout.ConversionPattern=%5p [%t] (%F:%L) - %m%n
# Configuration of the log file
log4j.appender.file=org.apache.log4j.RollingFileAppender
log4j.appender.file.File=/var/opt/sosftp/log/sosdex.log

log4j.appender.file.MaxFileSize=10000KB
# Keep a backup copy 
log4j.appender.file.MaxBackupIndex=10

log4j.appender.file.layout=org.apache.log4j.PatternLayout
log4j.appender.file.layout.ConversionPattern=%p %t %c - %m%n

Note that:

  • the default value for stdout is set by the operating system and
  • the default location for the jade-log is:
    • /var/opt/sosftp/log/sosdex.log

JADE will overwrite the default file name with values set in the log_filename parameters.

Note also that:

  • the working directory for chron is not ./jade/bin, where the log4j file is to be found.
  • this means that when starting chron:
    • use cd to navigate to the home directory
    • start jade.sh
    • start runner-script.sh, which switches the working directory to the bin directory
    • the name of the log4j file can be set with a parameter.

A typical profile would look like:

[FTP_123]
protocol = ftps
#port = 49159
host = dedcw28ftp01.de.int.kaufland
user = DE\ppmftp
password = ***********
log4j_Property_FileName = /opt/sosftp/sosdex_client.1.3.12.2032/profile/log4j.properties


[TEST_FTP_REC_new]
include = FTP_123
port = 49157
log_filename = /var/opt/sosftp/log/my_logfile_name.log
#verbose = 9
history = /var/opt/sosftp/log/history_TEST_FTP_REC_new.csv
file_spec = .*\.txt
force_files = false
remove_files = true
transactional = true
atomic_suffix = .tmp
local_dir = /var/mercator_env/qde/data/input/tisoware/
remote_dir = ./

2. To specify the log file name for each transfer

Work In Progress ....

  • No labels