[systemd-devel] Problems with rootfs over nfs

Kay Sievers kay.sievers at vrfy.org
Sun May 15 07:16:30 PDT 2011


On Sun, May 15, 2011 at 12:49, Mariusz Bialonczyk <manio at skyboo.net> wrote:
> Last time I gave a try to systemd as my init replacement. I am using it on
> debian sid system (systemd is from experimental), My rootfs is on NFS share
> (I have "ip=dhcp root=/dev/nfs and nfsroot=..." appended as kernel parameters).
> First problem in my configuration is remounting my root filesystem.
> It cannot remount it in read-write because systemd is remounting it with the
> following command:
> mount -o remount /
> and this gives the following error during bootup:
> mount.nfs: remote share not in 'host:dir' format
>
> so I have to patch /lib/systemd/system/remount-rootfs.service it like this:
>
> --- remount-rootfs.service.original     2011-04-28 21:20:45.000000000 +0200
> +++ remount-rootfs.service      2011-05-14 18:09:13.254955918 +0200
> @@ -15,5 +15,5 @@
>  [Service]
>  Type=oneshot
>  RemainAfterExit=yes
> -ExecStart=/bin/mount / -o remount
> +ExecStart=/bin/mount /dev/nfs / -o remount
>  StandardOutput=syslog
>
> After reboot my rootfs was remounted correctly in rw mode. I know this is a
> specific and ugly workaround, but my point is to report this as an issue.

What's in fstab for /? Maybe just that needs a fix for mount(8) to
understand what we do here.

> Just by the way: my system is starting up in about 25 seconds with sysvinit,
> while with systemd it took about 20 seconds. Nice :)

Nice.

> Second issue is the powering down the machine. My sysvinit has no problems
> with this. I took a photo of last onscreen messages:
> http://skyboo.net/systemd/sysvinit.png
> After this the computer is properly powered down.
>
> While using systemd i've got the following:
> http://skyboo.net/systemd/systemd.png
> It seems that the kernel is trying to pull some data from NFS server and it
> is not responding (don't know why - maybe the NIC was deconfigured too early,
> or rootfs unmounted)... and it hung like this forever - so the only way to
> power off is holding the power button :(
>
> If you need further info, please let me know, I'll try to provide
> as much as I can.

Just a first quick check of an issue we ran into with ATA disks:
what's in /proc/sys/kernel/hotplug before you shut down? Or what's
CONFIG_UEVENT_HELPER in your kernel setup, it must be ="" on modern
systems, otherwise the kernel will they to exec() binaries all the
time and keep the system's rootfs busy.

Kay


More information about the systemd-devel mailing list