diff options
author | Fernando Reyes (likewhoa) <design@missionaccomplish.com> | 2014-05-29 10:15:13 +0200 |
---|---|---|
committer | Fernando Reyes (likewhoa) <design@missionaccomplish.com> | 2014-06-24 01:11:14 +0200 |
commit | 854a835ede60717a9b4ac847b5e3e56877c35338 (patch) | |
tree | c7771ca503b293e7359caac190775d9c6a202c14 | |
parent | This fixes /etc/fstab from not working while in setup_aufs function and instead (diff) | |
download | genkernel-854a835ede60717a9b4ac847b5e3e56877c35338.tar.gz genkernel-854a835ede60717a9b4ac847b5e3e56877c35338.tar.bz2 genkernel-854a835ede60717a9b4ac847b5e3e56877c35338.zip |
Removing --bind on some directories to prevent ${NEW_ROOT} path
from existing in favor of --move.
Got rid of the no longer required subshell call for aufs ${NEW_ROOT}
overlay.
-rw-r--r-- | defaults/initrd.scripts | 11 | ||||
-rw-r--r-- | defaults/linuxrc | 7 |
2 files changed, 6 insertions, 12 deletions
diff --git a/defaults/initrd.scripts b/defaults/initrd.scripts index bf4124f..aded9ad 100644 --- a/defaults/initrd.scripts +++ b/defaults/initrd.scripts @@ -1363,10 +1363,9 @@ getdvhoff() { } setup_squashfs_aufs() { - ( # Setup aufs directories and vars - local overlay=/mnt/overlay - local static=/mnt/livecd + overlay=/mnt/overlay + static=/mnt/livecd for i in "${overlay}" "${static}"; do [ ! -d "${i}" ] && mkdir -p "${i}" @@ -1381,12 +1380,6 @@ setup_squashfs_aufs() { [ ! -d "${NEW_ROOT}${overlay}" ] && mkdir -p "${NEW_ROOT}${overlay}" [ ! -d "${NEW_ROOT}${static}" ] && mkdir -p "${NEW_ROOT}${static}" for i in "${overlay}" "${static}"; do mount --move "${i}" "${NEW_ROOT}${i}"; done - - # have handy /mnt/cdrom (CDROOT_PATH) as well - local new_cdroot="${NEW_ROOT}${CDROOT_PATH}" - [ ! -d "${new_cdroot}" ] && mkdir -p "${new_cdroot}" - mount --bind "${CDROOT_PATH}" "${new_cdroot}" - ) } setup_unionfs() { diff --git a/defaults/linuxrc b/defaults/linuxrc index d5b424c..0a91c58 100644 --- a/defaults/linuxrc +++ b/defaults/linuxrc @@ -995,7 +995,7 @@ then mkdir -p /${CHROOT}/.unions/memory mount -o move /memory /${CHROOT}/.unions/memory test_success "Failed to move aufs /memory into the system root" - for i in mnt/gentoo mnt/livecd ${CDROOT_PATH} + for i in mnt/gentoo mnt/livecd /mnt/overlay ${CDROOT_PATH} do mkdir -p ${CHROOT}/$i chmod 755 ${CHROOT}/$i @@ -1012,8 +1012,9 @@ then warn_msg "${str}are mounted in ram" warn_msg "consider saving important files elsewhere..." read -t 3 UNUSEDVAL - mount --bind ${NEW_ROOT}${CDROOT_PATH} ${CHROOT}${CDROOT_PATH} - mount --bind ${NEW_ROOT}/mnt/livecd ${CHROOT}/mnt/livecd + for i in ${CDROOT_PATH} ${overlay} ${static}; do + mount --move ${NEW_ROOT}${i} ${CHROOT}${i} + done fi good_msg "Booting (initramfs)" |