On Jun 4, 2006, at 2:40 PM, Lawrence Horvath wrote:

How can i force normal boot up even if the filesystem was uncleanly dismounted,
i have a box that it looks like the HD is failing, but i still need
some of the info off it, so i would like to get it to boot normally
anyway so i can sftp/scp the files off it then i can replace the HD,
but it refuses boot anything but single user mode.

Thanks

--
-Lawrence

Don't think you can do that really because it's a failsafe with /etc/ rc. You may just want to try adding noauto to /etc/fstab for the time being so that booting doesn't halt on your system, then login and transfer all the data off your disk that you can. Since TERM isn't set in single-user mode, I've found learning how sed works is a very good thing to do. I believe this would fix your problem (can't test since my FBSD box has been down due to SCSI disk controller/PSU failure):

#!/bin/csh

FSTAB=/etc/fstab; #just a variable to reference the old fstab

if [ -ne $1 ]; then # the device filename length should be non-zero
        cp -p $FSTAB $FSTAB.tmp; #backup the old fstab
cat $FSTAB.tmp | sed -e s|^$1.*rw|$1.*rw,noauto|g > $FSTAB #replace rw for the old partition in fstab with rw,noauto
fi

-Garrett
_______________________________________________
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"

Reply via email to