nv show system log
|
|
nv show system log
Shows the system log files and the log configuration, or opens a log file. |
|
|
Syntax Description
|
log |
Shows the log files, the component log levels, and the log rotation settings. |
|
file |
Opens the current log file (syslog) in the less viewer. |
|
|
file-name |
The log file to open; for example, syslog.1. |
|
|
follow |
Shows the last lines of the current log file, then shows new lines as they are written (like tail -F). Press Ctrl+C to stop. |
|
|
list |
Lists the available log files. |
|
|
Default |
N/A |
|
|
History |
25.02.2002
|
|
|
Example |
|
|
|
REST API |
GET https://<ip>/nvue_v1/system/log
|
|
|
Related Commands |
nv set system log component <component-name> level <level> |
|
|
Notes |
|
|
nv show system log component
|
|
nv show system log component [<component-name>]
Shows the log level of the system components, or the log files of a component. |
|
|
Syntax Description |
component-name |
The component name; for example, nvue. If you omit it, the command shows all components. |
|
file |
Opens the current log file of the component in the less viewer. |
|
|
file-name |
The component log file to open. |
|
|
follow |
Shows the last lines of the current log file, then shows new lines as they are written (like tail -F). Press Ctrl+C to stop. |
|
|
list |
Lists the log files of the component. |
|
|
Default |
N/A |
|
|
History |
25.02.2002
|
|
|
Example |
|
|
|
REST API |
GET https://<ip>/nvue_v1/system/log/component
|
|
|
Related Commands |
nv set system log component <component-name> level <level> |
|
|
Notes |
|
|
nv show system log rotation
|
|
nv show system log rotation Shows the log rotation settings. |
|
|
Syntax Description |
N/A |
|
|
Default |
N/A |
|
|
History |
25.02.2002 |
|
|
Example |
|
|
|
REST API |
GET https://<ip>/nvue_v1/system/log/rotation |
|
|
Related Commands |
nv set system log rotation |
|
|
Notes |
|
|
nv set/unset system log component
|
|
nv set system log component <component-name> level <level>
Sets the minimum priority level of the messages that a system component logs. The unset command restores the default (notice). |
|
|
Syntax Description |
component-name |
The component name: nvue, orchagent, peer_telemetry, portsyncd, sai_api_port, sai_api_switch, symmetry-manager, or syncd. |
|
level |
The minimum priority level: debug, info, notice, warn, error, or critical. |
|
|
Default |
notice |
|
|
History |
25.02.2002 |
|
|
Example |
|
|
|
REST API |
PATCH https://<ip>/nvue_v1/system/log/component |
|
|
Related Commands |
nv show system log component |
|
|
Notes |
To see the component names, run the nv show system log component command. |
|
nv set/unset system log rotation disk-percentage
|
|
nv set system log rotation disk-percentage <percentage>
Sets the log file size at which to rotate the file, as a percentage of the disk size. The unset command removes the setting. |
|
|
Syntax Description |
percentage |
The percentage of the disk size: 0.001–100. |
|
Default |
N/A |
|
|
History |
25.02.2002 |
|
|
Example |
|
|
|
REST API |
PATCH https://<ip>/nvue_v1/system/log/rotation |
|
|
Related Commands |
nv show system log rotation |
|
|
Notes |
If you set the disk percentage, the switch uses it instead of the size setting. |
|
nv set/unset system log rotation frequency
|
|
nv set system log rotation frequency <frequency>
Sets how often to rotate the log files. The unset command restores the default (daily). |
|
|
Syntax Description |
frequency |
The rotation frequency: daily, weekly, monthly, or yearly. |
|
Default |
daily |
|
|
History |
25.02.2002 |
|
|
Example |
|
|
|
REST API |
PATCH https://<ip>/nvue_v1/system/log/rotation |
|
|
Related Commands |
nv show system log rotation |
|
|
Notes |
|
|
nv set/unset system log rotation max-number
|
|
nv set system log rotation max-number <count>
Sets the maximum number of rotated log files to keep. The unset command restores the default (20). |
|
|
Syntax Description |
count |
The number of rotated log files to keep before the oldest file is removed: 0–999999. |
|
Default |
20 |
|
|
History |
25.02.2002 |
|
|
Example |
|
|
|
REST API |
PATCH https://<ip>/nvue_v1/system/log/rotation |
|
|
Related Commands |
nv show system log rotation |
|
|
Notes |
|
|
nv set/unset system log rotation size
|
|
nv set system log rotation size <mebibytes>
Sets the log file size, in MiB, at which to rotate the file. The unset command restores the default (10 MiB). |
|
|
Syntax Description |
mebibytes |
The file size in MiB: 0.001–3500. |
|
Default |
10 |
|
|
History |
25.02.2002 |
|
|
Example |
|
|
|
REST API |
PATCH https://<ip>/nvue_v1/system/log/rotation |
|
|
Related Commands |
nv show system log rotation |
|
|
Notes |
The disk-percentage setting, if set, overrides this setting. |
|
nv action rotate system log
|
|
nv action rotate system log Rotates and compresses the system log files manually. |
|
|
Syntax Description |
N/A |
|
|
Default |
N/A |
|
|
History |
25.02.2002 |
|
|
Example |
|
|
|
REST API |
POST https://<ip>/nvue_v1/system/log/@rotate |
|
|
Related Commands |
nv show system log rotation |
|
|
Notes |
|
|
Last updated: