aboutsummaryrefslogtreecommitdiff
path: root/etc
diff options
context:
space:
mode:
authorDoug Barton <dougb@FreeBSD.org>2001-02-05 04:54:42 +0000
committerDoug Barton <dougb@FreeBSD.org>2001-02-05 04:54:42 +0000
commit385a585a4bc1493cbd873a13f3b9d8919dab5ef4 (patch)
tree6033865a266831bbe667ee36d02626c85d0ca708 /etc
parenteabf71899fd55a3857df2e838493ec87d5649b8a (diff)
Notes
Diffstat (limited to 'etc')
-rw-r--r--etc/defaults/rc.conf1
-rw-r--r--etc/rc20
2 files changed, 19 insertions, 2 deletions
diff --git a/etc/defaults/rc.conf b/etc/defaults/rc.conf
index 7fd9a5272cde8..6e2775a2e6223 100644
--- a/etc/defaults/rc.conf
+++ b/etc/defaults/rc.conf
@@ -31,6 +31,7 @@ pccardd_flags="" # Additional flags for pccardd.
pccard_conf="/etc/defaults/pccard.conf" # pccardd(8) config file
local_startup="/usr/local/etc/rc.d /usr/X11R6/etc/rc.d" # startup script dirs.
rc_conf_files="/etc/rc.conf /etc/rc.conf.local"
+fsck_y_enable="NO" # Set to YES to do fsck -y if the initial preen fails.
##############################################################
### Network configuration sub-section ######################
diff --git a/etc/rc b/etc/rc
index fefeed38d5067..3155f34a4e246 100644
--- a/etc/rc
+++ b/etc/rc
@@ -157,8 +157,24 @@ autoboot)
exit 1
;;
8)
- echo 'Automatic file system check failed... help!'
- exit 1
+ case ${fsck_y_enable} in
+ [Yy][Ee][Ss])
+ echo 'File system preen failed, trying fsck -y . . .'
+ fsck -y
+ case $? in
+ 0)
+ ;;
+ *)
+ echo 'Automatic file system check failed . . . help!'
+ exit 1
+ ;;
+ esac
+ ;;
+ *)
+ echo 'Automatic file system check failed . . . help!'
+ exit 1
+ ;;
+ esac
;;
12)
echo 'Reboot interrupted'