Link to home
Start Free TrialLog in
Avatar of Smukhtar
SmukhtarFlag for Australia

asked on

Your PC Ran Into a Problem and Needs to Restart Windows 10 error:0xc000021a

Hi there

I had a clean installation of windows 10 on a desktop pc with a bootable usb flash drive (Windows downloaded from official Microsoft Website) about 4 months before. This computer was working until yesterday when all of a sudden I got this message "Your PC Ran Into a Problem and Needs to Restart" while I was using Google Chrome and watching Youtube and it stuck on this screen forever. I had to manually restart the computer but it did not fix the problem.

I tried to roll back the computer using system restore but it can't find any restore points to go back to. I have also tried startup repair with the installation media (USB Flash Drive) but that did not help either. It says Windows can't fix the startup problem.

After that I followed the instruction on this Youtube video to the letter

https://www.youtube.com/watch?v=fhHBdBD_92A

This video has this text if you don't have the time to watch the video

"

Once you go to the "Automatic Repair" screen and Restart the system, it comes with the same error and end up there again only. So Go to the "Advanced Option".
Select the "Troubleshoot" option. Here there are multiple options "Refresh your PC", "Reset your PC", "Microsoft Diagnostics and Recovery toolset" and "Advanced Options". Click on "Advanced Options" as the other options are not going to help you.

Under the "Advanced options" there are again multiple options. "System Restore" which is help full only if you have created a Restore Point. "System Image Recovery" is help full only if the Image Recovery is created. Both these options are not going to help me here as i didnt created both. We already did "Startup Repair" and "Startup Settings" contains different options.

So click on fourth option "Command Prompt" and from here we are going to restore the registry to the previous state prior to the changes.

Go to following Location "C:\Windows\System32\Config\RegBack" and copy all the following files "Default", "SAM", "Security", "Software" and "System" to the previous directory that is "C"\Windows\System32\Config". Before copying these files to the Config folder, please take the back from Config folder.

Once you restore the registry files, restart your system. And magically your system will start again normally.


"


The files I renamed and pasted in that location are still there. I don't know how to remove them or to undo any changes I made.

I also had a chat with Microsoft representative who asked me to run the chkdsk which did not return any errors on the disk.
He also suggested I should try to download the new Windows ISO file and create the new installation media and try to fix the startup problem. I downloaded the new windows 10 and created the USB with the help of media creation tool; booted from the usb, tried to fix the startup but it did not work.

Also performed sfc /scannow

The guy at Microsoft Chat also advised to run Dism /Online /Cleanup-Image /RestoreHealth  which I did but somehow I got this message

" Error 50
 DISM does not support servicing Windows PE with the /Online option.
The DISM log file can be found at x:\windows\logs\DISM\dism.log "

At the end Microsoft Chat Representative said that I need to clean install the windows as it can not be fixed.

Now I am stuck with a PC that won't let me go back to previous build or let me restore it to a previous position or won't fix the startup.
I want to get it back to the condition before this problem started. I don't want to clean install as there is too much data and programs that I don't have the backup of and moreover installation process is too much time cosuming also downloading/uploading the data to all the cloud services is expensive and tedious.

The ideal solution will be just fix the startup problem without any clean installation and I'd appreciate if you could also mention the steps to undo the steps that I followed in the above-mentioned youtube video. thanks

There is no problem with the hardware that I am aware of
Avatar of nobus
nobus
Flag of Belgium image

>>  Your PC Ran Into a Problem and Needs to Restart  <<  probably malware
connect the disk to a working pc as 2nd drive, and scan it with the AV
run also these on it :
http://www.malwarebytes.org/mbam.php                         MBAM
http://majorgeeks.com/RogueKiller_d6983.html                  Roguekiller

after that also run a diskcheck for errors - to be sure the drive is ok
Does your PC have an inbuilt videocontroller? Try to remove your videocard and let system start with onboard video.
If you were watching video at the moment when the problem occured then it could be that a vid driver crashed.
Once you've checked it for viruses check the HDD with its vendor made tools as suggested by nobus. Failing HDD behaves very similar to your problem.
Avatar of Smukhtar

ASKER

I don't have additional/dedicated video card installed. All I got the onboard video card. Secondly I run the Chkdsk for 1 hour and it did not return any problems with the hdd. Also ran the sfc/scannow that did not report anything missing/corrupt. I am just thinking how can I connect the SDD from the desktop to my laptop to check for the viruses as suggested in the earlier comment. I have to buy something from the computer shop in the morning to connect it to my laptop for that purpose.

