Parameter Description
Table 1 describes the log parameters. Log parameters (such as file names) can contain only letters, digits, and special characters (-._,/=). For security purposes, the paths involved in Table 1 must meet the security requirements of your organization.
For more information about Ascend DMI, run the ascend-dmi -h command.
Parameter |
Description |
Mandatory or Not |
|---|---|---|
[-h, --help] |
Display the help information about the ascend-log-collect.sh script. |
Yes |
[-v, --version] |
Displays the version information about the ascend-log-collect.sh script. |
Yes |
--output-file=<FILENAME> |
Specifies the output path and file name of the collected logs. The recommended file name extension is .tar.gz. If --output-file is not specified, the ascend-report-<hostname>-<YYYYMMDDhhmmss>.tar.gz file is generated in the current path by default. If only the name of the output file is specified but the output path is not specified, the file with the specified name is generated in the current path by default. The output path of collected logs cannot contain a large number of other files. |
No |
--safe |
Calls Ascend DMI to check the device health status. In this case, the power consumption test is not performed. This option is enabled by default. |
No |
--extra |
Calls Ascend DMI to check all check items. --extra takes effect only when --modules is set to ascend or not specified. If the power consumption test is performed, the AI Core usage and processor temperature increase. After the collection is complete, the AI Core usage and processor temperature become normal. NOTE:
If both --safe and --extra are specified, the latter one takes effect. For example, if ascend-log-collect.sh --extra --safe is used, --safe takes effect and --extra does not take effect. |
No |
--modules=<MODULE>[,<MODULE>]... |
Specifies the modules whose information is to be collected. Use commas (,) to separate multiple modules. The options are system, ascend, mindx, and all. For details about the mapping between the specified modules and the collected files, see Table 2. If --modules is set to all, the information about all preceding modules is collected. |
No |
--ascend-path=<PATH> |
Specifies the path of the installed Ascend software. The installed software version information is collected. The default path is /usr/local/Ascend. |
No |
--user=<USERNAME> |
Specifies the user whose CANN logs are collected. This parameter is supported only by the root user and cannot be used on the Atlas 200 AI accelerator module (RC). This parameter and --user-log are mutually exclusive and cannot be used at the same time. If neither --user nor --user-log is specified, the user mode logs of the current user are collected by default in $HOME/ascend/log and /var/log/ascend_seclog. NOTE:
--user is recommended. |
No |
--user-log=<USERLOG> |
Specifies the directory from which CANN logs are collected. This parameter can be used only by the root user and cannot be used on the Atlas 200 AI accelerator module (RC) and Atlas 200I SoC A1 core board. This parameter and --user are mutually exclusive and cannot be used at the same time. If neither --user nor --user-log is specified, the user mode logs of the current user are collected by default in $HOME/ascend/log and /var/log/ascend_seclog. NOTE:
--user is recommended. |
No |
--sdk-log-path=<PATH> |
Specifies the directory for storing SDK logs. Enter the actual directory for storing generated SDK logs. You are advised to set this parameter to the minimum directory where the logs to be collected are located. If the directory is too large, all readable files in the directory will be collected, including a large amount of redundant information. |
No |
--mindie-log-path=<MINDIELOGPATH> |
Specifies the log path to store MindIE logs. The default value is /var/log/ascend_log/app_log/mindie. |
No |
[-q, --quiet] |
If this parameter is specified, no foolproof message is displayed. By default, this operation is allowed. -q takes effect only when the ascend module logs are collected and --extra is specified. NOTE:
If this parameter is not specified, a foolproof message is displayed. You need to enter Y or N (y or n) to confirm the operation. |
No |
Module |
Collected File |
Note |
|---|---|---|
system |
system-report.log.gz |
- |
ascend |
ascend-report.log.gz, npu_log_collect_YYYYMMDDhhmmss.tar.gz, ascend_user_log.tar.gz, device_log.tar.gz, ascend_user_install_log.tar.gz, and YYYY-MM-DD-HH-MM-SS folder |
|
mindx |
alog.tar.gz, plog.tar.gz and mindx_sdk_info_*.tar.gz |
The alog.tar.gz and plog.tar.gz files are collected and generated only when the logs of edge devices exist. The mindx_sdk_info_*.tar.gz file is collected and generated only when the path of SDK logs to be collected is specified. |
Example
- ascend-log-collect.sh -h (Viewing the help information)

- ascend-log-collect.sh --version (Viewing the version information)

- ascend-log-collect.sh (executing in default mode)

- ascend-log-collect.sh --safe (executing in safe mode)

- ascend-log-collect.sh --extra (executing in extra mode)

- ascend-log-collect.sh --output-file=./result.tar.gz (specifying the output file)

- (--modules=ascend): ascend-log-collect.sh --modules=ascend (Only Ascend NPU health information, Ascend software logs, device system logs, and Ascend NPU logs are collected.)

- ascend-log-collect.sh --user=HwHiAiUser (specifying the user whose CANN logs are collected)

- ascend-log-collect.sh --user-log=/root/ascend/log (specifying the directory from which CANN logs are collected)

- ascend-log-collect.sh --sdk-log-path=/home/ascend/mxVision-{version}/logs (specifying the directory for collecting SDK logs)

- ascend-log-collect.sh --mindie-log-path=/var/log/ascend_log/app_log/mindie (Specifying the path that stores MindIE logs to be collected)
