#
6db7a859
|
| 17-Jul-2025 |
William de Abreu Pinho <williamdapinho@gmail.com> |
move service files from Yocto layer
This change relocates phosphor-debug-collector service files from the Yocto layer to the phosphor-debug-collector repository. It also ensures that non-user execut
move service files from Yocto layer
This change relocates phosphor-debug-collector service files from the Yocto layer to the phosphor-debug-collector repository. It also ensures that non-user executables are installed in the libexec.
[1]: https://github.com/openbmc/docs/blob/master/anti-patterns.md#incorrect-placement-of-executables-in-sbin-usrsbin-or-bin-usrbin
Tested: ``` $ find /tmp/phosphor-debug-collector | grep libexec /tmp/phosphor-debug-collector/usr/local/libexec /tmp/phosphor-debug-collector/usr/local/libexec/phosphor-debug-collector /tmp/phosphor-debug-collector/usr/local/libexec/phosphor-debug-collector/phosphor-dump-manager /tmp/phosphor-debug-collector/usr/local/libexec/phosphor-debug-collector/phosphor-dump-monitor /tmp/phosphor-debug-collector/usr/local/libexec/phosphor-debug-collector/phosphor-ramoops-monitor $ find /tmp/phosphor-debug-collector | grep service /tmp/phosphor-debug-collector/usr/lib/systemd/system/obmc-dump-monitor.service /tmp/phosphor-debug-collector/usr/lib/systemd/system/ramoops-monitor.service /tmp/phosphor-debug-collector/usr/lib/systemd/system/xyz.openbmc_project.Dump.Manager.service ``` Booted image in qemu: ``` root@bmc:~# ls -l /usr/libexec/phosphor-debug-collector/ -rwxr-xr-x 1 root root 367700 Mar 9 2018 phosphor-dump-manager -rwxr-xr-x 1 root root 34452 Mar 9 2018 phosphor-dump-monitor -rwxr-xr-x 1 root root 26200 Mar 9 2018 phosphor-ramoops-monitor root@bmc:~# systemctl status xyz.openbmc_project.Dump.Manager.service * xyz.openbmc_project.Dump.Manager.service - Phosphor Dump Manager Loaded: loaded (/usr/lib/systemd/system/xyz.openbmc_project.Dump.Manager.service; enabled; preset: enabled) Active: active (running) since Thu 2024-12-19 13:27:21 PST; 7 months 15 days ago Invocation: 8ff137acc50f4d8299b5d999b886896d Process: 374 ExecStartPre=/bin/sh -c mkdir -p /var/lib/phosphor-debug-collector/dumps (code=exited, status=0/SUCCESS) Main PID: 479 (phosphor-dump-m) Tasks: 1 (limit: 4102) Memory: 1.5M (peak: 16.2M) CPU: 1min 58.037s CGroup: /system.slice/xyz.openbmc_project.Dump.Manager.service `-479 /usr/libexec/phosphor-debug-collector/phosphor-dump-manager
Aug 05 04:33:35 bmc phosphor-dump-manager[479]: Initiating new BMC dump with type: core path: /var/lib/systemd/coredump/core.devmem.0.0b7096e8ddc54ce9a7...3000000.zst Aug 05 04:33:40 bmc phosphor-dump-manager[2926]: cp: can't stat '/var/lib/systemd/coredump/core.devmem.0.0b7096e8ddc54ce9a7799c4d23eea94a.2881.175439361...r directory Aug 05 04:33:58 bmc phosphor-dump-manager[2887]: Tue Aug 5 11:33:58 UTC 2025 Report is available in /var/lib/phosphor-debug-collector/dumps/6 Aug 05 04:33:59 bmc phosphor-dump-manager[2887]: Tue Aug 5 11:33:59 UTC 2025 Successfully completed Aug 05 04:35:41 bmc phosphor-dump-manager[479]: OriginatorId is not provided Aug 05 04:35:41 bmc phosphor-dump-manager[479]: OriginatorType is not provided. Replacing the string with the default value Aug 05 04:35:41 bmc phosphor-dump-manager[479]: Initiating new BMC dump with type: core path: /var/lib/systemd/coredump/core.devmem.0.0b7096e8ddc54ce9a7...9000000.zst Aug 05 04:35:46 bmc phosphor-dump-manager[3322]: cp: can't stat '/var/lib/systemd/coredump/core.devmem.0.0b7096e8ddc54ce9a7799c4d23eea94a.3278.175439373...r directory Aug 05 04:36:10 bmc phosphor-dump-manager[3284]: Tue Aug 5 11:36:10 UTC 2025 Report is available in /var/lib/phosphor-debug-collector/dumps/7 Aug 05 04:36:11 bmc phosphor-dump-manager[3284]: Tue Aug 5 11:36:11 UTC 2025 Successfully completed Hint: Some lines were ellipsized, use -l to show in full. root@bmc:~# systemctl status obmc-dump-monitor.service * obmc-dump-monitor.service - Phosphor Dump core monitor. Loaded: loaded (/usr/lib/systemd/system/obmc-dump-monitor.service; enabled; preset: enabled) Active: active (running) since Thu 2024-12-19 13:26:44 PST; 7 months 15 days ago Invocation: eeeb2b3224f54287995e8bd9a022d255 Main PID: 350 (phosphor-dump-m) Tasks: 1 (limit: 4102) Memory: 276K (peak: 800K) CPU: 650ms CGroup: /system.slice/obmc-dump-monitor.service `-350 /usr/libexec/phosphor-debug-collector/phosphor-dump-monitor
Dec 19 13:26:44 bmc systemd[1]: Started Phosphor Dump core monitor.. root@bmc:~# systemctl status ramoops-monitor.service * ramoops-monitor.service - Ramoops monitor. Loaded: loaded (/usr/lib/systemd/system/ramoops-monitor.service; enabled; preset: enabled) Active: inactive (dead) Condition: start condition unmet at Thu 2024-12-19 13:27:39 PST; 7 months 15 days ago `- ConditionPathExistsGlob=/var/lib/systemd/pstore/dmesg-ramoops-* was not met
Dec 19 13:27:39 bmc systemd[1]: Ramoops monitor. was skipped because of an unmet condition check (ConditionPathExistsGlob=/var/lib/systemd/pstore/dmesg-ramoops-*). ```
Change-Id: I23b67ac5651569cc2cefaa29f421bc42c3965741 Signed-off-by: William de Abreu Pinho <williamdapinho@gmail.com>
show more ...
|