Auto-checking of file systems

Randy Jarrett WA4MEI rsj at wa4mei.UUCP
Sun Dec 4 13:20:55 AEST 1988


In article <683 at wa3wbu.UUCP> john at wa3wbu.UUCP (John Gayman) writes:
>
>   What do I have to modify in Sys V/AT to have it run fsck on all file
>systems, including root, at power up regardless of wether the previous
>shutdown was normal or not. I've looked through the files run in inittab
>and its not real clear. Thanks.   
>					John

In the file /etc/mountall comment out three lines in the following group
that are marked with #xxx.


XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
" /etc/mountall "

		#	First check file system state and repair if necessary.
		msg=`/etc/fsstat ${dev} 2>&1`
#xxx		if [ $? -ne 0 ]
#xxx		then
			echo "
	${msg}
	${dev} is being checked automatically."
			/etc/fsck -y -t /fsck.tmp -D ${dev}
#xxx		fi

		/etc/mount ${dev} ${fs} ${readonly}
	done

And then three lines in bcheckrc to force the checking of /dev/dsk/0s0

" end of /etc/mountall "
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

" /etc/bcheckrc "

msg=`/etc/fsstat ${rootfs} 2>&1`

#xxx if [ $? -ne 0 ]
#xxx then
	echo "
	${msg}
	The root file system (${rootfs}) is being checked automatically."
	/etc/fsck -y -D -b ${rootfs}
#xxx fi

" end of bcheckrc "
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX


Doing the three lines in each file will force the use of fsck on each filesystem everytime you boot your system


-- 
Randy Jarrett  WA4MEI 
UUCP  ...!gatech!wa4mei!rsj        | US SNAIL: P.O. Box 941217
PHONE +1 404 493 9017		   |           Atlanta, GA 30341-0217



More information about the Comp.unix.microport mailing list