Log CLI Commands
log set level
- Function
Sets the log level.
- Syntax
log set level <level_name>
- Parameters
Parameter
Description
Value
level_name
Changes the log level to the corresponding value.
CRI, ERR, WARN, INFO, or DBG
log clearflag
- Function
When a fault occurs in the log system, the fault tolerance mechanism of the log system is activated to change the log file directory (from /var/log/gcache to /opt/gcache/tmp by default). After the fault is rectified, run this command to clear the fault flag and restore the log file directory from the one used for fault tolerance (/opt/gcache/tmp) to the one specified in the configuration file (/var/log/gcache).
- Syntax
log clearflag
- Parameters
Parameter
Description
Value
N/A
N/A
N/A
log clearalarm
- Function
Clears log alarms of the log module.
- Syntax
log clearalarm <alarm_num>
- Parameters
Parameter
Description
Value
alarm_num
6: The usage of the drive where logs are stored exceeds the threshold.
7: The capacity of the drive where logs are stored is insufficient.
9: The log file cannot be opened.
10: The log file cannot be written.
11: The log file cannot be renamed.
12: The log file cannot be removed.
6, 7, 9, 10, 11, or 12