Christianb 8 Posted October 9, 2002 Hi I would like to know how you can tell from Dos if a system just hibernated? I'm writing a utility that I'll run before Norton Ghost. I know there are windows Backup titles and many other options. However I actually like backing up in dos. Almost nothing can go wrong. No Virusses, No crashing, No files in use, No etc... Also you can delete Hiberfil.sys if the user didn't just hibernate. Of course you can delete it anyways, but that would definetly be annoying: getting error messages and loosing your application states, and possibly some unsaved files. So how about it do any of your MCPs, A+'s, or MCSEs know how to do it? Thanks a zillion, Christian Blackburn Share this post Link to post
Tomay 0 Posted October 9, 2002 I just played with my second system which has 2 partitions C: win98 D:w2000 sp3. I hibernated, and then used a cdrom to boot into dos. (took me a while, cos I got an old scsi burner and it took a few tries to figure out that the boot sequence has to be scsi... to boot from scsi cd-rom ) Since I still like to use dos from time to time I understand you. But I hate ntfs and sometimes even fat32 and sometimes even norton comannder, cos it cuts all my long filenames and then everything looks like file~1. I figured out two ways to determine if a sys is hibernated. On my C: was a file called "hiberfil.sys" just like the one od D: but just 40 bytes long, and when I opened it was "linkmulti(0)disk(0)rdisk(0)partition(2)" I deleted the file and the system did not resume from hibernation, but went to the bootmenu. I wandered if there wobuld be any errors if I booted win2k, so I tried, but it didn't do a fresh boot it just returned from hibernation. So at boot the hiberfil.sys is checked before boot.ini so if you have a multi os system you can't boot to other systems while in hibernation or can you? I tired after deleting the hiberfil.sys on c: and I could boot to w98 and then normaly resumed from hibernation afterwards. (but be careful when you do this on w xp without the sp1 or w2k without sp3. Everything i changed, installed ... while in hibernation booting to another system was trashed and put in a "found.000" folder when resuming from hib. M$ says it is fixed in the sp1, but be careful) when you're not in hibernation there is no hiberfil.sys on c: so you could write something like "if exist c:hiberfil.sys then..." (haven't got an A+ in programing) So how does the windows know when it's hibernated and when not. When viewing the hiberfil.sys on d:, that has the size of my ram i noticed "hibr" at the start of the file when it was in hibernation, when it was not there was nothing i could read. This is for a multi OS system i don't know what happens when you have a single xp sys. But try to look for something similar. Hope it helps. Good luck. Btw post back when you wrote the utillity and what it does. I'm interested (very) 8) Share this post Link to post
Christianb 8 Posted October 9, 2002 On a single OS system HiberFil.sys is always present. I have to take a look a the start of the HiberFil.sys file, thanks for your help. The HiberFil.sys is also always = my ammount of ram or not there if I deleted it. Share this post Link to post
Christianb 8 Posted October 9, 2002 Thanks for your Help Tomay, Christian Share this post Link to post
Tomay 0 Posted October 10, 2002 I'll take a look at a single OS system, when I get to one. Right now all my comp's a multi os. I guess I just can't without the old w98. Share this post Link to post
Christianb 8 Posted October 10, 2002 Ya I emulate windows 98 in my Virtual PC 5.0 program. Share this post Link to post
Christianb 8 Posted October 10, 2002 I use Virtual PC for software development mainly so I can test compatiblity. Share this post Link to post