[CLUE-Tech] file check other than at boot
Nate Duehr
nate at natetech.com
Thu Jun 10 18:26:43 MDT 2004
James LaRue wrote:
> A newbie question. If a Linux box does lock up, and is shut down
> uncleanly, a reboot offers to do a file check. What is the command to
> perform the same file integrity check, as root, from a terminal window?
The other answers about unmounting the filesystem (something you can't
do if your entire machine is one big "/" partition and you're booted
from that partition) are correct regarding fsck.
Also keep in mind that it's not a "file integrity" check, it's a
"filesystem integrity" check. In very extreme cases (usually when a
disk is sick and not writing things where it should anyway), fsck while
repairing the underlying filesystem can destroy "files" -- i.e. your
precious data.
You sometimes end up with recovered bits and pieces in your lost+found
directory for each mount point (with no filenames... lovely to sort
through) or you may just find things are gone forever.
In other words, fsck is a great tool, but it can't do your system
backups for you. ;-)
Nothing in the world beats the feeling that you have backups AND you've
restored them somewhere else and they worked during the test. :-) :-) :-)
If the data is worth money (work/production machines) it's inexcusable
for a professional admin not to have a backup, and nowadays you probably
want an "online" backup on another disk platter somewhere, an off-line
backup on some sort of removable media, and an off-site backup,
somewhere completely away from the building you're in -- in a safe place.
If it's at-home-I-don't-really-care-about-it data, the level of risk of
running without backups is up to the time, personality type, and sanity
level (or lack thereof when the drive fails -- remember ALL drives
eventually fail...) of the admin. (GRIN) Heh...
Nate Duehr, nate at natetech.com
More information about the clue-tech
mailing list