mirror of
https://github.com/freebsd/freebsd-src
synced 2024-10-07 00:50:50 +00:00
growfs_fstab startup script: set dumpdev to AUTO
The growfs_fstab script has been testing dumpdev, and if it is AUTO, enables dumps on the newly-added swap device for the initial boot. However, dumpdev defaults to AUTO on main, but NO on stable/13 and release branches. On the other hand, bsdinstall adds dumpdev="AUTO" by default (controlled by a menu item). bsdinstall is not used when booting an SD card or other disk image. Adopt the default from bsdinstall, and set dumpdev to AUTO in /etc/rc.conf in the growfs_fstab script if a swap partition has been added, along with the explanatory comment added by bsdinstall. Differential Revision: https://reviews.freebsd.org/D38751
This commit is contained in:
parent
8866ea619a
commit
eef9f9900f
|
@ -51,14 +51,9 @@ growfs_fstab_start()
|
|||
' < /etc/fstab
|
||||
then
|
||||
printf "/dev/label/growfs_swap\tnone\t\tswap\tsw\t\t0\t0\n" >>/etc/fstab
|
||||
|
||||
case "$dumpdev" in
|
||||
[Aa][Uu][Tt][Oo])
|
||||
dumpon $dumpon_flags /dev/label/growfs_swap
|
||||
;;
|
||||
*)
|
||||
;;
|
||||
esac
|
||||
printf '# Set dumpdev to "AUTO" to enable crash dumps, "NO" to disable\n' >>/etc/rc.conf
|
||||
printf 'dumpdev="AUTO"\n' >>/etc/rc.conf
|
||||
dumpon $dumpon_flags /dev/label/growfs_swap
|
||||
fi
|
||||
fi
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue