ASCEND_MODULE_LOG_LEVEL
Description
Sets the level of each module of app logs. Only debug logs are supported.
Format: export ASCEND_MODULE_LOG_LEVEL=module_name=module_level.
- module_name: module name, which can be GE, ASCENDCL, DRV, or RUNTIME. For details, see CANN_software_installation_directory/include/experiment/slog/toolchain/slog.h.
- module_level: log level of the corresponding module. The options are as follows:
- 0: DEBUG
- 1: INFO
- 2: WARNING
- 3: ERROR
- 4: NULL (no log output)
- Other values: invalid
- You must use no space before or after the equal sign (=) and colon (:). If you set log levels for multiple modules, separate the modules with colons (:). If the command format is incorrect (for example, the command contains symbols other than equal signs and colons) or the command contains unsupported module names, the command line is invalid.
- You can run the echo $ASCEND_MODULE_LOG_LEVEL command to view the log level set by the specific environment variable.
- If the environment variable is not configured, invalid, or left empty, the global log level is used. The priority of the ASCEND_MODULE_LOG_LEVEL environment variable is higher than that of the ASCEND_GLOBAL_LOG_LEVEL environment variable. If both are set, the ASCEND_MODULE_LOG_LEVEL environment variable takes effect.
- After the log level is set to DEBUG, service performance may be affected due to heavy log traffic.
- The environment variable takes effect only for debug logs and does not take effect for run and security logs.
Example
export ASCEND_MODULE_LOG_LEVEL=TBE=0:RUNTIME=0
Restrictions
None
Applicability
Parent topic: Logs