On Fri, 19.12.14 10:58, Baoquan He ([email protected]) wrote: > Hi, > > Now I encountered a prlblem. When I add an entry in /etc/fstab to mount > a disk on a dir like below, mount can be done successfully though /aa/bb > doesn't exist. > _ _ _ _ _ > /dev/disk/by-uuid/xxx-xxx /aa/bb xfs defaults 0 2 > > > However when I make a initramfs for kdump kernel, I add an entry to > $mntimg/etc/fstab like below, mount will fail if /sysroot/var/crash > doesn't exist. > _ _ _ _ _ > /dev/disk/by-uuid/xxx-xxx /sysroot/var/crash xfs > rw,relatime,...,x-initrd.mount 0 2 > > Does anyone know why this happen and how to fix it, or any > suggestion/idea?
First of all, you really shouldn't access /sys/root/var from the initrd. /var is a directory that if split out is mounted after the transition to the host. Hence, if you try to access it from the initrd, you actively break setups with /var split out. Now, my guess that the reason that your code fails is that /sysroot/ is read-only when your code is invoked, and hence the subdir cannot be created. Lennart -- Lennart Poettering, Red Hat _______________________________________________ systemd-devel mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/systemd-devel
