summary refs log tree commit diff
diff options
context:
space:
mode:
authorGraham Christensen <graham@grahamc.com>2017-07-16 16:54:54 -0400
committerGitHub <noreply@github.com>2017-07-16 16:54:54 -0400
commit8df6d351c40592547e3b00143a53667ec18ad47e (patch)
tree24ec474014067b3dbf3a46a560adf2af524d0298
parent653badee82d2e55120d706af41889f52e155143f (diff)
parent899e2b5748e7c2ea0a4f5c2dde74b15f15fe7e69 (diff)
downloadnixlib-8df6d351c40592547e3b00143a53667ec18ad47e.tar
nixlib-8df6d351c40592547e3b00143a53667ec18ad47e.tar.gz
nixlib-8df6d351c40592547e3b00143a53667ec18ad47e.tar.bz2
nixlib-8df6d351c40592547e3b00143a53667ec18ad47e.tar.lz
nixlib-8df6d351c40592547e3b00143a53667ec18ad47e.tar.xz
nixlib-8df6d351c40592547e3b00143a53667ec18ad47e.tar.zst
nixlib-8df6d351c40592547e3b00143a53667ec18ad47e.zip
Merge pull request #26912 from knedlsepp/fix-autoResize
nixos: Force check the filesystem before resizing
-rw-r--r--nixos/modules/system/boot/stage-1-init.sh1
1 files changed, 1 insertions, 0 deletions
diff --git a/nixos/modules/system/boot/stage-1-init.sh b/nixos/modules/system/boot/stage-1-init.sh
index 9a125dcb0aeb..1f4ab3eae07e 100644
--- a/nixos/modules/system/boot/stage-1-init.sh
+++ b/nixos/modules/system/boot/stage-1-init.sh
@@ -301,6 +301,7 @@ mountFS() {
         *x-nixos.autoresize*)
             if [ "$fsType" = ext2 -o "$fsType" = ext3 -o "$fsType" = ext4 ]; then
                 echo "resizing $device..."
+                e2fsck -fp "$device"
                 resize2fs "$device"
             fi
             ;;