Weird boot problem in Windows 7

RhapsodyOfFire

New member
Power User
Local time
8:55 PM
Messages
86
Hello.
I have a Windows 7 32 bits ultimate version which doesn't boot like it should. It gives the error of not shutting down normally. If I click it to Start windows normally it shows Starting Windows and after 2-3 seconds it says "Windows is loading files" just like it starts windows repair or install. The problem is it shouldn't because it was a working OS. If I choose "Launch startup repair" it shows the same screen but restarts the computer after 2-3 seconds. Disable AROSF doesn't help because there is no BSOD - just a restart always. Safe mode also says "Windows is loading files" and restarts without BSOD.
Windows was working normally so it must be an updating issue. I tried all the common possible commands (chkdsk /r didn't report problems) and especially bootrec.exe (/fixmbr /fixboot /rebuildbcd says 0 found windows installations) and it didn't helped. I tried sfc /scannow but of course it doesn't allow me because it thinks there is a repair pending. I even tried ERD commander for Windows 7 but it didn't allow me to uninstall hotfixes (cannot find any) and couldn't start the recovery environment for some reason. The automatic repair in Windows 7 recovery console (from the dvd) gives those two errors:
"Root cause found:
Boot manager failed to find OS loader."
and
"Repair action: File Repair
Result: Failed. Error code = 0x490
Time Taken = 4767 ms"

Memory and HDD are tested and okay!!!
 

My Computer

OS
32 bit Windows 7
I think it is BSODing, but because of a failure to dump the memory to a file (or it happens so fast) that the system is automatically restarting from the BSOD faster than you can see the blue screen.

Try this: tap F8 prior to Windows logo to get the boot menu like you would when going to Safe Mode, but select "Disable automatic restart", then attempt to load Windows normally. It should have the same issue except this time show a blue screen. If it does, record the details on it such as name of driver/module (if present) and the bugcheck code, followed by the 4 hex parameters in parentheses.
 

My Computer

OS
Windows 7 64-bit
It doesn't give BSOD this way. I just wrote it shortly "Disable AROSF" Also now I cannot run SFC /SCANNOW no matter what I do!
Here is the second error I received (the first was with the pending repair which I fixed with the offline sfc commands) :
"Windows Resource Protection Could Not Start the Repair Service"
And after I fixed it starting the windowsinstaller service or something I get the third error IN A ROW:
"Windows Resource Protection Could Not perform the requested operation"
I guess sfc could fix my problem but the problem is even starting it! Here is an interesting thread:
SFC Windows Resource Protection could not perform the requested operation FIX!
Problem is I cannot edit the registry from the DVD and I cannot enter the Windows in any way.
 

My Computer

OS
32 bit Windows 7
oh ok, I didn't know what AROSF meant so I disregarded it, lol.

It's evident your MBR got totaled as any attempt to recover it or restore any existing partition on the drive is failing. I'm not sure how the MBR got messed up or deleted as only means I could see that could cause it to be tampered with would be through a rootkit MBR infection or a failing hard drive.

If you want to try to resuscitate the MBR and any existing partition it looks like you're going to need to use something like TestDisk to find any existing MBR and partitions and recover them that way. If it proves unsuccessful at finding or recovering any, I have a feeling your hard drive is dying and is in a degraded state. You should use a bootup version of Seatools to test your system drive for any potential failures. Run all basic tests on it. Note that Seatools is not guaranteed to find that the drive is bad, but it helps. If any test failure occurs, the drive is most likely bad and must be replaced.

Both Seatools and TestDisk, amongst a myriad of other items of value, are on the UBCD, which I recommend you burn onto a cd using another available PC. It also has PartedMagic, a liveCD environment that you can use to access contents on your drive, perform a myriad of disk-related tools and data recovery stuff, and a whole bunch of other goodies. If the stuff on PartedMagic and TestDisk can't find your partitions, then they're gone for good.
 

My Computer

OS
Windows 7 64-bit
Problem is I cannot edit the registry from the DVD
at cmd prompt, type regedit, click File >Load hive and browse.
What are you planning to do in the registry?


You could try a shotgun approach:
if your windows installation is on D ( as seen from booted dvd )

At dvd cmd prompt:

bcdboot d:\windows /s c:

bcdboot d:\windows /s d:

bootsect /nt60 /mbr all

DISM /image:D:\ /cleanup-image /revertpendingactions
 

My Computers

System One System Two

  • Computer type
    PC/Desktop
    OS
    7 X64
    CPU
    i5 8400
    Motherboard
    gigabyte b365m ds3h
    Memory
    2x8gb 3200mhz
    Hard Drives
    various
    PSU
    pure power 11 400w cm
    Case
    Coolermaster
    Cooling
    cryorig m9i
  • Computer type
    PC/Desktop
    OS
    7x64
    CPU
    g5400
    Motherboard
    ga b365m ds3h
    Memory
    8gb ddr4 2400
    PSU
    xfx pro 450w
It seems some important drivers got damaged/removed from the system - I stopped the annoying automatic system recovery because it didn't even start normally with this guide:
At the Command prompt enter the following:
bcdedit /set {default} recoveryenabled No
After that I saw a more appropriate error saying :
File:\Windows\system32\DRIVERS\compbatt.sys
Status: 0xc000000f
Info: Windows failed to load because a critical system driver is missing, or corrupt.
The driver is a BATTERY driver which was actually missing from the system32\drivers folder but removing the battery didn't helped so I used a copy of the file from NOT THE USUAL FOLDER mentioned here:
It crashed and I lost all my files windows 7 0xc000000f Can't startup
which is %WinDir%\System32\DriverStore\FileRepository\acpi. inf_97916753
but in a folder starting with "battery" in it's name (the name of the folder was long and seemed randomized)
%WinDir%\System32\DriverStore\FileRepository\battery...
inside was the file compbatt.sys and I copied it to \system32\drivers and now I have a new error saying msahci.sys is missing...

Edit:
The automatic recovery from my DVD detected the files as important boot file and repaired it successfully :)! Now I get the beautiful 07b bsod which is easy to fix :).
I still cannot get sfc to run.
It says Windows resource protection could not start the repair service.
I started the windows modules installer service (trustedinstaller) but it doesn't help and there is no such file as C:\WINDOWS\WINSXS\PENDING.XML
My boot partition in C: and my Windows partition is D: so I am not making some amateur mistakes here. The bios hdd configuration was originally in AHCI mode and it still is so it is not such issue. Chkdsk doesn't detect any problems and there are no bad sectors with HDD Regenerator so it must be missing/damaged system files. Typing again the bootrec.exe commands didn't helped.
SIW2 is there any chance I could delete my partition/files using those commands you told me to use like this one:
DISM /image:D:\ /cleanup-image /revertpendingactions

