Skip to content

Commit ccdf938

Browse files
committed
docs: update logging documentation to clarify log file paths
1 parent d02db23 commit ccdf938

4 files changed

Lines changed: 26 additions & 40 deletions

File tree

docs/en/source/camera_devices/4_application_guide/launch_parameters.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -252,7 +252,7 @@ The following are the launch parameters available:
252252
* Shared SDK and ROS node log level. By default, only current device status is printed; set it to `debug` for more debug logs. Optional values: `none`, `debug`, `info`, `warn`, `error`, `fatal`.
253253
* SDK logs and crash files are saved to `~/.ros/Log` by default. ROS logs remain in `~/.ros/log`.
254254
* **`log_file_name`**
255-
* Saved SDK log file name. Effective when `log_level` is `debug`.
255+
* Saved SDK log file name. Effective when `log_level` is `debug`; the actual path is usually `~/.ros/Log/<camera_name>/<log_file_name>`.
256256
* **`enable_firmware_log`**
257257
* Enable firmware logging. This switch is independent from `enable_heartbeat` and can be enabled only when firmware logs are needed.
258258
* **`diagnostic_period`**

docs/en/source/camera_devices/8_FAQ/FAQ.md

Lines changed: 12 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
### Unexpected Crash
44

5-
If the camera node crashes unexpectedly, it will generate a crash log in the current running directory: `Log/camera_crash_stack_trace_xx.log`. Please send this log to the support team or submit it to a GitHub issue for further assistance.
5+
If the camera node crashes unexpectedly, it will generate a crash log under `~/.ros/Log/<camera_name>/`, with a file name similar to `camera_name_crash_stack_trace_xx.log`. Please send this log to the support team or submit it to a GitHub issue for further assistance.
66

77
### No Data Stream from Multiple Cameras
88

@@ -29,8 +29,10 @@ If the camera node crashes unexpectedly, it will generate a crash log in the cur
2929

3030
**1. SDK debug logs**
3131

32-
Set the launch parameter `log_level` to `debug`. After running, the SDK will generate log files in the `Log/` folder under the current working directory. If you want a more recognizable file name for this test, you can set the parameter `log_file_name`.
32+
Set the launch parameter `log_level` to `debug`. After running, the SDK will generate log files under `~/.ros/Log/<camera_name>/`. If you want a more recognizable file name for this test, you can set the parameter `log_file_name`.
3333

34+
- The actual SDK log file path is usually `~/.ros/Log/<camera_name>/<log_file_name>`.
35+
- In multi-camera setups, SDK logs are separated by `camera_name`, for example `~/.ros/Log/camera_01/camera_01.log` and `~/.ros/Log/camera_02/camera_02.log`.
3436
- SDK logs are appended to the same file: multiple launches will continue writing into the same log file.
3537
- Recommendation: before packaging logs to send to technical support, delete old log files, then reproduce the issue and collect new logs. This keeps the logs cleaner and makes troubleshooting more accurate.
3638

@@ -39,21 +41,14 @@ Set the launch parameter `log_level` to `debug`. After running, the SDK will gen
3941
In the launch file, set the node (or composable node container) parameter `output` to `"log"` to save ROS 2 logs locally.
4042

4143
- After setting `output="log"`, ROS 2 logs will be stored in the `~/.ros/log/` directory.
42-
- When submitting an issue, please package both the SDK logs under the `Log/` directory and the corresponding ROS 2 logs under `~/.ros/log/` for the same time period.
43-
44-
**3. Example Tutorial**
45-
46-
Run in the terminal
47-
```
48-
ros2 launch orbbec_camera gemini_330_series.launch.py log_level:=debug
49-
```
50-
![alt text](../../../../zh/source/camera_devices/image/image-2.png)
51-
52-
You can find the SDK logs in the Log folder within the current working directory.
53-
![alt text](../../../../zh/source/camera_devices/image/image-1.png)
54-
55-
ros2 log is enabled by default and can be viewed under `~/.ros/log/`
56-
![alt text](../../../../zh/source/camera_devices/image/image.png)
44+
- Each `ros2 launch` run creates a timestamped directory under `~/.ros/log/` containing `launch.log`, and also generates process log files such as `component_container_<pid>_<timestamp>.log`.
45+
- The difference is:
46+
- `launch.log` contains the merged output from all camera containers.
47+
- `component_container_<pid>_<timestamp>.log` records the runtime output of a specific container process.
48+
- In multi-camera setups, `component_container_<pid>_<timestamp>.log` is separated by container process.
49+
- In one-camera-per-container multi-camera launches, you can treat it as “one camera corresponds to one `component_container_*.log`”. If multiple cameras are loaded into the same container, that `component_container_*.log` will also contain logs from multiple cameras.
50+
- To identify the exact camera, rely on the namespace or node name in the log content, for example `camera_01.camera_01` and `camera_02.camera_02`.
51+
- When submitting an issue, please package both the SDK logs under `~/.ros/Log/` and the corresponding ROS 2 logs under `~/.ros/log/` for the same time period.
5752

5853
### Why Are There So Many Launch Files?
5954

@@ -139,5 +134,3 @@ If the above methods still cannot solve the problem, please contact our company
139134
* `Unit`: µs
140135

141136
If `software_trigger_period` is set too small, the trigger frequency will be limited, resulting in frame loss.
142-
143-

