Admin-Ahead Community

Linux => General Linux => Topic started by: Aby on April 26, 2014, 09:06:52 pm

Title: How to Force Linux Box to fsck on the Next Reboot
Post by: Aby on April 26, 2014, 09:06:52 pm
How to Force Linux Box to fsck on the Next Reboot

Fsck or file system check is used to check and repair one or more Linux file systems. To force your Linux box to run file system check, all you need to do is to just create an empty file /forcefsck.

1. Login to server as root via ssh

2. Navigate to “/”
# cd /

3. Create an empty file forcefsck
#touch /forcefsck

4. Reboot the server
#reboot

You can use the following single command as well to force fsck after reboot.
#shutdown -rF now

=====