In the mean time could you please provide the step by step instructions to reverse the steps mentioned in the youtube video. I believe if I could reverse what I did in following that video that might give me a chance with the startup recovery with the installation media. Thanks
you never need to run chkdsk on an SSD - they use other tools -but you never told us it was an SSD..

could be your ssd is failing
test it with the manufacturer's tool - or post the model
Your stop 0xc000021a error indicates a corruption of Windows core security services or of the BCD store which will result in the PC thinking there are no valid Windows installations.  You can check by booting to the Windows 10 USB drive, choosing the command prompt and checking with BCDEDIT: https://technet.microsoft.com/en-us/library/cc709667(v=ws.10).aspx

If it is what I think it is, this guy can fix it (not free) https://neosmart.net/wiki/0xc000021a/ or we can go into a painful process of creating a new BCD store.

BTW, putting back those registry files probably won't help.
User generated image
@nobus

Followed all the directions, scanned the SSD Hdd with Malwarebytes and Rogukiller by attaching to the same system as a secondry driver. Malwarebytes did not find anything major, just 3 'potentially unwanted programs' removed them and checked if it did fix the problem but no luck.
Also checked the disk with chkdsk; didn't return any errors or bad sectors, also checked with Samsung SSD Hdd utility, which says drive health is good. waiting for other ideas

@noxcho

I have checked the video card (its an on-board built-in video card) by removing the hdd that is giving that error and plugging a new SSD and installing the operating system on that SSD. Everything is working fine. Also checked the SSD that has issues with Samsung Hdd utility, says drive health is good. SSD model is Samsung SSD 850 EVO 1TB.

@Davis McCarn

Could not understand a single thing in the link what it means or how can it help, rather I bought that software from the 2nd link neosmart and built a USB disk with that Windows 10 Recovery Iso. Applied the automatic repairs without any luck. Then tried the System restore option and it did find a system restore point and I restored the system to that point and it asked me to restart the system and I still have the same error but the description is a little changed it says something like Bad System Configuration.

All that excercise has given me hope that it is just a software issue as drive health is good (According to the Samsung utility) and I could see all the files when I connected this SSD to the same system as a secondary Hdd. With the right strategy I hope this can be resolved. Waiting for further instructions, fingers crossed
The NEOSmart utility made a huge difference in that the PC then actually thought there was a Windows installation and that the restore point matched it.
Try the system restore again; but, choose the link which says "Show more restore points" and choose one labeled Windows update or critical update.
@ Davis McCarn

I can't choose the system restore, the system comes to this message straight away

"Your PC ran into......... 0xc000021a"

and If I chose the system restore with the help of NEOSmart utility it just gives me the restore point that it created itself 5 minutes before. Kinda stuck, any thoughts. thanks
Check and see if you have hibernate feature enabled by looking for hiberfil.sys in c:\.  If it is present then ensure to copy the original files back to c:\windows\system32\config location and then try rebooting again.
@Mohammed Khawaja

Could you please provide the complete steps/commands how to do that. I am at the command prompt and I can see C:\>. What I have to do next. Thx
@ Mohammed Khawaja

I typed  at the c:\windows\system32>powercfg -h off and got this message

Hibernation failed with the following error: The request is not supported.

The following items are preventing hibernation on this system.
              Windows does not support Hibernate during the upgrade process.
              Windows preinstallation Environment does not support Hibernate.

Does this message ring any bells?
You need to use the NEOSmart utility again, then run system restore and choose a different restore point.  Choose the link which says "Show more restore points" and choose one labeled Windows update or critical update.
@ Davis McCarn

Thats what I did. I run the NEOSmart utility multiple times and selected System Restore but NEOSmart utility shows only 2 restore points that it created itself before applying automatic repairs. There are no further options to choose for a system restore.
That's why one should use backup tool to avoid such problems in future.
How many partitions do you have on this drive?
@noxcho

Run the diskpart.exe and LIST DISK and it came up with Disk 0 and Disk 1. Disk 0 is the one that has the actual windows installation and it has 2 partitions but it is listing the whole drive with its size but not listing the partition (there are 2 partitions on Disk 0). Disk 1 is the USB flash drive that I am using as an installation media to repair the startup problem. Please have a look on this photo. thx

User generated image
You misread me. I said use the NEOSmart utility to "fix" the problem, THEN reboot and use Windows system restore ;but, choose a different restore point.
@ Davis McCarn

I have tried all the combinations.

