29.01.2016 17:55, Frank Steiner пишет: > Hi, > > this problem occurs in SLES 12 with systemd-210-70.30.1 which might be > to old to handle this situation correctly. So my question is if the > following situation should work in systemd or for some reason would not > (so that I can plan how to get around this). > > We have two entries in /etc/fstab: > > /dev/mapper/raid2--iscsi-backup--export /export2 xfs > defaults,_netdev 0 0 > /export2/rpm /nfsv4/rpm-export none bind,private,_netdev 0 0 > > I.e., we mount an iscsi device and then export part of it with nfs4, > so we need the bind-mount. But while both entries are correctly delayed > due to the _netdev, they both start to mount in parallel and the bind > mount is faster than the iscsi, of course. > > ... > [ OK ] Reached target Remote File Systems (Pre). > [ OK ] Reached target Network is Online. > Starting Login and scanning of iSCSI devices... > Mounting /nfsv4/rpm-export... > [ OK ] Mounted /nfsv4/rpm-export. > [ OK ] Started Login and scanning of iSCSI devices. > ... > [ OK ] Found device /dev/mapper/raid2--iscsi-backup--export. > [ OK ] Started Activation of LVM2 logical volumes. > Mounting /export2... > [ OK ] Mounted /export2. > ... > > In http://www.freedesktop.org/software/systemd/man/systemd.mount.html > I found the information "If a mount unit is beneath another mount unit > in the file system hierarchy, both a requirement dependency and an > ordering dependency between both units are created automatically." > > This sounds like it should work in the scenario as /export2/rpm is > clearly beneath /export2. But there are no matching depencendies > in the the /run/systemd/generator/*.mount files. So is it safe to > assume the error only occurs due to the old systemd version? >
These dependencies are added internally, they are not found in any on-disk unit files. Check with "systemctl show mount-unit". > In the current release, should this work automatically by adding > dependencies in the generated mount files or would I have to > add "x-systemd.requires-mounts-for" (which my systemd doesn't know > about...) explicitely in fstab? > This should work in your version as well. If it does not, the only idea I have is that /export2/rpm unit is processed before /export2 and so does not "know" about this dependency yet. _______________________________________________ systemd-devel mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/systemd-devel
