HOWTO: Forcing a filesystem check

Ubuntu makes a filesystem check every 30 boots or something. If for any case, you want a filesystem check you can do it by issuing the following command:

shutdown -rF now

This command will restart Ubuntu and will make a filesystem check.

4 Responses to “HOWTO: Forcing a filesystem check”

  1. NetOperator Wibby Says:

    Thank you *so* much for this!

  2. Peter Piper Says:

    I noticed that ‘F’ is not one of the options shown in ’shutdown –help’ (see below). How would anyone know that the F option exists if ’shutdown –help’ doesn’t show it?

    shutdown –help
    Usage: shutdown [OPTION]… TIME [MESSAGE]
    Bring the system down.

    Options:
    -r reboot after shutdown
    -h halt or power off after shutdown
    -H halt after shutdown (implies -h)
    -P power off after shutdown (implies -h)
    -c cancel a running shutdown
    -k only send warnings, don’t shutdown
    -q, –quiet reduce output to errors only
    -v, –verbose increase output to include informational messages
    –help display this help and exit
    –version output version information and exit

  3. Martin Says:

    sudo shoutdown -Fr now

    did nothing but reboot for me. Im on Ubuntu 8.04.

  4. jordilin Says:

    Well, aparently the -F option is no longer available. You can do sudo touch /forcefsck (just places and empty file in /) and then restart normally. Then, the operating system will perform a filesystem check

Leave a Reply