Answer: How to perform a *SAFE* file system check on /dev/md1?

Thank-you to WD for a quick answer to the problem.

The other issue encountered was that the option to scan the volume(s) also got stuck on the Initializing status and would not proceed so the file system check had to be performed manually.

https://support-en.wd.com/app/answers/detail/a_id/30057

For me the instruction to use /usr/bin/e2fsck /dev/md1 didn’t work. I had to use e2fsck /dev/md1

The file system check completed successfully.

My question was:

What I’m looking for is how to safely force a file system check on a volume while the NAS is starting up and I need someone with a lot of experience on how fsck and e2fsck work.

I refer you to: 7 UNIX / Linux tune2fs Command Examples for EXT2, EXT3, EXT4 Filesystem Parameters and >Linux tune2fs command examples.

This is what I was thinking …

Currently /dev/md1 is set for: Maximum mount count: -1

Could I end-up with a NAS that won’t start if I do this.

  1. Use tune2fs -c 1 /dev/md1
  2. Restart the NAS
  3. Use tune2fs -c -1 /dev/md1

Will e2fsck always run in non-interactive mode while running at start-up so as to not stop the start-up process by asking for a response from the user that it can’t get.