Second edit:
It turns out SFC doesn't start because I have to remove the pending.xml file on the recovery partition which is temporarily loaded into the memory from the dvd itself with a letter "x"! I am not even joking and this is some big bullsh*t.
I even made a picture to prove it to you. SFC runs but it didn't find problems and it runs very fast - for like 2-3 minutes yet the system partition is like 70 GB...
 
Last edited:

My Computer

OS
32 bit Windows 7
You made the attempt to remove the pending.xml file, but did you also make sure that you were running SFC on the recovery environment on the Windows disc and not the drive? You will also want to use the OFFBOOTDIR and OFFWINDIR args for SFC to specify boot and windows directory paths, as instructed here. If that doesn't work, there's a good possibility it cannot find any partition tables or MBR, hence the 0x7B bugcheck. Again, this can easily be caused by corrupted partition table/MBR and/or a bad drive.
 

My Computer

OS
Windows 7 64-bit
You made the attempt to remove the pending.xml file, but did you also make sure that you were running SFC on the recovery environment on the Windows disc and not the drive? You will also want to use the OFFBOOTDIR and OFFWINDIR args for SFC to specify boot and windows directory paths, as instructed here. If that doesn't work, there's a good possibility it cannot find any partition tables or MBR, hence the 0x7B bugcheck. Again, this can easily be caused by corrupted partition table/MBR and/or a bad drive.
sfc /scannow /offbootdir=C:\ /offwindir=D:\windows
I typed exactly this and it doesn't help - it actually shows again "windows resource protection could not perform the requested operation". I can access all the partitions from other computer.
But it really must take like 30-60 minutes for a real system file check even on fast computers so there is something fishy here. Why it doesn't scan the system drive???
The mbr should be fixed with bootrec commands as I've done it before dozens of times.
I scanned with latest definitions of AVG and it didn't found anything suspicious. For some reason my OS is called "Windows 7 Ultimate (recovered)"
I've runner HDD Regenerator again in the first 70 gb and it didn't find anything and the speed of the test was very good 60+ mb/s.
 
