Configuration Options¶
Here we will list all options and what they do.
Command Line¶
All of the command line arguments can also be added to a config file.
address
¶
The IP address to use to listen for all incoming syslog messages.
Default: 0.0.0.0
.
CLI usage example:
$ napalm-logs -a 172.17.17.1
$ napalm-logs --address 172.17.17.1
Configuration file example:
address: 172.17.17.1
auth-address
¶
The IP address to listen on for incoming authorisation requests.
Default: 0.0.0.0
.
CLI usage example:
$ napalm-logs --auth-address 172.17.17.2
Configuration file example:
auth_address: 172.17.17.2
auth-port
¶
The port to listen on for incoming authorisation requests.
Default: 49018
CLI usgae example:
$ napalm-logs --auth-port 2022
Configuration file example:
auth_port: 2022
certificate
¶
The certificate to use for the authorisation process. This will be presented to incoming clients during the TLS handshake.
CLI usage example:
$ napalm-logs --certificate /var/cache/server.crt
Configuration file example:
certificate: /var/cache/server.crt
config-file
¶
Specifies the file where further configuration options can be found.
Default: /etc/napalm/logs
.
CLI usage example:
$ napalm-logs -c /srv/napalm-logs
$ napalm-logs --config-file /srv/napalm-logs
config-path
¶
The directory path where device configuration files can be found. These are the files that contain the syslog message format for each device.
CLI usage example:
$ napalm-logs --config-path /home/admin/napalm-logs/
Configuration file example:
config_path: /home/admin/napalm-logs/
disable-security
¶
If set no encryption or message signing will take place. All messages will be in plain text. The client will not be able to verify that a message was generated by the server.
It is not recommended to use this in a production environment.
CLI usage example:
$ napalm-logs --disable-security
Configuration file example:
disable_security: true
extension-config-path
¶
A path where you can specify further device configuration files that contain the syslog message format for devices.
CLI usage example:
$ napalm-logs --extension-config-path /home/admin/napalm-logs/
Configuration file example:
extension_config_path: /home/admin/napalm-logs/
keyfile
¶
The private key for the certificate specified by the certificate
option.
This will be used to generate a key to encrypt messages.
CLI usage example:
$ napalm-logs --keyfile /var/cache/server.key
Configuration file example:
keyfile: /var/cache/server.key
listener
¶
The module to use when listening for incoming syslog messages. For more details, see Listener.
Default: udp
.
CLI usage example:
$ napalm-logs --listener kafka
Configuration file example:
listener: kafka
log-file
¶
The file where to send log messages.
If you want log messages to be outputted to the command line you can specify
--log-file cli
.
Default: /var/log/napalm/logs
.
CLI usage example:
$ napalm-logs --log-file /var/log/napalm-logs
Configuration file example:
log_file: /var/log/napalm-logs
log-format
¶
The format of the log messages.
Default: %(asctime)s,%(msecs)03.0f [%(name)-17s][%(levelname)-8s] %(message)s
.
Example: 2017-07-03 11:54:25,300,301 [napalm_logs.listener.tcp][INFO ] Stopping listener process
CLI usage example:
$ napalm-logs --log-format '%(asctime)s,%(msecs)03.0f [%(levelname)] %(message)s'
Configuration file example:
log_format: '%(asctime)s,%(msecs)03.0f [%(levelname)] %(message)s'
log-level
¶
The level at which to log messages. Possible options are CRITIAL
, ERROR
,
WARNING
, INFO
, DEBUG
.
Default: WARNING
.
CLI usage example:
$ napalm-logs -l debug
$ napalm-logs --log-level info
Configuration file example:
log_level: info
port
¶
This can be assigned using -p
The port to use to listen for all incoming syslog messages.
Default: 514
.
CLI usage example:
$ napalm-logs -p 1024
$ napalm-logs --port 1024
Configuration file example:
port: 1024
publish-address
¶
The IP address to use to output the processed message.
Default: 0.0.0.0
.
CLI usage example:
$ napalm-logs --publish-address 172.17.17.3
Configuration file example:
publish_address: 172.17.17.3
publish-port
¶
The port to use to output the processes message.
Default: 49017
.
CLI usage example:
$ napalm-logs --publish-port 2048
Configuration file example:
publish_port: 2048
transport
¶
The module to use to output the processed message information. For more details, see Publisher.
Default: zmq
(ZeroMQ).
CLI usage example:
$ napalm-logs -t kafka
$ napalm-logs --transport kafka
$ napalm-logs --publisher kafka
Configuration file example:
transport: kafka
Or:
publisher: kafka
Config File Only Options¶
The options to be used inside of the pluggable modules are not provided via the command line, they need to be provided in the config file.
device_whitelist
¶
List of platforms to be supported. By default this is an empty list, thus everything will be accepted. This is useful to control the number of sub-processes started.
Example:
device_whitelist:
- junos
- iosxr
device_blacklist
¶
List of platforms to be ignored. By default this list is empty, thus nothing will be ignored. This is also useful to control the number of sub-processes started.
Example:
device_blacklist:
- eos