Fsck

From ArchWiki
Revision as of 20:39, 25 August 2008 by Ejmarkow (Talk | contribs) (Fsck - Definition and running it manually, the easy way)

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

Fsck

What is Fsck?

Fsck is used to check and optionally repair one or more Linux file systems. A filesystem can be a device name (e.g. /dev/hdc1, /dev/sdb2), a mountpoint (e.g. /, /usr, /home), or an ext2 label or UUID specifier (e.g. UUID=8868abf6-88c5-4a83-98b8-bfc24057f7bd or LABEL=root). Normally, the Fsck program will try to handle filesystems on different physical disk drives in parallel to reduce the total amount of time needed to check all of the filesystems. (Source: man fsck)

The Arch Linux boot process conveniently takes care of the Fsck process for you and will periodically check all relevant partitions on your hard drive automatically in a scheduled manner. Hence, there is usually is no need to resort to the command line unless necessary.

Invoking Fsck Manually - The Easy Way

Suppose you opt to run a full Fsck check manually on your next system reboot. This can be done very easily with one command in Arch Linux. First, exit your window manager, log into root (#), and type the following command:

# shutdown -Fr now

The command shutdown will bring down the system in a secure manner, -F forces fsck to be safely invoked on a reboot, -r causes the system to reboot after shutdown, and now shuts down the system immediately.

Enter the command above and press ENTER. The system will reboot immediately. When your Grub menu appears (assuming you are using it), enter Arch Linux like you normally do. During the boot process, you will see that Fsck has been invoked and checks all relevant partitions on your hard drive. This manual procedure is simple, fast, and hassle free.