chenall/grub4dos

Windows XP in ram - problem with vhd >4GB

stonepark77 opened this issue · 9 comments

Hello everyone !

For several days I’m blocked on a small personal project. I think that someone who knows grub4dos well could find easily the solution.

I want to use windows XP entirely loaded in memory. I followed some tutorials to do so and it works fine when the virtual disk is smaller than 2GB.
But with a 4 GB vhd, windows XP does not start, and after several blinking of the screen, the computer just reboot.
Is this a limitation of Grub4dos ? Windows xp ? Are my commands wrong ?

I have a computer with I5 3300 and 16 GB of ram.

With a virtual disk of 2 gb named xp2gb.vhd

Grup> map --mem (hd0,0)/xp2gb.vhd (hd0)
Grup> map --hook
Grup> chainloader (hd0,0)/ntldr
Grup> boot

Everything works perfectly !!

Now I try with a virtual disk of 4 gb named xp4gb.vhd, same command

Grup> map --mem (hd0,0)/xp4gb.vhd (hd0)
Grup> map --hook
Grup> chainloader (hd0,0)/ntldr
Grup> boot

The screen blink, and the computer reboot

What I already tried :

  • differents versions of Grub4Dos (0.4.1 to 0.4.6)
  • a vhd of 4 GB with windows xp 64 bits instead of 32 bits
  • a compressed vhd with gzip
  • the --top option

Is it just impossible to do with Windows XP ?

All suggestions are welcome. Sorry for my English level

XP 32bit is a 32 bit os and can only access the bottom 4gb of memory, but since up to approx. 500mb of memory space at the top is often occupied by chipset registers, etc. You really have 3gb and a bit, of the lower 4gb of ram, especially as grub4dos may be taking up a fair few mbs too.

Does the xp 64 bit vhd boot if you just make a 2gb vhd? Are you using correct 64 bit drivers?

Virgus commented

Have you tried using kernel alternatives which enable PAE ?
I've been using PAE Gamersky 64GB tweak with an XP vhd and 32GB. I used SVBus for filebooting in the past but never tried ram booting with an XP vhd. But it might work also for ramboot.

There's a second PAE tweak named PAE fix128 v48 but cannot find a working link. I never tried this second one but it might work as well and I'll test it sooner or later as I just upgraded to 128GB.

Please let us know how your test ends, I'm quite interested !

For your convenience I put both here

Cheers,
V.

EDIT I just remembered of a third patch in Ramsey's XP Patch Integrator that you can find here. But it might rely on the first one of the previous two.

Thank you both. You've given me a lot to work with and I'll be doing a lot of testing tonight. I'll keep you informed on the results !!!

@steve6375

Does the xp 64 bit vhd boot if you just make a 2gb vhd? Are you using correct 64 bit drivers?

Just tried. Yes, a xp 64 bit with 2gb vhd...boots. The system boots and displays the Window's desktop briefly. But after 3 seconds, Windows crashes. Probably a driver problem but anyway, it boots. Unlike the same setup but with a 4gb vhd.

For the scsi driver, I use winvblock driver.

@Virgus
I don't use "PAE Gamersky 64GB tweak" or the second one. Or any patches... But on the physical machine, I use the simple method with "ntkl64g.exe + hal64g.dll" in windows\system32 and the boot.ini modified. It works for me.

On this physical machine, all 16 gb of ram are recognized and usable. I'll try tomorrow a 4gb vhd with a xp 32 including the PAE trick.

Hello ! Sorry for the delay.
I was a bit busy and had to do a lot of vhd and testing.
But finally, everything is ok, I managed to make xp work with a 6GB vhd disk. All loaded in memory.

Currently, the package that works :

  • Windows xp pro 32 bits
  • SVBus driver as you suggested @Virgus
  • grub4dos version 0.4.5c

It also works with PAE mode, all remaining ram is well recognized.

It's really amazing... Windows XP in ram. Everything is so instantaneous, it's so fast.

But unfortunately, I didn't manage to achieve what I wanted.

Everything is ok with a "basic" xp installation as I said.

But it was not my goal.

My goal was to use an existing image of my system, with a lot of software installed (microsoft office, internet browser etc) and pc drivers (sound card, graphics card, motherboard etc).
And make it work all in memory. But it seems impossible. A vhd with this system image just don't boot.
Maybe driver problems, or problems due to the particular functioning of grub4dos or virtualbox limitations to make a vhd with a physical to virtual. Too many variables.
But the result is that it doesn't work despite hours of testing and re-testing. Maybe it's just impossible to do. Too bad.

Virgus commented

No problem @stonepark77, we're all subjected to time constraints.

Thanks for the update I'm glad to know that you made it. I don't have the time now to do some tests but what you've achieved is in my plans for the next future. I hope I'll have the time to dig into this in the upcoming summer. Concerning your unreached goal, since it's out of topic for the G4D repository, would you like to exchange information privately ? You could drop me a line at this temporary address and I'll reply from my personal address.

I've used XP with all drivers and software installed on a VHD in the past via SVBus fileboot and if your issue is related to size you could just use junctions for the software folders. Thus booting in Ram just with the OS and loading all the rest from the ssd.
There are further reductions possible (which I use on W10 and will need testing on XP) and there are portable apps which I use extensively and are really useful to avoid software setups.

BTW Did you try SVBus with Kai's G4D patched version ? For ramboot loading via NVMe is really fast. It can be chainloaded via G4D official version so that you could use this old 2018 version just for ramboot.

@Virgus
Indeed, this is beyond the scope of G4D. I would be happy to exchange information privately.
I sent you a message15 minutes ago, tell me if you didn't received it.

Virgus commented

@stonepark77 message received, thanks. I just replied to your email.

Problem solved. Everything is working with G4D 0.4.5c. Thank you all, I close this thread.