docs/zh/source/camera_devices/4_application_guide/launch_parameters.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -252,7 +252,7 @@
252252
* SDK和ROS节点日志级别。默认只输出设备当前状态;需要更多调试信息时可设置为 `debug`。可选值:`none``debug``info``warn``error``fatal`
253253
* SDK日志和崩溃文件默认保存在 `~/.ros/Log`,ROS日志仍保存在 `~/.ros/log`
254254
* **`log_file_name`**
255-
* 保存的SDK日志文件名。当`log_level``debug`时生效。
255+
* 保存的SDK日志文件名。当`log_level``debug`时生效;实际路径通常为 `~/.ros/Log/<camera_name>/<log_file_name>`
256256
* **`enable_firmware_log`**
257257
* 启用固件日志。该开关与 `enable_heartbeat` 解耦,适合在需要抓取固件日志时单独开启。
258258
* **`diagnostic_period`**

docs/zh/source/camera_devices/8_FAQ/FAQ.md

Lines changed: 12 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
### 意外崩溃
44

5-
如果相机节点意外崩溃,它将在当前运行目录中生成崩溃日志:`Log/camera_crash_stack_trace_xx.log`请将此日志发送给支持团队或提交到GitHub issue以获得进一步帮助
5+
如果相机节点意外崩溃,它会在 `~/.ros/Log/<camera_name>/` 目录下生成崩溃日志,文件名类似 `camera_name_crash_stack_trace_xx.log`请将此日志发送给支持团队或提交到 GitHub issue 以获得进一步帮助
66

77
### 多相机无数据流
88

@@ -29,8 +29,10 @@
2929

3030
**1. SDK debug 日志**
3131

32-
将 launch 参数 `log_level` 设为 `debug` 运行后,会在当前工作目录下的 `Log/` 文件夹中生成 SDK 日志文件。如果需要为本次测试指定一个更易识别的日志文件名,可以修改参数 `log_file_name`
32+
将 launch 参数 `log_level` 设为 `debug` 运行后,会在 `~/.ros/Log/<camera_name>/` 目录下生成 SDK 日志文件。如果需要为本次测试指定一个更易识别的日志文件名,可以修改参数 `log_file_name`
3333

34+
- `log_file_name` 对应的实际文件路径通常为 `~/.ros/Log/<camera_name>/<log_file_name>`
35+
- 多相机场景下,SDK 日志按 `camera_name` 分目录保存,例如 `~/.ros/Log/camera_01/camera_01.log``~/.ros/Log/camera_02/camera_02.log`
3436
- SDK 日志是追加写入的:多次启动会在同一个文件里不断累积日志。
3537
- 建议:在准备打包日志发给技术支持前,先删除旧的日志文件,然后重新复现问题并采集新的日志,这样日志更干净、定位更准确。
3638

@@ -39,21 +41,14 @@
3941
在 launch 文件中,将节点(或可组合节点容器)的 `output` 参数设为 `"log"`,即可将 ROS2 日志保存到本地:
4042

4143
- 设置为 `output="log"` 后,ROS2 日志将保存在 `~/.ros/log/` 目录下。
42-
- 如需提交问题,请同时打包 `Log/` 目录下的 SDK 日志和 `~/.ros/log/` 下对应时间的 ROS2 日志,一并提供。
43-
44-
**3. 示例**
45-
46-
在终端运行
47-
```
48-
ros2 launch orbbec_camera gemini_330_series.launch.py log_level:=debug
49-
```
50-
![alt text](../image/image-2.png)
51-
52-
即可在当前工作目录下的 Log 文件夹下查看 SDK 日志
53-
![alt text](../image/image-1.png)
54-
55-
ros2 log 默认开启,可在 `~/.ros/log/` 下查看
56-
![alt text](../image/image.png)
44+
- 每次 `ros2 launch` 会在 `~/.ros/log/` 下生成一个时间戳目录,里面有 `launch.log`;同时还会生成 `component_container_<pid>_<timestamp>.log` 一类的进程日志文件。
45+
- 二者区别如下:
46+
- `launch.log` 包含所有相机容器输出汇总后的日志。
47+
- `component_container_<pid>_<timestamp>.log` 记录的是某个容器进程本身的运行输出。
48+
- 多相机场景下,`component_container_<pid>_<timestamp>.log` 是按“容器进程”区分的。
49+
- 在一机一容器的多相机 launch 中,可以看做“一路相机对应一个 `component_container_*.log`”;如果你把多路相机加载到同一个容器里,那么同一个 `component_container_*.log` 里也就包含多路相机日志。
50+
- 区分具体是哪一路相机时,请以日志内容中的命名空间或节点名为准,例如 `camera_01.camera_01``camera_02.camera_02`
51+
- 如需提交问题,请同时打包 `~/.ros/Log/` 目录下的 SDK 日志和 `~/.ros/log/` 下对应时间的 ROS2 日志,一并提供。
5752

5853
### 为什么有这么多启动文件?
5954

@@ -141,5 +136,3 @@ ros2 launch orbbec_camera femto_bolt.launch.py serial_number:=CL8H741005J
141136
* `单位`:µs
142137

143138
`software_trigger_period` 设置过小,将导致触发频率受限,从而丢帧。
144-
145-

0 commit comments

Comments
 (0)