LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Slackware (https://www.linuxquestions.org/questions/slackware-14/)
-   -   tune2fs passing arguments to e2fsck? (https://www.linuxquestions.org/questions/slackware-14/tune2fs-passing-arguments-to-e2fsck-4175437690/)

Geremia 11-18-2012 11:28 AM

tune2fs passing arguments to e2fsck?
 
How do I get tune2fs to pass certain arguments to e2fsck? Basically, I want e2fsck to use the directory sorting argument (-D) whenever tune2fs triggers fs checks at boot. Or would I have to create an e2fsck.conf file in /etc/?

Thanks

ljb643 11-19-2012 07:25 PM

Tune2fs will not help. It does not get involved in running the disk check at boot. (tune2fs just sets some parameters in the volume for use by other programs.)

I do not think you can do what you want. e2fsck.conf seems to have no option to control the directory optimization. It has to be specified in the e2fsck command line, which means you would have to do it manually.

rknichols 11-19-2012 08:23 PM

You would have to find the script that invokes the boot-time fsck (perhaps /etc/rc.d/rc.sysinit, but YMMV) and modify that to add the "-D" option.

ljb643 11-19-2012 09:05 PM

There is no such script. The check happens if the mount command (mount -a in rc.M) finds the filesystem needs checking.


All times are GMT -5. The time now is 06:24 PM.