1)NEOSmart utility,  Auto repair, restart, no difference
2)NEOSmart utility , System restore, restart, no good
3)after fixing with NEOSmart utility  tried the installation media to repair the startup, still the same error
4) If I don't use either of NEOSmart utility or the installation media it just comes to the screen with that error message where the problem started.
Then; unfortunately, you had better take that drive out, connect it to another PC that works, and back up anything you want to keep.  All of your software will have to be reinstalled; all you can save is your documents, pictures, emails, etcetera.
In diskpart type select disk 0 then list partition.

Then get out from diskpart and run in cmd bootrec /rebuildbcd

Does it finish successfully?
@noxcho

followed the steps recommended in the last comment.
in the diskpart selected disk 0 and then list partition that came up with 2 partitions.
Exited from the diskpart and ran the bootrec /rebuildbcd and it said that you want to do that for 1 or for all or no. I opted for yes(for 1). it did something and then I restarted the computer. It made a little bit of difference saying that it is trying to fix errors on the disk and then came up with the original error message.

Repeated the same step but this time, opted for A(All). It fixed something, restarted the computer and it came up with the message it is going to fix the errors on the disk and then after it returned the original error.

I must say it was a step in the right direction. Further comments appreciated. Thx
Can you slave this drive to another PC and see if you are able to access its partitions?
Or just take a picture of your Windows Disk Management once the drive is slaved to another machine?
ASKER CERTIFIED SOLUTION
Avatar of Davis McCarn
Davis McCarn
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
The only sure course was to do another format and reload.  I disabled write caching, made her a shutdown icon, and tried to impress on her that she must shut it down before hitting the power strip.

Davis, I hope you've installed for her a backup tool and made a backup to some protected area. Because next time it would help you to deal with her problem faster :)
I have a backup of all of her files which I will keep for at least three months and is what I used to restore her files when it got clobbered again.  I'll be contacting her in about a week to see how things are going and will suggest we address a regular backup.
@noxcho

Here it looks like in Disk Management. I have followed the instruction and take a screenshot of the drives showing in the system. Disk 0 (Partition E) has the corrupt startup for Windows 10.

User generated image
Sorry for the late response. Waiting for further instructions. Thanks
This partition does not look like a system partition. Did you pre-format the drive before you installed the system?
Can you show me the root directory of E: drive? Please uncheck in Folder Options the Hide Protected files and Hide Extensions. So that we see which system files are on the C:
@Davis McCarn

I believe what you said in that particular case happened exactly the way you described. But I love my computer; its my work horse and entertainment tool and I take good care of that and never treat it a bad way by pulling the plug or switching the power off rather than shutting it down.

I believe Windows 10 recent Updates are to be blamed. All of my family computers including 2 laptops are showing a weird behavior and all this happened in last 15 days. But I could see the little problems right after installing the Windows 10 on all 3 machines. Slow shutdowns, stuck at restart screen for hours, unresponsive mouse, unresponsive keyboards to name a few for the other laptops not this machine in question. Also this desktop having the startup problem was not good with external devices, hard drives were slow to respond or just plain stuck while moving data back and forth right before it died. I must say Windows 10 updates distribution/update mechanism is to blame.

 But this particular machine we are talking about is most dear to me and its the one worst affected.

I had customize everything over the period of 6 months and I want it to get back in the state before I had this problem. I can smell it is just a software issue and can be fixed.

When it is fixed I'll bother you, The Experts at experts-exchange , to get an advice to make it bullet proof in terms of fool proof backup etc


"We may never know why Chrome and Youtube decided to eat your lunch.  We may even be able to fix the boot issue; but, I'm virtually sure that Windows won't be right in the head if we do.  The smartest course, IMHO, is to backup your files and start from scratch.
BTW, if you use the media creation tool again, you'll get a newer version of 10 which includes the October update which is huge."

I created this media a week before by downloading ISO from the official Microsoft website and I think it has all the updates, should I need to reinstall.


I forgot to mention one thing, though, I do not Power Off the PC or pull the plug but I do make it sleep after a certain time using the Windows built-in Power Options and/or I force it sleep by selecting Power->Sleep. Can this cause a problem or is it a bad habit. My current knowledge says that it should not be a problem else why they will give you this option

Appreciate your time and effort for a detailed comment

Waiting for further comments/instructions
@noxcho

"This partition does not look like a system partition. Did you pre-format the drive before you installed the system? "

The answer is no. I did not pre-format the driver before installing the Windows 10. Rather I created the partition during the installation process


root directory of E: drive after following the instructions

User generated image
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
@Davis McCarn

Here is the sizes of registry files. I don't know what size they should be for any particular file

