Restoring MBR on a corrupted SSD

dust

Ars Legatus Legionis
19,135
Subscriptor
I suffered a power outage the other day and when I attempted to boot my main computer it would not go into Windows, only the BIOS. Further investigation revealed the Samsung Evo Pro 990 1TB M.2 SSD had a corrupted MBR and was not being seen by the BIOS.

Using Hiren BootCD and Crystal Disk Info I discovered that the SSD had been written to too many times and went into read-only mode. It also returned corrupted blocks when checked with scandisk. The main partition shows up as RAW in Disk Management.

I have imaged the drive using a sector-by-sector copy with Lazesoft Disc Recovery, both to a image file and a direct copy to an external 1TB SSD. The original drive did show the file structure when accessed with the command line in both Windows Recovery and Hiren BootCD. I believe I can retrieve most of my data using a data recovery program if necessary.

I was able to clone the disk to the replacement M.2 disk and attempt to fix the MBR so it attempts to boot into Windows 10, but it returns a stop error with REGISTRY_ERROR on every boot. When checking Windows\System32\Config\ for a registry backup I find none. I attempted to copy the registry files from the old drive because they had Last Modified dates before the outage, but it still returns a stop error upon boot.

Is it possible to uncorrupt the data/copy disk as much as possible and restore the MBR and registry to the copy? I'd love to be able to do an in-situ clone to the new M.2 drive I purchased as a replacement and be back up and running with as little hiccup as possible. In the mean time I have done a fresh Windows 10 Pro install and have been steeling myself for installing everything from scratch.

Most of my data is on other hard drives so I'm not too worried, but my main Outlook PSTs are on the main drive.
 

dust

Ars Legatus Legionis
19,135
Subscriptor
Okay I've verified that I can see the drive in Explorer in my fresh install. It pops up with a drive letter and I can browse files. I ran chkdsk /f on it and it repaired the corrupted blocks/files.

When I imaged the drive it had four partitions, recovery, boot, main, and system. I only imaged the main partition so now I have three partitions on the new drive, unallocated, main, and unallocated. Disk Management shows that volume as GPT. It shows the new C: drive as MBR.

Is there a way to initialize the imaged drive as a boot drive? I'm not sure if it will work because I didn't copy over the other partitions.

I see "Initialize GPT Disk" in Lazesoft Recovery Suite, but I'm not sure what it does.

Edit: Or what if I booted into Hiren BootCD and copied the old disk clone back over the currently functional C: drive? Since the clone is just a data partition and not System or Reserved partitions, in theory it should restore back to my old setup prior to the power loss and disk corruption. Providing the registry is not corrupt, of course.
 
Last edited:
If the OS is Win 7, 10 or 11 I'd do a RMA on the SSD then reinstall from the image file on the new warranty SSD then do a "dirty repair install" by unzipping the original install .iso and running the .exe file in the unzipped OS folder (I do them on the desktop) while booted into Windows. This will repair/ replace any damaged or missing original files plus let you keep everything already installed. You'll have to run Windows Update again after completing the repair. Make sure NOT to let the installer download anything at the beginning of the repair process.

After the whole process has completed run sfc /scannow from PowerShell or CMD as Administrator. After that make a new backup image file and save it to an external drive.
 
  • Like
Reactions: continuum

dust

Ars Legatus Legionis
19,135
Subscriptor
If the OS is Win 7, 10 or 11 I'd do a RMA on the SSD then reinstall from the image file on the new warranty SSD then do a "dirty repair install" by unzipping the original install .iso and running the .exe file in the unzipped OS folder (I do them on the desktop) while booted into Windows. This will repair/ replace any damaged or missing original files plus let you keep everything already installed. You'll have to run Windows Update again after completing the repair. Make sure NOT to let the installer download anything at the beginning of the repair process.

After the whole process has completed run sfc /scannow from PowerShell or CMD as Administrator. After that make a new backup image file and save it to an external drive.
I have a Windows 10 Pro installation CD. How exactly would that work? I've tried doing "Repair Install" from the installer but it asks for my admin password and I have completely forgotten it. It should be the one I always use but I'm thinking Windows made me create a "more secure" one when I set the computer up in 2019.

Does the Windows 10 downloadable ISO have Pro built in? I have a legit activation code because I bought it.

I also can't warranty the drive, it's too old.

Currently on another drive cloning, I'll check back in a couple hours.
 

dust

Ars Legatus Legionis
19,135
Subscriptor
Did a full drive clone to the new SSD and rebooted fully expecting to have to do some corruption clean up and to my surprise the computer booted back into my old Windows install with everything just as I left it.

The internet is moving slow for some reason but I think that's unrelated.

We'll see what happens when I connect all my storage drives and reboot but for now it seems like disaster has been averted.
 

dust

Ars Legatus Legionis
19,135
Subscriptor
Okay, final update for now.

Booted into Hiren BootCD to do chkdsk, it did find file corruption and was able to fix it. I noticed the internet slowdown was only Firefox, Chrome worked fine. The Diagnostic Policy Service was eating up CPU and doing constant writes to system32\sru. I deleted all the logs in the sru folder and temporarily disabled the DPS and that fixed a lot of the slowdown. I have noticed an intermittent slight freeze where the computer stops responding to input for about one second every thirty seconds or so, it may just be in Firefox.

I have thirteen Firefox windows open right now, each with at least thirty tabs. I have a massive tab hoarding problem.

All storage drives came back online properly when reconnected physically, no drive letter issues.

So far as I can tell it's like the hard drive never crashed.

As far as prevention strategies I'm going to be running CrystalDiskInfo in the system tray from now on with alerts set for both temperature and write limit. I'll also set up a regular backup service to image my main system drive to my FTP server at least once a month. My roommate says he does that right before Patch Tuesday and it's saved his bacon a few times.

I also think I need to get a NAS and start replacing my storage drives, some are from my previous system that I built in 2009 and possibly even before. My documents and music drive has a Powered On Hours of over thirteen years.
 
  • Wow
Reactions: continuum

continuum

Ars Legatus Legionis
97,774
Moderator
Okay one thing I've noticed is it loses audio input and output to my Blue Yeti microphone for about three seconds every so often then switches back.
Can't speak for you but I occasionally get USB resets due to the TPM bug in earlier AMD AGESA's, I have a hardware TPM module and supposedly the bug is only if you use the fTPM, but 🤷🏻‍♂️.

Not sure if thats related for you...
 

dust

Ars Legatus Legionis
19,135
Subscriptor
Can't speak for you but I occasionally get USB resets due to the TPM bug in earlier AMD AGESA's, I have a hardware TPM module and supposedly the bug is only if you use the fTPM, but 🤷🏻‍♂️.

Not sure if thats related for you...
I unplugged everything but mouse and keyboard, shut down and rebooted, and plugged everything else back in one-by-one.

No USB issues at all.
 
  • Like
Reactions: continuum