Programmable Internetworking & Communication Operating System Docs ... Click Spaces -> Space Directory to see docs for all releases ...
Page tree
Skip to end of metadata
Go to start of metadata

The set system syslog local-file command sets the local save location of the syslog file.


Command Syntax

set system syslog local-file <location>


Parameter

Parameter

Description

local-file <location>

Specifies the local save location of the syslog. The value could be disk or ram.

  •   disk: saves the syslog to disk, the path is /tmp/log.
  •   ram: saves the syslog to RAM, the path is /var/log.

By default, the syslog is kept in RAM.


Usage Guidelines

By default, the syslog file stays in RAM. When the system is powered off and restarted, the syslog file in RAM will be cleared. You can configure the syslog to be saved to disk. When the system is powered off and restarted, the syslog saved to disk will still exist.

NOTE

For N3048EP-ON, N3048ET-ON, N1148T-ON and N3132PX switches, because of the OverlayFS file system, the log files on the switch will not be saved from RAM to the flash even if you have set the save location of the syslog to disk. If you want the syslog file not to be cleared when the system is powered off and restarted, you need to perform the file backup operation. The steps are as follows or you can see File Backup.

The steps of syslog file backup are as follows:

1.   Add syslog file path (If the save location of the syslog is RAM, the path is /tmp/log; else if save location of the syslog is disk, the path is /var/log) to the backup list, in /mnt/open/picos/backup_files file.

        Show the backup file list:

root@Xorplus$ cat /mnt/open/picos/backup_files
/tmp/log


2.   Under Linux bash, issue the following command manually (When setting OVS commands, you can only use this command to save the configuration file):

root@Xorplus$ save_config


Example

•  Set the local save location of the syslog file to disk.

admin@XorPlus# set system syslog local-file disk
admin@XorPlus# commit
  • No labels