* Run `swapoff -a' during shutdown. Otherwise filesystems containing
swapfiles cannot be unmounted or even remounted read-only. * In the remount, pass `-t none' to get a more informative error message if the filesystem is in use. svn path=/nixos/branches/boot-order/; revision=22179
This commit is contained in:
parent
48fdc931a4
commit
23cc979f61
@ -65,6 +65,10 @@ with pkgs.lib;
|
||||
hwclock --systohc --utc
|
||||
|
||||
|
||||
# Stop all swap devices.
|
||||
swapoff -a
|
||||
|
||||
|
||||
# Unmount helper functions.
|
||||
getMountPoints() {
|
||||
cat /proc/mounts \
|
||||
@ -99,7 +103,7 @@ with pkgs.lib;
|
||||
# `-i' is to workaround a bug in mount.cifs (it
|
||||
# doesn't recognise the `remount' option, and
|
||||
# instead mounts the FS again).
|
||||
mount -n -i -o remount,ro "$mp"
|
||||
mount -t none -n -i -o remount,ro none "$mp"
|
||||
|
||||
# Note: don't use `umount -f'; it's very buggy.
|
||||
# (For instance, when applied to a bind-mount it
|
||||
|
Loading…
x
Reference in New Issue
Block a user