|
|
|
@ -14,20 +14,3 @@
|
|
|
|
|
. /etc/initrd.d/00-suspend.sh
|
|
|
|
|
. /etc/initrd.d/00-iscsi.sh
|
|
|
|
|
. /etc/initrd.d/00-rootdev.sh
|
|
|
|
|
|
|
|
|
|
# If devtmpfs is mounted, try move it to the new root
|
|
|
|
|
# If that fails, try to unmount all possible mounts of devtmpfs as
|
|
|
|
|
# stuff breaks otherwise
|
|
|
|
|
move_mounts_to_chroot() {
|
|
|
|
|
for fs in /run /dev /sys /proc; do
|
|
|
|
|
if grep -qs "$fs" /proc/mounts; then
|
|
|
|
|
local chroot_dir="${CHROOT}${fs}"
|
|
|
|
|
mkdir -p "${chroot_dir}"
|
|
|
|
|
if ! mount --move $fs "${chroot_dir}"
|
|
|
|
|
then
|
|
|
|
|
umount $fs || \
|
|
|
|
|
bad_msg "Failed to move and umount $fs!"
|
|
|
|
|
fi
|
|
|
|
|
fi
|
|
|
|
|
done
|
|
|
|
|
}
|
|
|
|
|