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

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

Ключ

  • Эта строка добавлена.
  • Эта строка удалена.
  • Изменено форматирование.
Комментарий: Published by Scroll Versions from space RED and version 7.10
Sv translation
languageru

Файл конфигурации bookworm.conf

Scroll Table Layout
widths40%, 60%

        "FormatCompendium   поддерживаемых форматов.
СодержимоеОписание
{
 
    "Logging": {...}

см. Общая секция Logging

    "ThriftServers": {...}

см. Общая секция ThriftServers

    "NookDir": "/opt/iw/tm5", 

В секции указывается рабочий каталог модуля. По умолчанию – /opt/iw/tm5.

    "DebugBreak": false, 

Посылать ли SIGTRAP (SIGBREAK на Windows) при обработке любого исключения. Служит для отладки

    "UnsafeSignalHandlers":false,

Поддержка работы с необрабатываемыми сигналами. По умолчанию выключена (false). При установке значения true позволяется устанавливать в коде обработчики "небезопасных" сигналов (например, SIGSEVG). Добавлять, включать/выключать данную настройку не рекомендуется без предварительной консультации с разработчиками.

    "Discovery": {...},

см. Общая секция Discovery

    "MergeDetector": {
Конфигурация детектора склейки
        "CFBFormats": {
Поиск сигнатур форматов
           "XMLPath": "mergedetector/cfb_formats.xml",
Путь к справочнику
           "XSDPath": "mergedetector/cfb_formats.xsd"
Путь к XSD-схеме для валидации
         },
 

         "EOFFormats": {
Сравнение размера файла с данными из CFB заголовка (только для форматов, основанных на MS CFB
           "XMLPath": "mergedetector/eof_formats.xml",
Путь к справочнику
           "XSDPath": "mergedetector/eof_formats.xsd"
Путь к XSD-схеме для валидации
         },
 

         "SizeFormats": {
Сравнение размера файла со значением, записанным в известном месте (для разных форматов, имеющих поле с размером). Применимо также к форматам, состоящим из серии блоков с записанным размером.
            "XMLPath": "mergedetector/size_formats.xml",
Путь к справочнику
            "XSDPath": "mergedetector/size_formats.xsd"
Путь к XSD-схеме для валидации
     },
 

    "Compendiums": {

Список путей до справочников

        "OCRCompendium": {

Справочник, содержащий информацию о том, выполнять ли OCR-извлечение для конкретного сервиса / типа объектов / протокола.

"BaseXMLPath
             "XMLPath":  "config-perm/bookworm/ocr.xml",

Путь до базового OCR-справочника. Справочник переписывается при обновлении RPM-пакетов.

             "CustomNodeXMLPath": [],

Список кастомных OCR-справочников для конкретных нод. Самый высокий приоритет правил.

             "CustomXMLPath":  "config-perm/bookworm/ocr-custom.xml",

Путь до кастомного OCR-справочника с опциями. Правила, описанные здесь, имеют более высокий приоритет, чем соответствующие в BaseXMLPath. Также этот справочник не затирается при обновлении RPM.

 
"XSDPath
            "XSDPath": "compendiums/ocr.xsd"

Путь к XSD-схеме для валидации OCR-справочников.

},
 

        "ErrorCompendium": { 

Справочник локализованных ошибок обработки.

              "XMLPath": "config-perm/bookworm/errors.xml",

Путь к справочнику.

              "XSDPath": "compendiums/errors.xsd"

Путь к XSD-схеме для валидации.

  },
 

        "ActionCompendium": { 

Справочник связанных с перехватываемыми событиями действий. Поддерживает локализацию.

              "XMLPath": "config/bookworm/actions.xml",

Путь к справочнику. "XSDPath":

              "XSDPath": "compendiums/actions.xsd"

Путь к XSD-схеме для валидации.

 },
 
 
        "AntigarbageCompendium":
 {
 

Справочник

образцов событий для предотвращения ошибочного удаления или удаления их как мусорного трафика. 

              "CustomXMLPathXMLPath": "config-perm/bookworm/formats_customantigarbage.xml",

Путь

до пользовательского xml-файла с настройками

к справочнику.

              "CustomizationXMLPathXSDPath": "configcompendiums/errors.xsd"

Путь к XSD-схеме для валидации.

}, 

        "FormatCompendium": { 

Справочник поддерживаемых форматов.

            "CustomXMLPath": "config-perm/bookworm/formats_customizationcustom.xml",
Путь до пользовательского xml-файла с кастомизацией настроек;настройками
            "CustomizationXSDPathCustomizationXMLPath": "compendiumsconfig-perm/bookworm/formats_customization.xml",
Путь до xml-файла с кастомизацией настроек;
            "CustomizationXSDPath": "compendiums/formats_customization.xsd",
Путь до xsd-схемы, которой должен удовлетворять файл с кастомизацией настроек.
            "XMLPath": "config-perm/bookworm/formats.xml",

Путь к справочнику.

            "XSDPath": "compendiums/formats.xsd"

Путь до XSD-схемы, которой должны удовлетворять файлы с системными и пользовательскими настройками

  },
 

        "ExtractorCompendium": { 

Справочник для детектирования mime-типа по сигнатуре, а также определения подходящего экстрактора.

            "CustomXMLPath": "config-perm/bookworm/extractors_custom.xml",
Путь до пользовательского xml-файла с настройками;
            "CustomizationXMLPath": "config-perm/bookworm/extractors_customization.xml",
Путь до xml-файла с кастомизацией настроек;
            "CustomizationXSDPath": "compendiums/extractors_customization.xsd",
Путь до xsd-схемы, которой должен удовлетворять файл с кастомизацией настроек.
"
              "XMLPath":  "config-perm/bookworm/extractors.xml", 

Путь до системного xml-файла с настройками

              "XSDPath":  "compendiums/extractors.xsd"

Путь до XSD-схемы, которой должны удовлетворять файлы с системными и пользовательскими настройками

 },
 

        "ProtocolCompendium":  { 

Локализованный справочник протоколов.

                "XMLPath":  "config/bookworm/protocols.xml",

Путь к справочнику.

                "XSDPath":  "compendiums/protocols.xsd"
Путь к XSD-схеме для валидации.
 },
 
        "ServiceCompendium": { 
Локализованный справочник сервисов и типов событий.
                "XMLPath":  "config/bookworm/services.xml", 
 Путь к справочнику.
                "XSDPath":  "compendiums/services.xsd"
 Путь к XSD-схеме для валидации.
  },
 

        "TechInfoCompendium": { 
Локализованный справочник технологий для обработки mime-типов
                "XMLPath":  "config-perm/bookworm/tech_info.xml", 
Путь к справочнику.
"XSDPath":
                "XSDPath":  "compendiums/tech_info.xsd"
Путь к XSD-схеме для валидации.
  },
 
        "ValidatorCheck": true,
Включение/выключение валидации справочников.
    "UnsafeHandlers": false
Поддержка работы с необрабатываемыми сигналами. По умолчанию выключена (false). При установке значения true позволяется устанавливать в коде обработчики "небезопасных" сигналов (например,  SIGSEVG ).  Добавлять, включать/выключать данную настройку не рекомендуется без предварительной консультации с разработчиками.

}

 


Unit-файл iw_bookworm.service 

Scroll Table Layout
widths50%, 50%

Код
Описание

[Unit]

Раздел для определения метаданных демона и настройки его взаимодействия с другими демонами
Description=InfoWatch Traffic Monitor Configuration Bookworm

Название демона

After=network-online.service iwtm-consul.service Демоны, которые будут запущены до запуска текущего демона
  


[Service]Раздел настройки запуска демона

Type=simple

Тип запуска демона. simple - демон запускается и переходит в режим ожидания на консоли

PermissionsStartOnly=true

Запуск команд из ExecStartPre под пользователем root

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

Полный путь и аргументы команды, которые должны быть выполнены до запуска основного процесса

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

Полный путь и аргументы команды, которая должна быть выполнена для запуска демона. Запускается от пользователя, указанного в User

ExecStop=/bin/kill -s SIGQUIT $MAINPID

Команда для остановки демона. Если не указано, процесс будет немедленно уничтожен, когда демон будет остановлен. Запускается от пользователя, указанного в User

ExecReload=/bin/kill -s SIGHUP $MAINPID

Команда для перезагрузки конфигурации демона, если она доступна. Запускается от пользователя, указанного в User

Restart=on-failure

Команда для рестарта демона, если он остановится или упадет. Значение on-failure означает, что демон будет перезапускаться, если он остановился с ненулевым кодом возврата или был завершен по сигналу (kill <pid_демона>)

RestartSec=5

Время ожидания перед попыткой перезапуска демона

RestartPreventExitStatus=SIGKILL

Команда, по которой можно принудительно завершить работу демона

TimeoutStopSec=0

Время, в течение которого система будет ждать остановки демона, прежде чем пометить его недоступный или завершенный принудительно

User=iwtm

Имя пользователя, от которого осуществляется запуск демона

Group=iwtm

Имя группы пользователя

LimitNOFILE=32768

Максимальное количество открытых файлов

LimitFSIZE=infinity

Максимальный размер файла (КБ). infinity - без ограничений

LimitNPROC=65536

Максимальное количество процессов

LimitCORE=infinity

Ограничение на размер coredump-файла (КБ)

LimitMEMLOCK=infinity

Максимальное заблокированное в памяти адресное пространство (КБ)  
  





[Install]

Определение поведения демона, если он включен или отключен

WantedBy=multi-user.target

Запускать этот демон, когда система грузится в multi-user режиме
Sv translation
languageen

The bookworm.conf configuration file:

Scroll Table Layout
widths50%, 50%

ContentDescription
{
 

    "Logging": {...}
See General section Общая секция Logging
    "ThriftServers": {...}
See General section Общая секция ThriftServers
    "NookDir": "/opt/iw/tm5", 
In this section, the module working directory is specified. By default –  /opt/iw/tm5
    "DebugBreak": false, 
     

If SIGTRAP should be sent (SIGBREAK to Windows) while any exception handling. Used for debugging purposes.
    "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.

    "Discovery": {...},
See Common section Discovery
  "MergeDetector": {
Configuration of splice detector
        "CFBFormats": {
Formts signatures search
           "XMLPath": "mergedetector/cfb_formats.xml",
Path to directory
           "XSDPath": "mergedetector/cfb_formats.xsd"
Path to XSD scheme to validate
         },
 
         "EOFFormats": {

Comparison of file size and data from CFB (only for formats based on MS CFB)

           "XMLPath": "mergedetector/eof_formats.xml",
Path to directory
           "XSDPath": "mergedetector/eof_formats.xsd"
Path to XSD scheme to validate
         },
 

         "SizeFormats": {
Comparison of file size and value recorded in the known place (for different formats with size fields). This can be also applied to formats consisting of block series with records.
            "XMLPath": "mergedetector/size_formats.xml",
Path to directory
            "XSDPath": "mergedetector/size_formats.xsd"
Path to XSD scheme to validate
     },
 

    "Compendiums": {
Paths to compendiums list
        "OCRCompendium": {
Directory containing information about enabling OCR extraction for a specified service/ object type/ protocol.
 "BaseXMLPathXMLPath":  "config-perm/bookworm/ocr.xml",
Basic OCR directory. It is to be overwritten when updating the RPM packages.
 "CustomNodeXMLPath": [],
Custom OCR directory list for separate nodes. The highest rules priority. "CustomXMLPath":
 "CustomXMLPath":  "config-perm/bookworm/ocr-custom.xml",
Custom OCR options directory . The rules belonging to this section have higher priority over the corresponding rules from BaseXMLPath. This directory is not overwritten when RPM packages are updating.
    "XSDPath": "compendiums/ocr.xsd"

Path to XSD schema for OCR directory validation

},
         "ErrorCompendium": { 
Localized processing errors directory
   "XMLPath": "config-perm/bookworm/ocr-customerrors.xml",
Custom OCR options directory . The rules belonging to this section have higher priority over the corresponding rules from BaseXMLPath. This directory is not overwritten when RPM packages are updating. Path to directory
     "XSDPath": "compendiums/ocrerrors.xsd"
Path to XSD schema for OCR directory validation
}, 
                 "ErrorCompendiumActionCompendium": { 
Localized processing errors directoryDirectory of actions related to interrupted events. Supporting localization.
              "XMLPath": "config-perm/bookworm/errorsactions.xml",
Path to directory
               "XSDPath": "compendiums/errorsactions.xsd"
Path to XSD schema for validation
}, 
          "ActionCompendium": { 
Directory of actions related to interrupted events. Supporting localization.
"AntigarbageCompendium": { 
Directory with the samples of events, needed to avoid error when the events are wrongly deleted as garbage 
                            
              "XMLPath": "config-perm/bookworm/actionsantigarbage.xml",
Path to directory
 
              "XSDPath": "compendiums/actionserrors.xsd"
Path to XSD schema XSD-scheme for validation.
},
 
 

         "FormatCompendium": { 
Supported formats directory
            "CustomXMLPath": "config-perm/bookworm/formats_custom.xml",
Path to user xml file with settings
            "CustomizationXMLPath": "config-perm/bookworm/formats_customization.xml",
Path to xml file with settings customization
            "CustomizationXSDPath": "compendiums/formats_customization.xsd",
Path to xsd scheme, with which the file with settings customization should comply
              "XMLPath": "config-perm/bookworm/formats.xml",
Path to directory
              "XSDPath": "compendiums/formats.xsd"
Path to XSD schema for validation
  }, 
         "ExtractorCompendium": { 
Directory for signature-based detection of mime-type, and suitable extractor determination.
            "CustomXMLPath": "config-perm/bookworm/extractors_custom.xml",
Path to user xml file with settings
            "CustomizationXMLPath": "config-perm/bookworm/extractors_customization.xml",
Path to xml file with settings customization
            "CustomizationXSDPath": "compendiums/extractors_customization.xsd",
Path to xsd scheme, with which the file with settings customization should comply
              "XMLPath":  "config-perm/bookworm/extractors.xml",  

              "XSDPath":  "compendiums/extractors.xsd"
Path to XSD schema for validation
 }, 
          "ProtocolCompendium":  { 
Localized protocols directory.
                "XMLPath":  "config/bookworm/protocols.xml",
Path to directory
                "XSDPath":  "compendiums/protocols.xsd"
Path to XSD schema for validation
 }, 
          "ServiceCompendium": { 
Localized services and event types directory.
                "XMLPath":  "config/bookworm/services.xml", 
Path to directory
                "XSDPath":  "compendiums/services.xsd"
Path to XSD schema for validation
  }, 
          "TechInfoCompendium": {
Localized directory of technologies for mime-type processing.
                "XMLPath": "config-perm/bookworm/tech_info.xml", 
Path to directory.
                "XSDPath": "compendiums/tech_info.xsd"
Path to XSD schema for validation.
  }, 
     "ValidatorCheck": true,
Enabling/disabling directory validation
     "UnsafeHandlers": 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.
} 

The iw_bookworm.service unit file:

Scroll Table Layout
widths50%, 50%

CodeDescription

[Unit]

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

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_bookworm

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

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

The full path and command arguments 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)

 

 
  





[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