Boot USB marked as write protected after power loss


Recommended Posts

So I have my server on a UPS that can sustain a solid 35 minute outage before initiating a shutdown.  That said, I did not anticipate the following scenario...

 

I had my 2 year old daughter in the basement with me long enough to get one thing from my workshop (like I've done tons of times) and I turned around to pick her back up and in the 4 seconds it took me to set her down and grab what I came there for, she opened a worm hole and exited it on the other side of the basement.  My eyes locked onto her and time slowed down for me as I watched her press the power button on the UPS and the server go silent.  I'm pretty sure I had a mild stroke preventing me from reacting and then just as fast she pressed the button again and the server came to life.  I watched in horror until I heard the POST beep and saw the boot screen.  Shortly after that I was gifted for her efforts with a kernel panic for failure to load root fs on unknown device.  I have seen this before and it's usually a corrupt image, so I downloaded the unRAID zip file and restored everything but the config folder.  It finished with no errors and I put the drive back in the server.   Same deal.  2 hours later I finally discover that the USB stick is write protected.  It's a Kingston drive, but it's one of the metal ones that does not have a hardware switch on it to write protect the drive.  Some how that momentary power loss marked the whole drive as write protected and after another hour or two I have tried with Linux, Windows, and macOS and every procedure Google can find to remove the write protect and format the drive.  Alas I am still at square one.  Has this happened to anyone before and were you able to recover the USB drive or am I really just stuck buying a new one?

 

Second, is there any setting in unRAID that I can disable to prevent this from happening again?  I can understand a partition being marked as read only with a dirty shutdown, but the whole drive is excessive and very frustrating.

 

Thanks and surround your servers with some anti-matter to keep the kids away ;-)

Link to comment
10 hours ago, cbf305 said:

I can understand a partition being marked as read only with a dirty shutdown, but the whole drive is excessive and very frustrating.

I do not think this is an Unraid feature. I guess that the USB drive did not appreciate the unclean shutdown.

 

Do you have a recent backup of your drive ?

Link to comment
15 hours ago, cbf305 said:

Second, is there any setting in unRAID that I can disable to prevent this from happening again?

Flash device always like that, when EOL or exceeds writing then you can't write to it anymore.

 

So you need minize the writing and perform backup.

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.