Дерево страниц

Сравнение версий

Ключ

  • Эта строка добавлена.
  • Эта строка удалена.
  • Изменено форматирование.

...

Sv translation
languageen

The smtpd.conf configuration file:

ContentDescription
{
 
    "Logging": {...},
see General section Logging
    "NookDir": "/opt/iw/tm5", 

 

In this section, the module working directory is specified. By default – /opt/iw/tm5.

"UnsafeSignalHandlers":false,
Unhandled signals support. Disabled by default (false). Once true is set, it is allowed to use unsafe handlers in code (e.g. SIGSEVG). Adding, enabling/disabling this parameter is not recommended without consultation with developers.
    "DebugBreak": false, 
If SIGTRAP should be sent (SIGBREAK to Windows) while any exception handling. Used for debugging purposes.
    "SMTPD": {
Iw_smtpd daemon settings section.
        "Domain": "smtp.company.com", 
Full domain name of hosting SMTP-server, used for identity inside mail protocol. It is recommended to use TM server name, where iw_smtpd process is running.
  "EnablePrivSock": false, 
Using privileged socket mechanism (privsock) to receive capability marks (used on OS Astra Linux version 1.6 and later ones) . Default value - false.
        "MaxThreads": 8, 

Maximum number of streams to perform iw_smtpd parallel process. The default value is 8. Strems number growing will increase process performance, but memory usage will also grow.

        "MaxMsgSize": 104857600, 
E-mail maximum size (bytes). Default value is - 104857600
        "ListenPort": 2025, 
Server port, where the listening process is running. It is set during the installation.
        "ListenAddr": "0.0.0.0"
Server network interface address, where the listening process is running. It is set during the installation.
    }
 
}
 

The iw_smtpd.service unit file:

CodeDescription

[Unit]

A section where the daemon metadata is determined and interaction settings with other daemons are specified
Description=InfoWatch Traffic Monitor SMTP

The daemon name

After=network-online.service iwtm-consul.service Daemons that will be started before the current one
  
[Service]A section where the daemon start settings are specified

Type=simple

Daemon start type. simple - the daemon is started and goes into standby on the console

PermissionsStartOnly=true

Running commands from ExecStartPre under root

ExecStartPre=/bin/bash /opt/iw/tm5/bin/check_coredumps.sh -d iw_smtpd

The full path and arguments of the command that should be executed before the main process is started

ExecStart=/opt/iw/tm5/bin/iw_smtpd -p /opt/iw/tm5/etc

The full path and arguments of the command that should be executed before starting the daemon. The command is run under user specified in the User field

ExecStop=/bin/kill -s SIGQUIT $MAINPID

A command to stop the daemon. If the command is not specified, the process will be killed once the daemon is stopped. The command is run under user specified in the User field

ExecReload=/bin/kill -s SIGHUP $MAINPID

A command that reloads the daemon configuration if it is available. The command is run under user specified in the User field

Restart=on-failure

A command that restarts the daemon when it stops or crashes. The on-failure value indicates that the daemon will be restarted if it has stopped with a non-zero return code or was ended by signal (kill <daemon_pid>)

RestartSec=5

A timeout before attempting to restart the daemon

RestartPreventExitStatus=SIGKILL

A command that forcibly ends the daemon operation

TimeoutStopSec=0

The time during which the system waits for the signal to stop before marking the process as unavailable or terminated

User=iwtm

The name of the user under whose account the daemon is started

Group=iwtm

Name of the user group

LimitNOFILE=32768

The maximum number of open files

LimitFSIZE=infinity

The maximum size of a file (KB). The infinity value means that the size is unlimited

LimitNPROC=65536

The maximum number of processes

LimitCORE=infinity

Limit for core dump size (KB)

LimitMEMLOCK=infinity

The maximum size of memory locked address space (KB)

AmbientCapabilities=PARSEC_CAP_PRIV_SOCK

A privilege for creating a privileged socket and changing its mandatory label. A privileged socket enables network operation ignoring the mandatory policy
AmbientCapabilities=CAP_NET_BIND_SERVICEA privilege that enables binding a socket to privileged ports (port numbers lower than 1024).
  
  

[Install]

Defines the behavior of a daemon when it is enabled/disabled

WantedBy=multi-user.target

Start the daemon when the system is loaded in multi-user mode