Last edited:

My Computer

OS
32 bit Windows 7
SIW2 is there any chance I could delete my partition/files using those commands

No.
 

My Computers

System One System Two

  • Computer type
    PC/Desktop
    OS
    7 X64
    CPU
    i5 8400
    Motherboard
    gigabyte b365m ds3h
    Memory
    2x8gb 3200mhz
    Hard Drives
    various
    PSU
    pure power 11 400w cm
    Case
    Coolermaster
    Cooling
    cryorig m9i
  • Computer type
    PC/Desktop
    OS
    7x64
    CPU
    g5400
    Motherboard
    ga b365m ds3h
    Memory
    8gb ddr4 2400
    PSU
    xfx pro 450w
"I typed exactly this and it doesn't help. I can access all the partitions from other computer."
So you've put the drive in another system and yet somehow that system can see all the partitions, but when you put it in the PC that is suffering, applications like PartedMagic cannot discover any of them? If that's the case, it sounds less like a drive issue and more of a motherboard problem with a faulting drive controller and/or BIOS.

"But it really must take like 30-60 minutes for a real system file check even on fast computers so there is something fishy here. Why it doesn't scan the system drive???"
If the drive has a LOT of files on it than yes, it can normally take well around that long to do a CHKDSK run, longer if you have it look for bad sectors as well. However, if it's unusually long without not having much space used up, then it's conducive - again - of a failing drive.
 

My Computer

OS
Windows 7 64-bit
SIW2 is there any chance I could delete my partition/files using those commands
No.
The first two commands give me the same error which doesn't show up in google exactly the same:
bfsvc could not open the bcd template store status = [c000000f ]

The third command says I cannot update the boot code of partition D because it cannot be locked. Access is denied.
There was a drive lock enabled feature enabled. It is HP 625 and it said that it needs password after each restart yet it wasn't asking for one so I didn't expect such an issue.

BTW I don't have the "boot" folder in my system drive D:\ which I think is important to boot Windows normally!

BTW the BSOD could be happening because of my msahci.sys driver not being suitable for the system but I've taken it straight from the reserve drivers folder. But even then this driver isn't required for booting from Safe Mode which doesn't work (it restarts automatically).

[FONT=Courier New, Courier, monospace]G:\boot\bootsect /nt60 D:[/FONT]
g is my dvd drive (Windows 7 install cd)
d is my hdd windows partition
this command says it is all successfully completed.
But if I type it like this

[FONT=Courier New, Courier, monospace]G:\boot\bootsect /nt60 all
it gives the access is denied error on D: drive only. All other seem to be okay.
The hdd has 4 total partitions.
[/FONT]
[FONT=Courier New, Courier, monospace]G:\boot\bootsect /nt60 all[/FONT][FONT=Courier New, Courier, monospace][FONT=Courier New, Courier, monospace] /force
This fixed the last access is denied error :).
I used
[/FONT]
[/FONT]detail disk
and it shows boot disk: no
4 volumes which doesn't have anything on Info. The system(active/boot partition is for some reason NTFS and D drive doesn't have a label).
The 100 mb partition is as follows:
Partition 0 Type : 07 Hidden: No Active: Yes