User generated image
Could you please let me know where this regbak folder located? I can't find it anywhere even with the file explorer search. Thx
@noxcho

"Is your BIOS on the machine where this drive belongs to, set as UEFI or Legacy?"

I have to check on this one. But I don't know which BIOS Settings look into. Thx
then post your motherboard model, so we ca,n look it up
or a picture or 2 of the bios
@nobus

Please have a look on the bios photos
User generated image
User generated image
User generated image
User generated image
It was right there,: but, its RegBack
As to the BIOS stuff, you would probably need to switch to Advanced to see the secure boot options or it may be under Boot; but, for heck's sake, do not change anything in it or it may never boot again!
The model number for motherboard is B85M-G and bios is version 0703.
It is in boot\Secure boot menu

Where it says secure boot state platform key state enabled  Loaded and it further says os type windows UEFI Mode
@Davis McCarn

"Have you gone back to the Windows\system32\config folder to see if any of the registry files are unusually small.  Compare them to the ones in the regbak folder and it certainly won't get worse if you copy the ones in RegBack back to the config folder.  Heck it might just make it boot!
"

Followed the instructions and copied the files from RegBack folder and all it did change the error message a little bit and asked to search for bad_System_config_info online. Furthermore it has another change it made is the continuous boot loop after copying those files, before it just stuck at that message "Your System Run into.........." and it just stayed there forever.

Could you please go through the comment ID: 41502816 and ID: 41502879

I believe noxcho made a strong point there in the Disk managment when I used the corrupt drive as a slave(Disk 0) it should have shown a little extra system partition on the left of partition E as it is showing for Disk 1 (the master running the windows) on the left of C partition with a title System Reserved having the size of 500MB. I want your thoughts on that one.

Furthermore if noxcho's point is valid; How can I create that little missing system partition.

User generated image
Your BIOS is set to use UEFI and your system is configured to boot from MBR drive in Legacy BIOS mode. Something or someone reconfigured your partitions so that EFI partitions disappeared.
Check in BIOS if you have any option there to change from UEFI to Legacy mode. The system does not need MSR partition to boot with legacy BIOS. So if you could change it to Legacy BIOS then it would give us a chance to repair the OS boot.
If there is no way to change to legacy BIOS then you are in a dead end.
Smukhtar said earlier that he had created the partitions during Windows Setup and I'll bet he didn't realize that would put the BCD on the C drive rather than creating the System Reserved partition and we don't dare mess with that if we want to rescue the existing installation.  DO NOT alter or change the existing partition structure, OK?

Have you tried booting into Safe Mode?

And, BTW, that is a very old BIOS you have there.  ASUS' site has an update that is 2 full years newer; but, also, don't do it until we have it booting again! https://www.asus.com/us/Motherboards/B85MG/HelpDesk_Download/
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
nochco,
We can't possibly know that yet as we do not have the contents of the BCD.

Smukhtar,
Wit the drive back in the original PC, you need to boot to your Win10 USB, get to a command prompt, and post the EXACT results from BCDEDIT<enter>
No need to know it. It is a rule of Windows that it needs efi loader plus the drive shout be GPT.
https://msdn.microsoft.com/en-us/library/windows/hardware/dn898510(v=vs.85).aspx
I am not sure if he used some advanced method of installing Windows but by default it should look as follows.
@ noxcho, Davis McCarn, nobus, Mohammed Khawaja

Thanks everybody for your time, effort and help. We did our best, but could not get it going. I think this computer is deceased.

I like Davis McCarn's comment

We may even be able to fix the boot issue; but, I'm virtually sure that Windows won't be right in the head if we do.  The smartest course, IMHO, is to backup your files and start from scratch.

as I will always be scared it can go wrong anytime. So I have decided to build from scratch. As a precaution and meaningful closure of this question, I'd like to ask the experts; What should one do to avoid this happening in future or minimize the impact.

A supplementary question is what tools/strategies are the best for automated backups (full,incremental,differential)  and restores
( preferably free or least expensive ).  Backup and restore should not be much time consuming
Thanks all, once again for your input
Just wanted to let you all know, what I tried before quitting. I installed the windows from the same installation media on a separate hard drive. Made an image backup for the system that was unable to boot. Copied the System Reserved Partition from the newly installed hard drive to the one not booting. Restored the C partition to the one not booting from the backup image. But when I finished doing all this, the same error message was there again. So I decided to build afresh.
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Thanks everybody for their input. I could not get the problem fixed but I learnt a lot. Maybe people coming in future with this question  benefit from these experts' comments.