]> git.pld-linux.org Git - projects/rc-scripts.git/blobdiff - rc.d/rc.shutdown
Skip cgroup/cgroup2 fs, too.
[projects/rc-scripts.git] / rc.d / rc.shutdown
index d86f962e8d6d94039069a8404a06656c26d1eb90..a3807dd79595195fb1053782b646b58892fa3a62 100755 (executable)
@@ -77,12 +77,12 @@ if ! is_yes "$VSERVER"; then
                UMOUNT_IGNORE="/ $UMOUNT_IGNORE"
        fi
        remaining=$(awk -v ig="^($UMOUNT_IGNORE)$" 'BEGIN { gsub(/[\t ]+/, "|", ig); } \
-                       $3 !~ /^(proc|loopfs|devpts|devtmpfs|shm|iso9660|ramfs|tmpfs|sysfs|securityfs|squashfs)$/ \
+                       $3 !~ /^(proc|loopfs|devpts|devtmpfs|shm|iso9660|ramfs|tmpfs|cgroup|cgroup2|sysfs|securityfs|squashfs)$/ \
                        && $1 !~ /^(none|\/dev\/root)$/ \
                        && $2 !~ ig {print $2}' /proc/mounts)
        while [ -n "$remaining" -a "$retry" -gt 0 ]; do
                show "Unmounting file systems"; busy
-               ERRORS=$(umount -a $force -t noproc 2>&1); rc=$?
+               ERRORS=$(umount -a $force -t noproc,nosysfs 2>&1); rc=$?
 
                # we might had unmounted /usr, recheck $TPUT availability
                # but well. we need tput only for show() and busy() (ok() and fail() messages are already cached)
@@ -101,7 +101,7 @@ if ! is_yes "$VSERVER"; then
 
                sleep 2
                remaining=$(awk -v ig="^($UMOUNT_IGNORE)$" 'BEGIN { gsub(/[\t ]+/, "|", ig); } \
-                               $3 !~ /^(proc|loopfs|devpts|devtmpfs|shm|iso9660|ramfs|tmpfs|sysfs|securityfs|squashfs)$/ \
+                               $3 !~ /^(proc|loopfs|devpts|devtmpfs|shm|iso9660|ramfs|tmpfs|cgroup|cgroup2|sysfs|securityfs|squashfs)$/ \
                                && $1 !~ /^(none|\/dev\/root)$/ \
                                && $2 !~ ig {print $2}' /proc/mounts)
                [ -z "$remaining" ] && break
@@ -117,7 +117,7 @@ if ! is_yes "$VSERVER"; then
        if [ -x /sbin/vgchange ]; then
                lvmversion=$(LC_ALL=C /sbin/vgchange --version 2>/dev/null | awk '/LVM version:/{if ($3 >= 2) print "2"}')
                if [ "$lvmversion" = "2" ]; then
-                       lvmsysinit="--sysinit"
+                       lvmsysinit="--sysinit --noudevsync"
                else
                        lvmsysinit=""
                fi
This page took 0.022705 seconds and 4 git commands to generate.