Thread View: linux.debian.bugs.dist
1 messages
1 total messages
Started by Kai Ma
Sat, 07 Nov 2026 17:40
Bug#1153356: checkrestart: index out of range for podman conmon cgroup under machine.slice
Author: Kai Ma
Date: Sat, 07 Nov 2026 17:40
Date: Sat, 07 Nov 2026 17:40
102 lines
4971 bytes
4971 bytes
Package: debian-goodies
Version: 0.88.2
Severity: normal
X-Debbugs-Cc: justksqsf@gmail.com
Dear Maintainer,
Running checkrestart as root fails with:
Traceback (most recent call last):
File "/usr/sbin/checkrestart", line 1292, in <module>
main()
File "/usr/sbin/checkrestart", line 383, in main
u=SystemdUnit(unit)
File "/usr/sbin/checkrestart", line 1186, in __init__
self.unit_slice=self.cgroup_path[4]
IndexError: list index out of range
The machine runs Podman containers. By instrumenting
SystemdUnit.__init__ in memory and rerunning checkrestart, I confirmed
that the failing cgroup is of the following form (IDs redacted):
0::/machine.slice/machine-libpod_pod_PODID.slice/libpod-conmon-CONTAINERID.scope
This belongs to a Podman conmon process.
SystemdUnit splits this string on "/", producing four elements.
The machine.slice branch then unconditionally accesses element [4],
apparently assuming a deeper hierarchy such as:
0::/machine.slice/machine-NAME.scope/payload/system.slice/example.service
A minimal reproduction using the installed script is:
python3 - <<'EOF'
import runpy
m = runpy.run_path("/usr/sbin/checkrestart", run_name="checkrestart_test")
m["SystemdUnit"](
"0::/machine.slice/machine-libpod_pod_TEST.slice/"
"libpod-conmon-TEST.scope"
)
EOF
Expected result:
checkrestart handles this cgroup layout without crashing, or reports
that it cannot determine a restart command and continues checking
other processes.
Actual result:
An uncaught IndexError aborts the check.
The same indexing logic was also present in upstream master when
checked.
Best regards,
Kai
-- System Information:
Debian Release: 13.7
APT prefers stable-updates
APT policy: (500, 'stable-updates'), (500, 'stable-security'), (500, 'stable')
Architecture: amd64 (x86_64)
Kernel: Linux 6.12.115+deb13.1-cloud-amd64 (SMP w/2 CPU threads; PREEMPT)
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8), LANGUAGE not set
Shell: /bin/sh linked to /usr/bin/dash
Init: systemd (via /run/systemd/system)
LSM: AppArmor: enabled
debian-goodies depends on no packages.
Versions of packages debian-goodies recommends:
ii apt 3.0.4
ii curl 8.14.1-2+deb13u7
ii dctrl-tools 2.24-3+b1
pn elfutils <none>
pn equivs <none>
pn libfile-slurper-perl <none>
pn libfile-which-perl <none>
ii libipc-system-simple-perl 1.30-2
ii man-db 2.13.1-1
ii perl 5.40.1-6+deb13u1
pn popularity-contest <none>
ii procps 2:4.0.4-9
ii python3 3.13.5-1
ii sensible-utils 0.0.25
ii whiptail 0.52.25-1
Versions of packages debian-goodies suggests:
pn apt-file <none>
pn ccze <none>
pn debsums <none>
pn konqueror <none>
ii lsb-release 12.1-1
ii lsof 4.99.4+dfsg-2
ii openssh-client 1:10.0p1-7+deb13u4
ii sudo 1.9.16p2-3+deb13u2
pn x-www-browser | www-browser <none>
ii xdg-utils 1.2.1-2
-- no debconf information
Thread Navigation
This is a paginated view of messages in the thread with full content displayed inline.
Messages are displayed in chronological order, with the original post highlighted in green.
Use pagination controls to navigate through all messages in large threads.
Back to All Threads