Windows 10 Windows Update Fails with various errors, but root cause is faulty upgrade of operating system hard disk to SSD or M2 drive

  • Thread starter Thread starter VinceS2
  • Start date Start date
V

VinceS2

So I am trying to update Windows 10 Pro 64 from 1809 to 2004 (ie Sept 2018 version to April 2020 version). The same problem stopped it updating to 1904, 1909 or doing an in place upgrade to same version. Somewhere along the line, I unwittingly stuffed up transferring Windows from one drive to another, and I deduce many have done the same. None of the advice out there to do the many things to fix Windows update were any help, including cleaning out old updates, catroot2 folder, chkdsk, media creation tool, disconnecting www, clean boot start, no firewall or Defender on, and whatever. Seemingly a fresh install of windows was the only option, and many have gone that way in their frustration. But this method will solve the problem for any 2004 or prior version of Windows 10, and likely many that are to come until Microsoft bakes in some basic error trapping to pick it up during the upgrade process of versions yet to come. It may be applicable to any system with a UEFI based Windows version, but I've not tested that theory.



As it turned out, the answer is simple, gotta love that! It is about a 2 out of 10 for degree-of-difficulty, and anyone that can confidently edit the registry can do this. I now have a current 2004 Windows version without having to reinstall anything, just the usual basic housekeeping items (Restore back on, menu fixes, check winaero tweaker and the like). My own basic mistake had caused an entirely predictable problem, and Microsoft have nothing in the arsenal to pick up klutzy real-world user’s mistakes like mine, duplicated several million times over I suspect. Hence this post, to hopefully let your pathway from reading it to having a fully updated windows of your very own be less than two hours, from this moment on, cool eh. All you need to do is properly put the EFI partition back on the disk and the waters will part. But there are a few twists to doing that, and I am yet to read a single guide that explains the whole thing, with every step working / relevant.



First, some history, then my Google searches, all for the purpose of helping good folk like yourself Google your way to this post. Now that you did that, you can scroll down to the Actions heading, unless the minutia I lived through is fascinating for you too!



The CORE problem was that I had not properly upgraded my op system disk, happened at least two years ago and probably a lot earlier. Most likely, this was going from a Samsung 0.5Gb 850 Evo on SATA to a 1TB 960 Pro on M.2. This on an ASUS Maximus VIII Assembly mobo i7 6700K but carried over to an ASUS Formula IX, i7 7700K. Right now, I have no idea exactly how I did this, but never been able to get Windows to update since. I expect I used Samsung’s data migration tool, but there are a few others in the arsenal and maybe I didn’t notice the Samsung one. Soon (2 weeks or so) I had a problem with the 960 regularly freezing, and Samsung replaced it with a 970Pro. When that started having freezing problems, I copied the drive back to the Evo and used it with zero issues hanging out the back on an eSATA port ever since. It worked great, and the freezing on the 970 was just filed under a job to do ‘one day’ to figure out if it was faulty or the mobo, driver or other software or what.



Obviously you need to understand a fair bit about partitions to do the above manipulations. So 2 years passed and I now upgraded the mobo to an MSI MEG Z490 Godlike with an i9 10900K. I thought I had it beat when I used a Media creation tool to make the M.2 970 into a bog standard version of 1809 (ie the current version on the 850) and then copy the drive C partition off the 850 across to the 970 in an M2 slot and used LAZESOFT’s (free) one button solution to get it working, which I found on Hiren's Boot Disc (free). That seemed to work fine for a month or so, no freezing but this non-shutdown issue due to some added service arose, so I decided to give updating one last red-hot go before going the clean install way. I put a couple of 2Tb 970 Evo's on the expansion card, as well as another SSD and a 4Tb mech drive. Which will explain some of the Actions items below...



In a bit of Googling I found the system partition needed to be at least 100MB to allow updates to happen and mine was 40MB. So I used MiniTools partition wizard (free) to pinch a bit of the over provisioning area to push C: along a bit and made the system partition 500MB, better safe than sorry eh. But it didn’t work. Note this was not a carry-over op system from Win 7 as I had done a clean install when my original upgraded system went flaky, details long gone...



The PC always passed DISM /online /cleanup-image /restorehealth and sfc /scannow in elevated prompts, with typically no errors, or rarely with errors it fixed and came up clean on rerun. Update troubleshooter always said there was nothing wrong. Nothing in Safe mode will improve the situation. Nor will Windows Automatic repair help anything via the RE (Recovery Environment). So Microsoft has got nuffin for us here. Which is truly amazing for such a basic error as it turned out to be. Two other PC’s I built and a laptop upgraded just fine, one being the Formula IX I swapped out for an original Maximus Extreme mobo PC I hadn’t turned on since 2016, which then upgraded with no issues off my 2004 DVD to an old Mushkin 120Gb SSD in the box! Even activated with no hassle with a local account, which was a bit of a surprise but nice to see Microsoft get one right without a hassle. This is not to say I was unlucky with the now-fixed i9 build; I stuffed it, in an important way, and remain unaware exactly how that happened.



Things I Googled as part of looking for an answer here, may not be the complete list:

windows update failure 0x80240034

how extend size of system reserved partition windows 10

SP Operation failed: Update Boot Code. Error: 0x80004005[gle=0x000000b7]

How create new efi boot entry for destination drive paragon

How to Fix When Windows 10 Won’t Shut Down

