I have an embedded linux system. I use grub2 for the boot loader. I would like to run an fsck -y /dev/sda on /dev/sda every time it boots--even when the system had a power loss and the reboot command was not used. How can I do this?
Tell me more
×
Server Fault is a question and answer site for
professional system and network administrators. It's 100% free, no registration required.
|
|
Are you using a particular distribution? On Debian based distributions it would be as simple as adjusting If you want to force a full fsck after every boot, then you could simply write create an empty file named |
|||||||||||
|
|
If there had been a power loss fsck will run anyway since the filesystem will not be marked as "clean". You can use |
|||||||||||
|