I have created a systemd service file and placed it in /etc/systemd/system/anfragen-3dkonfig-mapper.service
. I ran systemctl daemon-reload
, systemctl daemon-reexec
and rebooted the system.
systemctl enable anfragen-3dkonfig-mapper
results inFailed to enable unit: Unit file anfragen-3dkonfig-mapper.service does not exist.
systemctl start anfragen-3dkonfig-mapper
results inFailed to start anfragen-3dkonfig-mapper.service: Unit anfragen-3dkonfig-mapper.service not found.
ls -lh /etc/systemd/system/anfragen-3dkonfig-mapper.service
outputs-rw-r--r--. 1 root root 440 Mar 19 12:08 /etc/systemd/system/anfragen-3dkonfig-mapper.service
cd /root && systemd-analyze verify anfragen-3dkonfig-mapper.service
has an exit code of 0 and prints no output.mount
shows/dev/sda2 on / type xfs (rw,relatime,seclabel,attr2,inode64,noquota)
There are no other mounts touching
/usr
or/etc
.The contents of the service file are:
[Unit] Description=Anfragen 3D Konfigurations Mapper Service After=network.target [Service] Restart=always ExecStartPre=-/usr/bin/podman stop anfragen-3dkonfig-mapper ExecStartPre=-/usr/bin/podman rm anfragen-3dkonfig-mapper ExecStart=/usr/bin/podman run --rm --name anfragen-3dkonfig-mapper-app -p 10010:10000 anfragen-3dkonfig-mapper-app:0.0.1 ExecStop=/usr/bin/podman stop anfragen-3dkonfig-mapper [Install] WantedBy=multi-user.target
All above commands were run as the
root
user.- Operating System: CentOS Linux release 8.0.1905 (Core)
- Systemd version: 239
- Linux kernel:
Linux version 4.18.0-80.11.2.el8_0.x86_64 ([email protected]) (gcc version 8.2.1 20180905 (Red Hat 8.2.1-3) (GCC))
- I vaguely remember having a similar problem with another service file some months ago which just magically started working after a few hours of poking around and renaming the service file back and forth.
I'm interested in two things:
- How does one debug such a problem?
- What is wrong?