windows 10 installation failed 0X80004005 0X1000A

windows 10 update error 0x80004005

windows 10 installation failed in the downlevel phase with an error during prepare_first_boot operation

windows 10 installation failed 0X80004005 0X1000A prepare first boot

win 10 continuous circling dots on "shutdown"

how find error for windows install failure

0xc1900130

0x800705B4 update troubleshooter

system configuration cannot save the original boot configuration for later restoration. The system cannot find the file specified

bcdboot C:\windows /s N: /f UEFI failure when attempting to copy boot files

bootrec /fixboot access is denied in windows 10 ⇐ leads to the answer!!!



In the above, I got rid of the “won’t shutdown or restart” problem by doing a selective start-up where I selected all services to start, hid the Microsoft ones, then unselected all remaining. I still have some diagnostic work to figure out which one was the culprit, if the problem has survived to the new Windows version. But first, here, I am doing a dump of the knowledge while it is fresh, and while the drive C: is being imaged via Windows Backup imaging, in 2020 version still called Win 7 backup, unbelievable! But something you should do too when you get this problem sorted.



I have been a Windows insider for many years, but all that gives me is stubbornness, and a level of capacity to run down some really opaque convoluted rabbit holes looking for answers, before finding the blindingly simple solution! As follows…



Actions

Here I am going to plagiarise other posts that worked, but add my own bits where I nearly gave up for want of deducing what was really going on / needed. Obviously you need this guide open on a phone / other PC while working with the problem child. Capitalisation is for effect; all can be lower case letters.



You need to get to RE (Recovery Environment) command prompt. You can turn your PC off three times in a row while you see the circling dots to get to that one if you have to crash through. But I used my 2004 Windows Media Creation DVD, booted from it, selected Repair Your Computer, Troubleshoot, Command prompt. Neat and easy.



The prompt will be in X:\Windows\… I forget exactly, but it doesn’t matter. However, I do need to state EXACTLY what I did, because it worked.



Type in the command:

Bootrec /FixMbr



Type in the command:

Bootrec /FixBoot



(the above command failed for me. If by chance it works for you, maybe just do the next two steps and you are good)



Type in the command:

Bootrec /ScanOS



Type in the command:

Bootrec /RebuildBcd



Because the FixBoot option failed (rest worked), I found my way to this solution:



Type in the command:

Diskpart



Type in the command:

List disk



Note which disk is your boot drive number; mine is 3



Type in the command:

Sel disk 3 (or whatever is your boot drive number)



Type in the command:

List vol



Note which volume is the EFI partition; mine is 6. The EFI partition will be the only one that is FAT32, the rest should be NTFS. If you see something else, please figure it out and add a comment; if I can edit this post I will. You are going to format the volume so maybe it is only important that there is an unnamed partition there; I didn't need to experiment with this as I had an unnamed FAT32 partition to go with, however exactly that happened!



Type in the command:

Sel vol 6 (or whatever is your EFI partition number)



You can see most volumes have a drive letter assigned to them; pick a letter that is not used already and use it in the following, eg let's pick V:



Type in the command:

assign letter=V:



Type in the command:

Exit



Type in the command:

V:



Type in the command:

format V: /FS:FAT32



Now it gets tricky. You need to figure out which of the volumes is your actual windows drive, because otherwise the following command will give you a failure error. In my case, I could tell from the size of the partition / volume I saw when running the diskpart commands that it was drive G: that was the 970 Pro with the 'real' Drive C:, so this is what worked for me:



Type in the command:

bcdboot G:\windows /s V: /f UEFI



Presuming no error, Type in the command:

Dir V:\EFI\Microsoft\Boot\*.*



You should see a bunch of files listed and that is success, right there. This one was from memory, but you will figure it out if I made a typo...



I am pretty sure I ran the problematic command again, and I can see guides saying it is not necessary but should run fine after you have success with the previous step, so it should be OK to do it, but honestly I don't now remember if I did or not:



Type in the command:

Bootrec /FixBoot



Type in the command:

Exit



Then reboot Windows, which happened noticeably faster for me. Now you can put the 2004 Media Creation DVD in (or USB if you did that) and run Setup. I clicked on Download and said Not Now, also unticked the box to send feedback, which I normally let that be sent and now see it would have been fine. I stayed www connected, accepted the agreement and Clicked Install on that wonderful screen that says you can keep your files AND your apps, and off we went. About 3/4 hour and a couple of restarts and here we are. Click on Settings, Update then OS build info, scroll down and there it is ... 2004, yay!!! So now to run Update a couple of times, re-set up Insiders etc and get into the hum-drum of regular Windows - and it never felt so good!



The PC is still booting faster than it did before, something like 20 secs down to around 12. So I am guessing the lack of a proper EFI partition was able to be got around by the UEFI 'finding and checking' it, as opposed to just running it from where it was supposed to be. But that all came crashing down when Windows Update went looking for it. Why we couldn't just be told this really basic thing isn't there / configured properly Is anyone's guess. I am just enjoying the relief of fixing it, and I trust you soon will be too. I am happy if I can help make your journey easier :).

Continue reading...
 

Similar threads

N
Replies
0
Views
7
Nick Ramirez1
N
L
Replies
0
Views
8
Lorenzo Spadoni
L
Y
Replies
0
Views
4
Yahya Alkautsar
Y
F
Replies
0
Views
19
Fiona_269
F
Back
Top