Auto-detect possible file system corruption?


itimpi

Recommended Posts

There seem to be a significant number of cases recently in the forums where someone has formatted a disk flagged as ‘unmountable’ when in fact the correct action would have been to run a file system check/repair.   If one does not have backups in place this could lead to data loss that is avoidable if the correct recovery action had been taken.

 

A simple change would be to change the warning message given when format is selected to suggest that a file system check/repair might be a more appropriate action if the disk had previously mounted OK.  This would at least give visibility to new users that formatting is not the only way to clear the 'unmountable' status.

 

A more comprehensive change would be if UnRAID could track if a disk with a given serial in a given disk position was previously successfully mounted.  In such a case file system corruption become the most likely problem so the staus could be changed on such a mount failure to suggest that the first course of action should be to run a file system check (and thus a possible repair) rather than simply to format the disk.  

 

I would think this could cut down siginificantly on cases where the format was not the appropriate action.

 

 

Edited by itimpi
  • Upvote 2
Link to comment
  • 2 weeks later...
2 minutes ago, bonienl said:

What text message do you propose?

Good question!    At the moment I do not have any disks in a suitable state to bring up the warning so if you can remind me exactly what it currently says I will see if I can suggest a suitable wording.

 

I know I was thinking of adding text along the lines of “If this disk was previously mountable then an ‘unmountable’ state is frequently resolved by running a disk check/repair rather than using the format option”.  

Link to comment
29 minutes ago, itimpi said:

“If this disk's data slot was previously mountable then an ‘unmountable’ state is frequently resolved by running a disk check/repair rather than using the format option, which will erase any data that may be recoverable with a repair”.

FTFY. Sort of. I guess. People keep confusing disabled with unmountable, and assume the GUI option offered as a default will get their data back. The GUI says a format is needed, they format.

 

I would prefer unraid keep track of file system history by serial number, so repair options could be offered as a default with more digging in the UI necessary to format than to repair.

  • Upvote 1
Link to comment
7 minutes ago, jonathanm said:

I would prefer unraid keep track of file system history by serial number, so repair options could be offered as a default with more digging in the UI necessary to format than to repair.

That's good, but IMO if there's going to be a change it should also address when the user replaces a disk, which is probably when this mistake happens the most, since it's fairly common to have the disabled emulated disk go unmountable and then user formats the disk during the rebuild, and previous serial won't help with this.

Link to comment
11 minutes ago, jonathanm said:

FTFY. Sort of. I guess. People keep confusing disabled with unmountable, and assume the GUI option offered as a default will get their data back. The GUI says a format is needed, they format.

 

I would prefer unraid keep track of file system history by serial number, so repair options could be offered as a default with more digging in the UI necessary to format than to repair.

I agree that it would be better if the core Unraid system could distinguish the two cases better.   I was thinking that some rewording of the warning given on format was a 'quick fix' until a more fundamental change could be made that while not ideal would be better than nothing.  

 

There is also the fact that if the 'unmountable' is part of replacing a disk then the check/repair is ideally run against the emulated disk (which keeps the original physical disk intact) as that shows what will result from a rebuild.

Edited by itimpi
Link to comment
4 minutes ago, johnnie.black said:

That's good, but IMO if there's going to be a change it should also address when the user replaces a disk, which is probably when this mistake happens the most, since it's fairly common to have the disabled emulated disk go unmountable and then user formats the disk during the rebuild, and previous serial won't help with this.

When this situation happens, the user should do a disk repair, correct?

It means Unraid must keep some history and offer repair over format, when a new disk failed after a rebuild.

A truly added new disk has only the format option.

Link to comment

Seems a tough nut to crack. People don't read if they can help it. You need to make it difficult for them to do the wrong thing, and require them to read something only when they need to learn how to avoid the restrictions put in place.

 

If it could force them to repair the emulated disk before it would even begin a rebuild that might help.

Link to comment
18 minutes ago, trurl said:

You need to make it difficult for them to do the wrong thing, and require them to read something only when they need to learn how to avoid the restrictions put in place.

Tried that with the "I want to do this" checkbox and additional advisory popup message, it ain't foolproof...

Edited by bonienl
Link to comment
3 hours ago, bonienl said:

Tried that with the "I want to do this" checkbox and additional advisory popup message, it ain't fullproof...

Yes. Unfortunately there is just too much they need to understand about why they shouldn't just go ahead and check the box. Even though it tells them they are going to lose the data they think parity can get it back for them.

Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.