From this article How can I check that I am using MSAHCI? - The Corsair Support Forums
it seems msahci is a driver for SSD and I think it loads even in safe mode. Safe mode does give bsod but it restarts immediately. Maybe I should try repairs with ahci disabled from bios. I tried 2 different installation medias. The screen where I select which operation system to repair doesn't show is the OS version 32 or 64 bits which is a problem because I am also not sure since I cannot enter it :D. Yet the disk I use has both versions I am 100% sure because I used it a lot.

I've removed the drive from the notebook and put it right in my PC Win 7 Ultimate x64 and it still gave me the very same error with the big sfc command:
"G:\>sfc /scannow

Beginning system scan. This process will take

Another servicing or repair operation is curre
Wait for this to finish and run sfc again."
OR
"G:\Windows\System32>sfc /scannow /offbootdir=F:\ /offwindir=G:\Windows
Beginning system scan. This process will take some time.
Windows Resource Protection could not perform the requested operation."
This time f is boot drive and g is windows drive.
Now chkdsk won't run on the windows drive:
An unspecified error occurred (766f6c756d652e63 3f1).

This must be a TOP 10 of the ridiculous amount of weird problems happening in a row for a single operating system in the world! Chkdsk runs fine with the DVD. But what if it really doesn't check D: drive although I am in it and rather checks X: drive for some stupid reason. Although it is checking the drive very slowly which is appropriate.

I've scanned with NOD32 latest version the whole disk and the boot disk because NOD32 is very good at detecting and removing MBR viruses but it didn't found anything serious. Now we need to concentrate on what could cause BSOD 0x0000007B and is not chkdsk and bad sectors related.
How can I make the OS to make memory dump files? There is no minidump folder in Windows\ now.

I've replaced msahci.sys with the same file but from my PC (which is 64 bits :D)and now it doesn't give BSOD but it is back to "Loading setup files" or something (automatic system recovery) which returns me again to the same screen to choose repair or start windows normally.
I am back to the BSOD with restoring the original msahci.sys from the driverepository (reserved backup folder for drivers) so I think I just need the correct msahci.sys driver.

The russians have typed a lot about this exact BSOD 0x0000007B (0х80D86B58, 0xc0000034, 0x00000000, 0x000000000) and it seems that the ahci driver msahci.sys (or some other driver) could be DISABLED for some stupid reason from the registry in the OS.
BSOD 0x0000007B
Check the big comment of mAlexey1978
A new error finally.
intelide.sys 0xc000000f missing or corrupt.
It gave me random drivers missing so I replaced them all from the DVD X:\Windows\System32\Drivers folder and again I've got the BSOD just like not having ahci drivers for the disk. Maybe I should download them straight from HP then.
Just to recap I couldn't start sfc on the system drive even once!!! It checks X: drive just not saying it...
Although all the partitions are visible in order to make a new installation I need the ahci drivers which is very rare occurance. I've placed the ahci driver inside my USB thumb drive and it still says that there are no new devices detected (what it needs to detect if I see all the drives I dunno).
With disabled AHCI it still wants some driver!!! In the very same menu as soon as I put an installation dvd media it started okay (without restarting) without using the USB drive. Just installing from the dvd and didn't wanting an ahci driver. Maybe it is a rare drive letter issue and I say rare because I've installed it a dozens of times with the same usb pen drive.
 
Last edited:

My Computer

OS
32 bit Windows 7
The c000000f error from the bcd template thing is telling you that the file does not exist. Again, a filesystem issue. The issue with the 0x7B and the c00000034 (object name not found) is not specific to the AHCI driver not being present. However, it can cause it when Windows is set to run on AHCI while the system BIOS has the SATA mode set to IDE, or vice versa. They both must be the same: either BIOS has to be in IDE and msahci not loaded; or BIOS has to be set to RAID or AHCI and Windows set to load msahci.

