This file contains some parameter settings that are always read when the AFD is started. The following table shows and describes what parameters can be set and which programs must be restarted to activate the new value:
Parameter | Description | Default | Restart |
---|---|---|---|
AFD_TCP_PORT [<interface ip>:]<port number> | The TCP port number at which the process afdd will listen and wait for remote requests. If that port is currently in use by another program it will add one and see if that works so long until it finds a free port. Note you will only be able to pick a port that is not in the dynamic port range. IANA suggests this port range to be 49152 to 65535. On linux systems this usually is 32768 to 61000. On linux AFD will determine this value by reading /proc/sys/net/ipv4/ip_local_port_range. Optionally you can specify the interface ip where AFDD should listen. If this is not specified it will listen on all interfaces the system has. Unfortunately you can only specify one interface ip. NOTE: If this option is not set the afdd process will NOT start. | 4444 | afdd |
AFD_TCP_LOGS <allowed log flag> | The logs that may be requested from the given AFD_TCP_PORT. If
this is defined, then it means for all hosts that connect to this
port. With the TRUSTED_REMOTE_IP it can be restricted to specific
host(s). The value given is an integer bit mask, with the
following meaning:
5 (16) - System Log 6 (32) - Receive Log 7 (64) - Transfer Log 8 (128) - Transfer Debug Log 9 (256) - Input Log 10 (512) - Production Log 11 (1024) - Output Log 12 (2048) - Delete Log 15 (16384) - Event Log 16 (32768) - Distribution LogJust add the values in brackets to set the wanted logs. |
0 | afdd |
TRUSTED_REMOTE_IP <IP-number> [<allowed log flag>] | Trusted IP-number that may connect to AFD_TCP_PORT. To enter more then one IP-number you must have the identifier TRUSTED_REMOTE_IP on a new line for each number. Wildcards may also be used when specifying the IP-number. Optionally you can set the AFD_TCP_LOGS flag behind the IP number. If TRUSTED_REMOTE_IP is not set, all hosts may connect. | None | afdd |
MAX_AFDD_CONNECTIONS | The number of hosts that may connect to the afdd process. | 5 | afdd |
AFDD_PRIORITY | Scheduling priority that the process afdd, used to monitor the AFD with afd_mon, should run. Since it is just used for monitoring it does not need a high priority. See man nice for the meaning of the values, mostly it goes from 19 (least favorable) to -20 (most favorable scheduling). You can only set negative values here if AFD runs under root, which is not recommended. | Not set | afdd |
AFD_STAT_PRIORITY | Scheduling priority that the process afd_stat, used to collect statistics like number of files and bytes send and/or retrieved, number of connections and number of errors. This also does not need a high priority. | Not set | afd_stat |
AMG_PRIORITY | Scheduling priority that the process amg. Since this process scans the local directories it is important. | Not set | amg |
ARCHIVE_WATCH_PRIORITY | Scheduling priority that the process archive_watch. If the archive is big (has lots of small files), this process can strain the disk subsystem considerably, for this reason it is a good idea to have this process run at a low as possible priority. | Not set | archive_watch |
EXEC_BASE_PRIORITY | Scheduling priority that the process gets when AMG forks via the exec option or FD via the pexec option. Note that on most implementation it is required that the executable file dir_check and fd need to belong to root and need to have the sticky bit set. In most cases it is not needed to set this value. | Not set | amg, fd |
FD_PRIORITY | Scheduling priority that the process fd. Since this process distributes the data and scans remote directories it is important. | Not set | fd |
INIT_AFD_PRIORITY | Scheduling priority that the process init_afd. This process starts all other process of AFD and they will inherit the priority given to init_afd. | Not set | init_afd |
SHOW_LOG_PRIORITY | Scheduling priority that the graphical dialogs showing log data: show_log, show_elog, show_ilog, show_olog and show_dlog. Since these process are non critical and they can produce a lot of IO and CPU load they should get a low priority. | Not set | show_log, show_elog, show_ilog, show_olog, show_dlog |
ADD_AFD_PRIORITY | If set to YES the AFD priority from DIR_CONFIG is added to the scheduling priority. Process effected by this are all those started via the exec and pexec option and all sf_xxx and gf_xxx process. This value is added to any of the above value. For example if FD_PRIORITY set to 5 and an AFD priority of 9 is set for a job the resulting sf_xxx and/or gf_xxx process will have a priority of 14. If there is a pexec option set and EXEC_BASE_PRIORITY is 2 then the resulting priority of the executing process would be 11. | NO | amg, fd |
MAX_NICE_VALUE | Usually it is not needed to set this value, but it can be used to increase or decrease the maximum nice value to what your system does support. | 0 | amg, fd |
MIN_NICE_VALUE | Usually it is not needed to set this value, but it can be used to increase or decrease the minimum nice value to what your system does support. | 19 | amg, fd |
MAX_SHUTDOWN_TIME | Time in 0.1 seconds given for AFD to shutdown it's process before it terminates. Note, it will not terminate exec jobs started via the exec option. When compiled with systemd this will take care of those process. | 600 | amg |
ALDA_DAEMON | Start a process that monitors the given log data and log them in the given format. For the parameters that need to set, see the documentation of alda. | None | None |
IN_GLOBAL_FILESYSTEM | If AFD is running in a global filesystem (NFS, GFS, etc) set this option to YES. Then data from memory mapped files will be synced to disk more frequently. This is only necessary when you try to monitor or use AFD from another host that has this filesystem mounted. | NO | init_afd |
EXTRA_WORK_DIR | If there are multiple filesystems from which AFD must distribute
files set this option for each extra filesystem. Otherwise AFD
will always copy from one filesystem to the other. Only one extra
filesystem can set for the key word EXTRA_WORK_DIR, so to specify
multiple filesystems you must use it multiple times. If you have
an extra filesystem in /ram and /drbd, you can set this as follows:
EXTRA_WORK_DIR /drbd/afd EXTRA_WORK_DIR /ram/afdAFD will then create its extra directories in /drbd/afd and /ram/afd (files, archive, etc). |
Not set | amg, fd |
DIR_CONFIG_NAME | The file from where AFD will read it's configuration. This
option may be used more then once, thus making it possible
to read from multiple configuration files. If the name specified
does not contain the absolute path, it will try to locate the
given file in $AFD_WORK_DIR/etc. Some examples:
DIR_CONFIG_NAME DIR_CONFIG DIR_CONFIG_NAME DIR_CONFIG.radar DIR_CONFIG_NAME /home/afd/oper/etc/DIR_CONFIG_OTHER DIR_CONFIG_NAME /home/afd/oper/etc/configs/*.dir_configNote the last example is with wildcard. |
$AFD_WORK_DIR/etc/DIR_CONFIG | amg |
RENAME_RULE_NAME | Via this options it is possible to specify the file name from where the AFD reads all the rules on how to rename files. This option may be used more then once, thus making it possible to read from multiple rename rule files. If the name specified does not contain the absolute path, it will try to locate the given file in $AFD_WORK_DIR/etc. | $AFD_WORK_DIR/etc/rename.rule | amg |
MAX_NO_OF_DIR_CHECKS | This is the number of times dir_check my fork itself to copy or exec some command. | 20 | amg |
DEFAULT_INOTIFY_FLAG | This flag determines the default inotify flag for all directories.
It can be overruled with the directory option inotify in the
DIR_CONFIG. The value given is an integer bit mask, with the
following meaning:
1 (1) - File moved into or renamed in directory. 2 (2) - File that is closed after being written to. 3 (4) - File created/linked.If set to zero, no inotify is used and directories are scanned. |
0 | amg |
DEFAULT_NO_PARALLEL_JOBS | The default number of parallel process that may be forked for sending the data. This is the default value set by AMG when this destination is new. | 3 | amg |
DEFAULT_MAX_ERRORS | The default number of errors before the host becomes red in afd_ctrl dialog. This is the default value set by AMG when this destination is new. | 10 | amg |
DEFAULT_RETRY_INTERVAL | The default interval in seconds at which AFD tries to resend data after it got disconnected due to an error. This is the default value set by AMG when this destination is new. | 300 | amg |
DEFAULT_TRANSFER_BLOCKSIZE | The default transfer blocksize in byte that the data is transmitted to the destination. The value should be divisible by 256. The value set here will be the default value set by AMG when this destination is new. | 4096 | amg |
DEFAULT_SUCCESSFUL_RETRIES | The default number of successful retries after which it tries to contact the primary host again. This is the default value set by AMG when this destination is new. | 10 | amg |
DEFAULT_TRANSFER_TIMEOUT | The default time in seconds after which a connection is timed out. This is the default value set by AMG when this destination is new. | 120 | amg |
DEFAULT_ERROR_OFFLINE | When set to YES all errors and warnings to this destination will be set offline, ie. this host will not turn red in afd_ctrl dialog. The value set here will be the default value set by AMG when this destination is new. | NO | amg |
MAX_PROCESS_PER_DIR | The maximum number of process that may be forked for one directory. | 10 | amg |
IGNORE_FIRST_ERRORS | On big systems with many connections it can be disturbing if errors are always shown. Some error situation is only of short duration. This parameter when set, marks the first number of errors/warnings as offline. So they will not be by default visible in logs and will not show up in the error history. | 0 | amg |
AMG_DIR_RESCAN_TIME | The rescan time of the local user directories in the DIR_CONFIG file. This does not effect the rescan time of remote directories, which is set with REMOTE_FILE_CHECK_INTERVAL. Don't pick a small value here if your system shows high system load when working with files or directories (eg. fault tolerant systems). This is also the interval time that the AMG checks if the DIR_CONFIG or HOST_CONFIG file have been changed. The unit is second. | 5 | amg |
DEFAULT_DIR_INFO_TIME | The time when AMG will send an information message in receive log that no data has been received in the specified directory. This value will be overridden by info time value from DIR_CONFIG if set. The unit is second. | 0 | amg |
DEFAULT_DIR_WARN_TIME | The time when AMG will warn in receive log that no data has been received in the specified directory. This value will be overridden by warn time value from DIR_CONFIG if set. The unit is second. | 0 | amg |
DEFAULT_DELETE_FILES_FLAG | What to do with files that have reached a certain age but cannot be transmitted because either there is no rule (Unknown), they are being queued by AFD (Queued), they are old locked files (Locked), they are old locked files on a remote host (Rlocked) or old locked files in the $AFD_WORK_DIR/files/incoming directory (Ilocked). By specifying one of the above those files will be automatically removed by AFD when DEFAULT_OLD_FILE_TIME value has been reached. To specify more then one type, just add the next with a space or comma as a separator sign and the whole string must be placed in ". | Not set | amg |
DEFAULT_OLD_FILE_TIME | When to delete Unknown, Queued, Locked or Rlocked files from one of AFD's input directories. The value is in hours. | 24 | amg |
REMOVE_UNUSED_HOSTS | By default AFD will never delete a host from HOST_CONFIG if the host is not found in DIR_CONFIG. With this option set, those hosts will be deleted. | Not set | amg |
DELETE_STALE_ERROR_JOBS | When a job is removed from DIR_CONFIG but FD has still files queued and these jobs produce errors (ie. they cannot be send, due to whatever reason), AFD will by default not delete these files. By setting this to YES, such jobs will be removed. | NO | fd |
MAX_CONNECTIONS | The maximum number of simultaneous connections/transfers that the AFD allows. Don't set this value to high since some environments allow only a limited number of process per user. | 50 | fd |
REMOTE_FILE_CHECK_INTERVAL | The interval in second that the FD rescans remote directories for files. Do not set this value to low. | 60 | fd |
CREATE_SOURCE_DIR | If this is set to NO, the source directories will not be created if they do not exist. When set to YES, these will be created if AFD does have the permission to do so. Only local directories will be created. | YES | amg |
CREATE_REMOTE_SOURCE_DIR | If this is set to NO, the remote source directories will not be created if they do not exist. When set to YES or you specify the mode, these will be created if AFD does have the permission to do so. Only remote directories will be created. | NO | fd |
CREATE_SOURCE_DIR_MODE | The permission of the source directories that found in the DIR_CONFIG and created by AMG/FD if they are not there. | 775 | amg/fd |
CREATE_TARGET_DIR | If this is set to YES or a mode is set and the target directory does not exist it will be created automatically, unless the option do not create target dir is set. If it is set to NO (default) it will not create the target directory. With the option create target dir this can be overridden. | NO | fd |
CREATE_TARGET_DIR_MODE | The permission of the target directories that is found in the DIR_CONFIG and created by FD if they are not there. | 775 | fd |
DEFAULT_AGE_LIMIT | Files older then the given seconds will be deleted by default, unless the age-limit is specified under options, then this value will be taken. A value of 0 will disable this, it is however still possible to set this value with the age-limit option in DIR_CONFIG. | 0 | fd |
DEFAULT_AGEING | Process FD has a job queue where jobs can age when the transmission is not successful. How quickly a job ages is determined by the following value. 9 is very quick ageing and will put the job almost to the end on first error encountered. A value of 0 will disable ageing. | 5 | amg, fd |
EXEC_TIMEOUT | When setting one of the exec options ( exec or pexec), the default is to let those process run as long as those process want to run, ie. there is no restriction in time. This default can be changed to the value specified here in seconds. If the time is up the process is killed. | 0 | amg/fd |
DEFAULT_HTTP_PROXY | The default HTTP proxy where HTTP requests are send to. This can be an IP number or a hostname. Optionally one can specify the default port using the following syntax: <server name>:<port> | Not set | fd |
DEFAULT_SMTP_SERVER | The default SMTP server where mails are to be send to. This can be an IP number or a hostname. Optionally one can specify the default port using the following syntax: <server name>:<port> | localhost:25 | fd |
DEFAULT_PRINT_SMTP_SERVER | The default SMTP server where mails are to be send to from the print dialog (show_ilog, show_olog, show_dlog, show_elog and show_queue ). This can be an IP number or a hostname. Optionally one can specify the default port using the following syntax: <server name>:<port> | localhost:25 | dialogs |
DEFAULT_SMTP_FROM | The default what will be put into the from line, if the from option is not set under [options]. If not set it will take the user- and hostname from the current system where AFD is running. One can also insert the current hostname, for example user.%H@ducktown.de would resolve to user.node1@ducktown.de if the hostname is node1. To insert the full hostname one can use %h. | <current user>@<hostname> | fd |
DEFAULT_SMTP_REPLY_TO | The default what will be put into the reply-to line, if the reply-to option is not set under [options]. If not set it will not send the reply-to line. Here too one can insert the current hostname either with %H or %h as described in DEFAULT_SMTP_FROM above. | Not set | fd |
DEFAULT_CHARSET | The default charset used when sending mails. Note, AFD will
NOT check if the specified charset is a valid one. Possible
values could be:
utf-8 --> UTF-8 iso-8859-1 --> Latin 1; Western European Languages iso-8859-2 --> Latin 2; Slavic/Central European Languages iso-8859-3 --> Latin 3; Esperanto, Galician, Maltese, Turkish iso-8859-4 --> Latin 4; Estonian, Latvian, Lithuanian iso-8859-5 --> Cyrillic iso-8859-6 --> Arabic iso-8859-7 --> Modern Greek iso-8859-8 --> Hebrew iso-8859-9 --> Latin 5; Turkish iso-8859-14 --> Latin 8; Celtic iso-8859-15 --> Latin 9; Western European Languages with Euro |
Not set | fd |
DEFAULT_GROUP_MAIL_DOMAIN | When sending the same mail to multiple users and mail group functionality of AFD, by default it just sends the group name. To make it a fully qualified address one can set here the domain. | Not set | fd |
MAX_COPIED_FILES | The maximum number of files that are copied before they are send to the FD. This value is set so that the AFD starts sending files as soon as possible even when there are thousands of files waiting in the source directory to be send. Otherwise it might take to long to process all the files at once and time is lost that could be used to transmit data. | 100 | amg |
MAX_COPIED_FILE_SIZE | The maximum size in Kilobytes that are copied before they are send to the FD. | 100 MB | amg |
FORCE_REREAD_INTERVAL | Here one can set the minimal interval in seconds at which all source directories must be scanned. This can be useful on systems that do not update the directory modification time reliably (for example NFS when time of client and server is out of sync). Setting this will generate a higher system load, since directories will be scanned more often. | 0 (Disabled) | amg |
ONE_DIR_COPY_TIMEOUT | When AMG has collected MAX_COPIED_FILES, it will try to continue to copy from this directory until it reaches the timeout set by this option in seconds. | 5 | amg |
FULL_SCAN_TIMEOUT | The timeout for scanning all directories. If set to 0 this is disabled. When this is set it will only take effect if during a scan there are directories which still have files to be distributed but could not because of MAX_COPIED_FILES or some other limits. If FULL_SCAN_TIMEOUT has not been reached, it will try to continue with the full directories until FULL_SCAN_TIMEOUT is reached. | 0 | amg |
DIR_CHECK_TIMEOUT | When the administrator has marked one or more directories as important (with '*'), this is the minimum time in second that these directories have to wait during one scan of all directories. | 30 | amg |
ADDITIONAL_LOCKED_FILES | Allows the administrator to set a default list of locked files
that gets added to each [files] section in DIR_CONFIG. Each element
must be separated with a | (pipe) and may start with a !. If the !
(not sign) is not set it will automatically insert it. If
one sets the following in AFD_CONFIG:
ADDITIONAL_LOCKED_FILES *.tmp|*.temp|*.lockThen each [files] section in DIR_CONFIG will always start as follows: [files] !*.tmp !*.temp !*.lockNote that this is not efficient! Rather try to get the other applications to lock with a leading dot. |
Not set | amg |
GF_FORCE_DISCONNECT | If keep connected is set, it can be that the process never disconnects because there is a constant flow of data. This can be a problem if there are changes in the filesystem underneath. Depending on the implementation this can go by unnoticed by the connected process. A good example is if the directory we are in is a soft link and this is changed, then the for example FTP session will not notice this. It will then read from a directory different where the current symbolic link points to. The value is in seconds. | 0 (Never disconnect) | fd |
SF_FORCE_DISCONNECT | See description above. This is the same the only difference being that this is for sending files. | 0 (Never disconnect) | fd |
MAX_SYSTEM_LOG_FILES | The number of old system logfiles that AFD keeps before they are deleted. | 4 | |
MAX_SYS_LOGFILE_SIZE | The size in bytes before the system logfile is rotated. | 2097152 | system_log |
MAX_RECEIVE_LOG_FILES | The number of old receive logfiles that AFD keeps before they are deleted. | 7 | |
MAX_TRANSFER_LOG_FILES | The number of old transfer logfiles that AFD keeps before they are deleted. | 7 | |
MAX_TRANS_DB_LOG_FILES | The number of old transfer debug logfiles that AFD keeps before they are deleted. | 3 | |
MAX_TRANS_DB_LOGFILE_SIZE | The size in bytes before the transfer debug logfile is rotated. | 8388608 | trans_db_log |
MAX_EVENT_LOG_FILES | The number of old event logfiles that AFD keeps before they are deleted. | 5 | |
MAX_EVE_LOGFILE_SIZE | The size in bytes before the event logfile is rotated. | 10485760 | event_log |
MAX_MON_SYS_LOG_FILES | The number of old monitor system logfiles that AFD keeps before they are deleted. | 4 | |
MAX_MON_SYS_LOGFILE_SIZE | The size in bytes before the monitor system logfile is rotated. | 2097152 | mon_sys_log |
MAX_MON_LOG_FILES | The number of old monitor logfiles that AFD keeps before they are deleted. | 14 | |
MAX_INPUT_LOG_FILES | The number of old input logfiles that AFD keeps before they are deleted. | 7 | |
MAX_DISTRIBUTION_LOG_FILES | The number of old distribution logfiles that AFD keeps before they are deleted. | 7 | |
MAX_PRODUCTION_LOG_FILES | The number of old production logfiles that AFD keeps before they are deleted. | 7 | |
MAX_OUTPUT_LOG_FILES | The number of old output logfiles that AFD keeps before they are deleted. | 7 | |
MAX_DELETE_LOG_FILES | The number of old delete logfiles that AFD keeps before they are deleted. | 7 | |
DEFAULT_PRINTER_CMD | With this option it is possible to set the printer command for your specific environment. | "lpr -P" | |
DEFAULT_PRINTER_NAME | This option specifies the default printer for your system. | ||
PING_CMD | Full path of the ping command plus any options. If there are options you must put the full command in ". The hostname will be added to the end of the command. | afd_ctrl | |
TRACEROUTE_CMD | Full path of the traceroute command plus any options. The hostname will be added to the end of the command. | afd_ctrl | |
VIEW_DATA_PROG | Program to view data of show_olog and show_queue dialog. This may
be used multiple times in AFD_CONFIG to configure different
programs for different file types (patterns). The optional
parameter --with-show_cmd can be used for programs that just
write to STDOUT and/or STDERR. The syntax is as follows:
VIEW_DATA_PROG [--with-show_cmd] <progname> <pattern> <progname> - Is the program name of the program to be called. If parameters need to be added, they must be put in ". The filename to be shown, can be added with %s. <pattern> - The filename pattern that applies for the above program name. Multiple patterns must be separated with a pipe sign (|). |
show_olog, show_queue | |
VIEW_DATA_NO_FILTER_PROG | In dialog show_olog it is possible to set the view mode. The default
is set to an internal program showing the content of the file in hex
view. With VIEW_DATA_NO_FILTER_PROG one can specify another program.
It is possible to specify multiple VIEW_DATA_NO_FILTER_PROG programs.
Note the first value is always the alias name of the program name that
is shown in show_olog. This may only be 8 characters long. With the
option --with-show_cmd one can show the output of programs that just
write to STDOUT and/or STDERR. here some example entries:
VIEW_DATA_NO_FILTER_PROG XV /usr/bin/xv VIEW_DATA_NO_FILTER_PROG Xpdf xpdf VIEW_DATA_NO_FILTER_PROG od --with-show_cmd "od -A x -t x1z -v" VIEW_DATA_NO_FILTER_PROG bufr --with-show_cmd "bufrtool -d -t ~/afd/usr/tables_v2 -i %s -o - " |
show_olog | |
FAKE_USER <fake user name> | This option allows the administrator to allow certain users
to take up another identity, even if they do not exist on the
system. This user will then be used to look up the permissions
in the afd.users file. So if you for
example give operators limited permission and do not want to
create a new user, you can do the following:
FAKE_USER afd->operatorIf the user afd enters the following command: afd_ctrl -u operatorthe afd_ctrl dialog will come up with the permissions of operator. More fake users can be added with a comma as separator: FAKE_USER afd->operator,afd->donaldThe list may not be longer then 1023 bytes. |
When one of the above values is changed the appropriate process must be restarted.
Copyright © 1999 - 2024 by H.Kiehl Holger.Kiehl@dwd.de Last updated: 09.04.2024 |
Index | Home |