OcNOS-SP : System Management Guide : System Management Command Reference : Syslog Commands : logging logfile
logging logfile
Use this command to specify the log file controls and where to save the logs in a configuration file. This command enables writing debug output and command history to the disk file in the directory /log/.
When logging logfile is enabled, OcNOS log information is stored in user configured logging file which is present in "/log" directory. The log is spread across four files total of these files size is the user configured size.
For example, if the name of the logging log file is “mylogFile” and logging file size configured is 4 MB then each file will be maximum size of 1MB. The logging file names will be "mylogFile", "mylogfile.0", "mylogfile.1" and "mylogfile.2".
"mylogFile" will have the latest log information. As soon as it’s size becomes 1 MB this file is renamed as mylogFile.0 and newlog information is written to new "mylogFile". As a result oldest log information stored in mylogfile.2 and is lost in order to accommodate new set of logs in mylogFile.
Use option no to cancel writing to a specific log file.
Note: Changing logfile paramenters (name/size/severity) will be taken into effect for the next OcNOS session.
Command Syntax
logging logfile LOGFILENAME <0-7> ((size <4096-419430400>)|)
no logging logfile
Parameter
LOGFILENAME
Specify the snmp user name (Min 5 to Max 32 alphanumeric characters).
<0-7>
Severity level as shown in Table 32-94.
<4096-419430400>

Log file size in bytes.
Default
By default, log file size is 419430400 bytes.
Command Mode
Configure mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
This command is used to log the debug messages of a particular protocol daemon to the specified file.
#configure terminal
(config)#logging logfile test123 7
 
 
Last modified date: 10/19/2023