Log Overview
Log Types
Logs record the running process and exception information of a system and support troubleshooting in system running and program debugging during development. Logs are classified into the following types:
- System logs that record OS events on the device, including:
- System logs of the Ctrl CPU (kernel-mode logs and user-mode logs generated during system process running), which reflect the overall running status of the Ascend AI Processor.
- System logs of the non-Ctrl CPU (for example, low-power electronics), which reflect the running status of components such as the low-power electronics, Task Scheduler, and ISP.
- App logs that are generated at AI app runtime, including:
- Logs printed by components such as AscendCL, GE, Runtime, and HCCL on the host.
- Logs printed by the AI CPU process on the device.
For details about the modes mentioned in this document, see Ascend Product Models.
Replace id and pid in log file names in this document with the actual device ID and service process ID, respectively.
During program running, the maintenance and test information of the software stack is recorded in the memory. If a program running error occurs or a process ends, the information is flushed to a file, preventing frequent generation and recording of log files from affecting the performance. The information is stored in trace logs, which are generated independently. For details, see Viewing Trace Logs.
Log Format
A log example is as follows:
[ERROR] TEFUSION(12940,atc):2021-10-17-05:54:07.599.074 [tensor_engine/te_fusion/pywrapper.cc:33]InitPyLogger Failed to import te.platform.log_util
The log format is as follows:
[Level] ModuleName(PID,PName):DateTimeMS [FileName:LineNumber]LogContent
Field |
Description |
|---|---|
Level |
Log level. The options are as follows: ERROR, WARNING, INFO, or DEBUG. |
ModuleName |
Name of the module that generates a log |
PID |
Module process ID |
PName |
Module process name |
DateTimeMS |
Time when a log is printed, formatted as: yyyy-mm-dd-hh:mm:ss.fff.zzz (year-month-day-hour:minute:second:millisecond:microsecond) |
FileName:LineNumber |
File name and the corresponding line number that calls the log printing API |
LogContent |
Detailed log content of each module |