[systemd-devel] Running a x86_64 kernel on Fedora 15 x86 userland

Thomas Meyer thomas at m3y3r.de
Sun Sep 11 01:04:37 PDT 2011


Hello.

Again I tried to run an x86_64 kernel on Fedora 15 x86 user land, but I
encounter a problem with the automount points and the actual
mounting.

When accessing the automount directory, systemd catches an event and
starts the actual mount job. this mount job seems to correctly call
comapt_sys_mount system call (eax == 0 when leaving this function).
but somehow the mount process is leftover as a zombie process.

here the systemd debug log:

1.) I boot into systemd emergency mode:

> [  117.134138] systemd[1]: Successfully opened /dev/kmsg for logging.
> [  117.134163] systemd[1]: systemd 26 running in system mode. (+PAM +LIBWRAP +AUDIT +SELINUX +SYSVINIT +LIBCRYPTSETUP; fedora)

[...]

> [  120.130677] systemd[1]: Job emergency.target/start finished, result=done
> [  120.131162] systemd[1]: Startup finished in 4s 88ms 251us (kernel) + 1min 53s 430ms 582us (initrd) + 2s 611ms 858us (userspace) = 2min 130ms 691us.
> [  120.133750] systemd[1]: Accepted connection on private bus.
> [  120.134823] systemd[1]: Got D-Bus request: org.freedesktop.systemd1.Agent.Released() on /org/freedesktop/systemd1/agent
> [  120.135237] systemd[1]: Got D-Bus request: org.freedesktop.DBus.Local.Disconnected() on /org/freedesktop/DBus/Local
> [  164.349155] systemd[1]: Accepted connection on private bus.
> [  164.350962] systemd[1]: Got D-Bus request: org.freedesktop.systemd1.Manager.StartUnit() on /org/freedesktop/systemd1
> [  164.354038] systemd[1]: Got D-Bus request: org.freedesktop.DBus.Local.Disconnected() on /org/freedesktop/DBus/Local

2.)start an automount point:

# systemctl start dev-hugpages.automount

> [  170.774923] systemd[1]: Accepted connection on private bus.
> [  170.776555] systemd[1]: Got D-Bus request: org.freedesktop.systemd1.Manager.StartUnit() on /org/freedesktop/systemd1
> [  170.776591] systemd[1]: Trying to enqueue job dev-hugepages.automount/start/replace
> [  170.776625] systemd[1]: Installed new job dev-hugepages.automount/start as 65
> [  170.776641] systemd[1]: Enqueued job dev-hugepages.automount/start as 65
> [  170.778160] systemd[1]: Autofs kernel version 1.0
> [  170.781899] SELinux: initialized (dev autofs, type autofs), uses genfs_contexts
> [  170.783105] systemd[1]: Autofs protocol version 5.2
> [  170.783161] systemd[1]: dev-hugepages.automount changed dead -> waiting
> [  170.783195] systemd[1]: Job dev-hugepages.automount/start finished, result=done
> [  170.783710] systemd[1]: Got D-Bus request: org.freedesktop.systemd1.Manager.GetUnit() on /org/freedesktop/systemd1
> [  170.784543] systemd[1]: Got D-Bus request: org.freedesktop.DBus.Properties.Get() on /org/freedesktop/systemd1/unit/dev_2dhugepages_2eautomount
> [  170.786499] systemd[1]: Got D-Bus request: org.freedesktop.DBus.Local.Disconnected() on /org/freedesktop/DBus/Local

3.) try to cd into /dev/hugepages:

# cd /dev/hugepages

-> this command triggers the actual mount process and hangs, but can be interrupted with Ctrl+C.

> [  190.986967] systemd[1]: Got direct mount request for ffff8800708ea8c0, triggered by 396 (bash)
> [  190.988073] systemd[1]: Trying to enqueue job dev-hugepages.mount/start/replace
> [  190.988112] systemd[1]: Installed new job dev-hugepages.mount/start as 67
> [  190.988133] systemd[1]: Installed new job systemd-logger.socket/start as 68
> [  190.988148] systemd[1]: Enqueued job dev-hugepages.mount/start as 67
> [  190.988164] systemd[1]: dev-hugepages.automount changed waiting -> running
> [  190.992549] systemd[1]: SELinux Socket context for /lib/systemd/systemd-logger will be set to system_u:system_r:init_t:s0
> [  190.996618] systemd[1]: systemd-logger.socket changed dead -> listening
> [  190.996673] systemd[1]: Job systemd-logger.socket/start finished, result=done
> [  190.997667] systemd[1]: About to execute: /bin/mount hugetlbfs /dev/hugepages -t hugetlbfs
> [  191.006452] systemd[1]: Forked /bin/mount as 416
> [  191.006494] systemd[1]: dev-hugepages.mount changed dead -> mounting
> [  191.006528] systemd[1]: Running GC...
> [  191.440188] SELinux: initialized (dev hugetlbfs, type hugetlbfs), uses transition SIDs

the actual mount process 416 is left over as zombie:

$ cat /proc/416/status

> Name:	mount
> State:	Z (zombie)
> Tgid:	416
> Pid:	416
> PPid:	1
> TracerPid:	0
> Uid:	0	0	0	0
> Gid:	0	0	0	0
> FDSize:	0
> Groups:	
> Threads:	1
> SigQ:	1/15363
> SigPnd:	0000000000000000
> ShdPnd:	0000000000000000
> SigBlk:	0000000000000000
> SigIgn:	0000000000000000
> SigCgt:	0000000000000000
> CapInh:	0000000000000000
> CapPrm:	ffffffffffffffff
> CapEff:	ffffffffffffffff
> CapBnd:	ffffffffffffffff
> Cpus_allowed:	1
> Cpus_allowed_list:	0
> Mems_allowed:	1
> Mems_allowed_list:	0
> voluntary_ctxt_switches:	9
> nonvoluntary_ctxt_switches:	5

any ideas what is going on here? what can I do to debug this problem?

mounting the directory without the systemd autofs mount works correctly.

with kind regards
thomas



More information about the systemd-devel mailing list