Jump to content

Yet another corrupt sys file!


5614

Recommended Posts

So I was playing around with my winXP kernel hoping to improve the system a little, it's nothing I ain't done before! I decided to replace my current kernel with a updated version I made a few weeks back but never got around to booting into safe mode for to override current system files. This kernel I was playing with is the ntsokrnl.exe which some of you may have seen before, it's a windows critical file!

 

Anyway, after successfully implementing my new kernel my computer couldn't boot. I went into safe mode (where it shows what is loading) and it got stuck on ntsokrnl.exe.... I had a corrupt version of windows which couldn't start!

 

So I boot off the winXP CD and tell it to instal windows. When it sees I have a version installed it asks me whether I wanna fix or instal a new version... I tell it to fix (note I selected instal first, then fix later... you can chose fix at the beginning, you do not wanna do that!) and it basically reinstalls windows.

 

Now I'm bored waiting for all the winXP updates to download again!

 

Cause of the prob: Not sure, a few possible explanations. ntsokrnl.exe being a windows critical file could have been updated in a standard windows update after I made my mod version of it. When I implemented the new version it'd confused the computer as the kernel would appear corrupt. Or maybe the file had just become corrupt.

 

Otherwise (this may be Dell computers only, I'm not sure) go to the registry:

 

HKEY_Local_MACHINE/Software/Microsoft/Windows/CurrentVersion/Policies/System/

 

And there'll be two keys here; one called legalnoticecaption and the other legalnoticetext... try adding some data into these two fields (just text, maybe "hello" or something) then reboot your computer... you'll see the difference! (That's for winXP, maybe only Dell) Also only do that if you think you know what you are doing! Editing registries can screw up your computer (and funnily enough I am not saying that from personal experience!!!)

Link to comment
Share on other sites

Hmm, 5614, what books do you read to know in such extent about Windows??

 

There isn't any much book talking in a very depth about Windows, unless you commit yourself in programming alot in windows API, and read a big, boring book about Windows INternals.

 

Albert :)

Link to comment
Share on other sites

I just learn it myself. Everything I know about computers I've taught myself. Hence if you search the site you'll find me asking how to set up a network, basics, but just shows! Also I play around a lot... the title "yet another" is because it's hardly the first time I've corrupted windows beyond use! So it takes 30mins to reinstal windows and then I'm off again, you can learn a lot that way.

Link to comment
Share on other sites

:D.... no! I'm just saying that the only thing I've ever been taught in school is how to use MS Word/Excel and this year for the first time how to use Access (oooh!!!), they never even taught us how to use HTML (although they do teach that to younger years now), but yet I know a lot! The answer is that I play around with stuff.

 

It's all fairly logical and if I see something and I don't know what it does I'll look into it and possibly play around with it, if I screw up boot in safe mode and fix it, if not use system restore (which is risky because viruses can archive themselves in restore points) or reinstal windows. Either way I learn what it is and what it does, be it by playing with it or the harder way!

 

I was just using resource hacker to play around with stuff, there were some threads on it a while back.

http://www.scienceforums.net/forums/showthread.php?t=8194

&

http://www.scienceforums.net/forums/showthread.php?t=8195

Link to comment
Share on other sites

the title "yet another" is because it's hardly the first time I've corrupted windows beyond use! So it takes 30mins to reinstal windows and then I'm off again, you can learn a lot that way.
youd learn more if you tried to learn how to fix it after you break it (theres a command-line thingy in the repare console that you could have used to extract just the ntoskernel from the instalation cd to the hdd, thus fixing your pc without reinsalling)

 

but yeah, breaking stuff is an excellent way of learning how stuff works. make sure to make regular back-ups if you do, though.

Link to comment
Share on other sites

heh, me don't think so!!! The comp wouldnt start in normal/safe/command line or nothin... and you can't access a NTFS drive (which mine and most people's HDD are) from DOS ;) In that past I've been able to fix probs in both safe mode and DOS, but not this time.

 

Interestingly the Windows reinstallation really screwed up Win Media Player, I assume because it installed v8 and I originally had v10... so now the comp had parts of 8 and parts of 10 so every time I even tried to open it it had a "Internal program error" or something like that... installing a fresh copy of v10 on top of everything fixed that!

Link to comment
Share on other sites

could you not whack the installation cd in and access the recovery consol?

 

i dont have too much experience in this area, but i was under the impression that the installation cd could load the drivers nessesary to make changes to the hdd, and so could copy across missing/corrupted files from the cd to the hdd.

Link to comment
Share on other sites

No. I didn't try it this time, but I have in the past. I ran into an Administrator password which I didn't set and don't know what it is/was. Maybe that isn't there now, when I last tried it it was on the original XP installation, maybe now I've reinstalled it won't be there.

 

Also I once booted off a 98 boot disk which got me into DOS, it was then I learnt that DOS can't access NTFS.

Link to comment
Share on other sites

I just went into Windows Recovery Console (available when you boot off the XP CD) and again I ran into the Administrator password, but this time it was blank, like it should be, the pre-installed copy of winXP must have had a default password which I don't know.

 

Also I only had access to C:\Windows I could not access My Documents, Program Files, nothing... just windows.... sadly I didn't think of trying to access the CD drive, too late now, can't be bothered to do it again just to see!

Link to comment
Share on other sites

it is apparently just as simple as wrighting something to the effect of

 

"expand D:\i386\ntoskrnl.ex_ : C:\WINDOWS\system32\ntoskrnl.exe"

 

in the recovery consol, and the file is uncompressed from its location on the install cd and copied to your os.

 

although tbh, i would have thought that a recovery disk would allow your OS to boot (as i ntoskrnl is one of the files found on a recovery disk), and then you could actually replase ntoskrnl.exe from within XP itelf?

Link to comment
Share on other sites

i would have thought that a recovery disk would allow your OS to boot (as i ntoskrnl is one of the files found on a recovery disk), and then you could actually replase ntoskrnl.exe from within XP itelf?
Without a working ntoskrnl you cannot start windows, under any conditions... I don't understand what you are trying to say.
Link to comment
Share on other sites

your right about not being able to boot from a start-up disk; i was getting cofused and thinking about other files, earlyer in the boot sequense. sorry bout that.

 

as for the recovery consol, here is a link. you can load up the recovery console from the instalation CD even if ntoskrnl is shafted beyond recognition, and then replace ntoskrnl either with a back-up copy which is saved on your hdd, or from the copy on the instalation CD.

Link to comment
Share on other sites

Yes. That's because you are booting off the CD and running everything through the CD. That's what you do when you have a brand new computer with nothing on it at all, you boot off the CD and instal an OS so that you can use the computer normally.

Link to comment
Share on other sites

yes, i know...

 

my point was simply that, rather than an entire over-the-top/repair installation, you could have simply used the recovery consol to replace just your ntoskrnl, thus saving yourself the effort of having to update everything again.

Link to comment
Share on other sites

Yes, that's true, but as I said, last time I used the recovery console I ran into unknown passwords and have since not used it (until earlier today). I suppose now that admin password is no longer there it'll be a useful feature.

 

Incidentally my Power Schemes http://www.scienceforums.net/forums/showthread.php?t=9824 still do not work after the reinstallation, weird.

Link to comment
Share on other sites

try this:

 

back up your registry first! (goto regedit and click export on one of the tags at the top).

 

go here

 

copy the code into a notepad file, ensuring that there is NO SPACE at the beginning (ie, the regedit bit is right up the top of the notepad) and that your computer doesnt do the stupid thing that mine just did, ie puts random spaces in at potentially reg-shafting places.

 

in notepad, goto 'save as type', and select 'all file types'. for 'save as', type "givemebackmyfarkingpoweroptions.reg".

 

now, locate the givemebackmyfarkingpoweroptions registry file. double click it and select 'yes' when it asks if you want to inport it. restart your pc and see if the power options are back.

 

if not, then goto regedit, select 'inport' and restore your back-up copy of the reg.

Link to comment
Share on other sites

You gave me an idea; I went and did it all myself! I went to HKEY_CURRENT_USER\Control Panel\PowerCfg and HKEY_USERS\.DEFAULT\Control Panel\PowerCfg and edited in all the details myself, rebooted, didn't work... So I backed up all registries, double clicked on the file you linked to, it asked me if I wished to import, I said yes, it said it had done it, I restarted, it works fine!

 

Looking at the coding for the file I downloaded (Dak's link) (view coding by 'open with' and notepad) it actually replaces all of them....... just did this now...... I compared the registries in the Dak's link thing vs. the old regs in the backup file I made; my old power registries are different from the replacement ones.

 

Now considering I just reinstalled windows you'd have thought it reinstalled registries like power options! But it doesn't, proof being that it didn't fix the prob! So then why did the registries change in the first place? Honestly don't have a clue!

 

The weird thing was when I went into the registries for the first time to fix em myself I found all my custom-power options (ie. Jonathan [normal options] and DVD [don't turn screen off quickly!]), they were there and working in the registries, must have been the actual KEY_USERS\.DEFAULT\Control Panel\PowerCfg\GlobalPowerPolicy\Policies reg which must have been corrupt... still don't know why... but thanks a lot Dak :)

 

 

[edit]I like the reg mod thingy mentioned at the bottom of the 1st post, so pointless yet cool -- try it, reboot, you'll see the effect! Spot the difference between the caption and the text reg (put in different data values for each) and then you'll see.

Link to comment
Share on other sites

... still don't know why... but thanks a lot Dak
my pleasure :cool:

 

the reason the reistalation left the registry alone is that you only did an 'over-the-top', or fix/repair instalation. theyre desighned to reinstall system files, but not affect other stuff, like documents, non-system files, and reg entries.

 

i shal play with your mod thingy when i have my own pc back... whats it do, pop up a funny message when you log on?

Link to comment
Share on other sites

Aww, I spose the notice part of legalnoticecaption gave it away! Yeah, when you get to the XP log on screen you get a little popup box thingy where the title is what you enter as the data for legalnoticecaption and the text is what you enter as the data for legalnoticetext.

 

I see it at the Welcome Screen thingy, if you use the standard username/password log on then you'd probably see it at the same time, not sure though.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.