The boot folder should be in your boot partition, which isn't always your system partition. So if the first partition in the system has boot folder but you have Windows on another partition, then that's ok as long as the one with the boot folder is the one that the system starts up on and it redirects everything to Windows on the other partition. So is the boot folder on your C: partition instead of your D:?

As for SFC still giving grief, when you start into the recovery environment and you select the Windows partition you are trying to work on, does it actually prompt you for an administrative password? It sounds an awful lot like you're getting access denied issues because you haven't entered proper administrative login credentials for that Windows installation, and so the recovery commands are having difficulties working because of it. Make sure you're working with the proper credentials.

You can try to tinker with the msahci or IDE/AHCI SATA mode to see if that'll get a fix in, but TBH, if that fails, I really think that your partitions and Windows installation has somehow reached a level of corruption where manual fixing is going to be extensive and requires advanced filesystem knowledge to work on to repair it. It sounds like it'll just be better to deal with a clean Windows install. It's a last ditch option, but considering the extensive work already put into this and the time it's already taken to revive it, it starts sounding more and more like the better option. Just backup your files to another drive and then reinstall Windows, making sure to remove all partitions on that drive first and recreating new ones.
 

My Computer

OS
Windows 7 64-bit
It didn't asked me for credentials a single time. Also I need administrator access to run chkdsk /R command too but it never asked me anything.
I've solved the problem with new installation sadly. :( I wanted to fix it for my own knowledge/experience but in the end it doesn't really matter that much. Thanks again for the help.
 

My Computer

OS
32 bit Windows 7
I know the determination - believe me I've been there - but there are some issues that go beyond even advanced technical support experience and enters the realm of deep hardware internal diagnostics and other stuff reserved only for highest echelons of computer prowess, such as escalation engineers and filesystem developers. Even then it may be a case where someone of that expertise would discover the exact problem, but say it's unrecoverable and the only means of fixing would be to backup and replace.

I'm not the brightest bulb when it comes to this stuff, but I am aware of being a bit more advanced than the average PC technician, yet I know well I'm better off not tinkering with stuff far beyond my skill level. I wouldn't want to waste time and effort to learn how to reconstruct a partition table manually when I can just backup and reinstall. There's a time and place for learning that stuff, but it ain't going to be through a need-to basis - you can't be a guru in a couple days with this kind of stuff.

Sorry that we couldn't help you further on the matter. However, given that the new installation seems to work, it does appear that we were at least close -if not dead on - in our evaluation that the MBR/partition table was broken, and that no manner of software nor manual editing is going to fix it. Best thing I would do after that would be to try and evaluate what could've done it - an infection? Hard drive failure? Not just anything can corrupt an MBR/partition, so you'll want to got through the possibilities of what could've done it then prepare accordingly. If it's something like a hard drive or disk controller having issues, then no manner of reinstalling is going to fix it. You'll want to see what you can do about finding the root of the problem, and if you can't, just shrug it off and move on.
 

My Computer

OS
Windows 7 64-bit
Thanks for the nice comment Vir Gnarus. I guess the problem is maybe a not common version (or modified somehow) of Windows 7 being installed prior to the problem. It's possible that the installation could've been made using an image made with the sysprep command for fast Windows 7 deployment. Couldn't find viruses with two good AV softwares so I guess damaged Windows from updating or MBR/Boot issue. The way how it always started Automatic Startup Recovery was very weird and I am sure it wasn't caused by a damaged keyboard :D. The people who were using the notebook didn't had much knowledge so they could've erased some drivers/boot files without telling me lmao ;D. Now the question is should I mark the thread as "Solved" although new installation is not so good solving in some cases.
 

My Computer

OS
32 bit Windows 7
Back
Top