Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

how to fsck automatically 1

Status
Not open for further replies.

redss

Programmer
Oct 20, 2002
195
how can I have my linux (slackware) box automatically run "e2fsck -y" ONLY upon getting errors when booting up?
thanks!
 
You can specify forced checking in /etc/fstab.
Like this:


code:--------------------------------------------------------------------------------
# <device> <mountpoint> <fstype> <opt> <dump> <fsckorder> <check>
/dev/hda1 / ext2 defaults 1 1 1
--------------------------------------------------------------------------------



SurFlite
MCSE,CCNA,CNA

 
ok, but will that invoke fsck with the -y option? I need e2fsck to AUTOMATICALLY be invoked with -y option, and no human intervention... so that when I boot up my computer (which is in my closet with no monitor) I won't have to hook a monitor up to the computer to type the fsck -y, when it could be done automatically.
 
Type e2fsck -f /dev/xxxx
where xxxx is your linux partition

The f switch will force checking even if the file system seems clean.


SurFlite
MCSE,CCNA,CNA

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top