Starting the Trace Forwarding Process

Function Description

Starts the Trace forwarding process.

Precautions

Retry mechanism: If a request fails, the system retries up to 6 times by default. If all retries fail, Trace forwarding is suspended until the request succeeds.

Syntax

python -m ms_service_profiler.trace [--log-level]

For details about the options, see Option Description.

Option Description

Table 1 Option description

Option

Description

Required/Optional

--log-level

Sets the log level. The values are as follows:

  • debug: debug level. Logs at this level record the debugging information for developers or maintenance personnel to locate faults.
  • info: normal level (default). Logs at this level record information about proper tool running.
  • warning: warning level. Logs at this level record information when the tool does not run in an expected state, but the running of the process is not affected.
  • error: minor error level.
  • fatal: major error level.
  • critical: critical error level.

Optional

Example

Start the Trace forwarding process using the default configuration. The command is as follows:

python -m ms_service_profiler.trace

The user who starts Trace forwarding must be the same as the user who starts the MindIE Motor service, and they must be in the same network namespace (on the same Docker or host).

Output Description

The following is an example of the command output when the forwarding process is started successfully:
2025-11-27 18:46:42,737 - 23410 - msServiceProfiler - INFO - Start http/protobuf exporter, endpoint: http://localhost:4318/v1/traces
2025-11-27 18:46:42,737 - 23410 - msServiceProfiler - INFO - Start socket server success, listen addr: OTLP_SOCKET
2025-11-27 18:46:42,737 - 23410 - msServiceProfiler - INFO - Start scheduler task: interval 1s
2025-11-27 18:46:42,738 - 23410 - msServiceProfiler - INFO - Start OTLPForwarderService success, running...