Jump to content

Install XP from a RAM loaded ISO image


cdob

Recommended Posts

Install XP from a RAM loaded ISO image. Use a default XP ISO image.

Addional files are at a F6 virtual floppy.

After years of search a new driver is developed:

FiraDisk: File/RAM Disk driver for Windows.

http://www.boot-land.net/forums/index.php?showtopic=8804

The driver is at early development.

The driver does mount a grub4dos RAM drive.

That's awsome and can be used at a lot of conditions.

Use grub4dos to load a virtual floppy and XP installation image to RAM first.

The virtual floppy is used at F6 stage.

32 bit FiraDisk drivers are loaded by default.You don't have to press F6.

You may press F6 to get selection choice.

There is a fake setup.exe used after first reboot.

The idea is used from drivers from CD

The integrated version is changed: this fake setup.exe launch a batch setup.cmd.

There are includeded the source code, a hidden window processed setup.exe.

And a visible window debug version setup_dbg.exe. To use this version rename this to setup.exe.

The fake setup calls the original, renamed setup: setupORG.exe

The original version is not includede. Therefore edit the floppy image and add the file:

Expand setup.ex_ from your windows version

expand.exe SETUP.EX_ setupORG.exe

copy the file to \setup\I386\setupORG.exe or \setup\AMD64\setupORG.exe

BTS DriverPacks method 2 are supported. http://driverpacks.net/

This use a fake setup and setupORG.exe too.

If you use a DriverPacks version, copy this setupORG.exe to floppy image.

You may add a file \WINNT.SIF too.

Used files at USB:

\Inst\XP_INST.IMA

\Inst\XP_RAM.ISO

A basic XP_INST.IMA is attached. Add setuporg.exe as described.

XP_RAM.ISO is a default XP ISO image. This file is loaded to RAM.

grub4dos menu.lst

title Loading XP RAM install - /Inst/XP_RAM.ISO
ls /Inst/XP_RAM.ISO || find --set-root /Inst/XP_RAM.ISO
map --mem /Inst/XP_INST.IMA (fd0)
#(fd1) optional, required at some BIOS
#map --mem /Inst/XP_INST.IMA (fd1)
map --mem /Inst/XP_RAM.ISO (0xFF)
map (hd0) (hd1)
map (hd1) (hd0)
map --hook
chainloader (0xFF)/I386/SETUPLDR.BIN

Assumptions:

hd0 : booted USB device

hd1 : windows target device

Tested at virtual machine. Has to be tested at real hardware:

several hard disks, several USB drives, internal multi card reader

As wimb indicated, comment this if you read and install to the same hard disk.

#map (hd0) (hd1)
#map (hd1) (hd0)

XP installation from CD and remapped drive order:

Files are not deleted from installation media.

Setup creates a valid boot.ini. No need to fix boot.ini.

Boot once from USB.

Setup may assign letter c: to another device.

C: is not available for new installed windows.

Setup.cmd deletes MountedDevices.

At reboot windows assign letters again: c:\windows

txtsetup.oem copy a flag file fixDrive.USB to activate this behaviour

If you don't need this behaviour, comment the lines

;dll = setup, fixDrive.USB

Setup.cmd uses ImDisk to mount the ISO file.

http://www.ltr-data.se/opencode.html#ImDisk

The name \Inst\XP_RAM.ISO is the internal default.

The name can be configured:

The floppy image contains a file \setup\ISOimage.ini. Edit this file.

Next the file $winnt$.inf is adjusted.

Windows setup continues and use the mounted ISO file.

Install from USB to USB is possible too.

This part based on Dietmar's tutorials. http://www.winusb.de

Read \USB32\to_usb.txt for details.

At windows setup press F6 and load firadisk and all usb drivers.

In addition there is optional approach to lower RAM usage, e.g. use a 600mb image at 512mb RAM.

Integrated mkISO_RAMload_sort.cmd creates a sorted ISO image:

boot and textmode files are in front of media.

Mkisofs.exe, dd.exe and gsar.exe are used to the create the ISO image.

http://cdrecord.berlios.de/private/cdrecord.html

http://www.student.tugraz.at/thomas.plank/

dd.exe http://www.chrysocome.net/dd

gsar.exe http://home.online.no/~tjaberg

Given a sorted ISO image, OEM at end of ISO image.

Use grub4dos map to load first part to RAM only.

Integrate all \I386 and \AMD64 files.

IsoBuster Free does list LBA (Logical Block Address) of files. http://www.isobuster.com/license-models.php

The LBA show the file location. Calculate N: LBA of file and add file length

Use this number to load image to RAM.

Example: load the first 234567 sectors to RAM.

Remember one CD sector holds 2048 byte data

title Loading XP RAM install - /Inst/XP_RAM.ISO (0xFE)+234567
ls /Inst/XP_RAM.ISO || find --set-root /Inst/XP_RAM.ISO
map --mem /Inst/XP_INST.IMA (fd0)
map /Inst/XP_RAM.ISO (0xFE)
map --hook
map --mem (0xFE)+234567 (0xFF)
map --hook
chainloader (0xFF)/I386/SETUPLDR.BIN

XP_RAM.ISO has to be continuous, defrag a splitted file.

v02:

firadisk updated: map to (fd0) only. F6 does work

64 bit prepared, unfortunately BSOD 0x7b at 64 bit firadisk

added flag file fixDrive.USB

added config file ISOimage.ini

under construction: install from USB to USB

v03:

added: install from USB to USB

added: added sorted files

added: multiboot ISO image, sub directory

v04:

ISOimage.ini is enabled by default

enhanced: sorted files, experimental RAMboot.lst created

v05:

update: firadisk and imdisk driver - flat file possible in addition

if required, USB drivers loaded at a addional reboot

v06: major redesign:

One driver only - firadisk

no need to include setup.exe in floppy image

XP_INST_v04.7z

XP_INST_v05.7z

XP_INST_v06.7z

Edited by cdob
Link to comment
Share on other sites


That's awesome cdob, thanks :thumbup

A few notes:

Direct editing of $winnt$.inf in 64 bit versions would not work:

http://blogs.sepago.de/nicholas/2008/03/13...on-windows-x64/

Maybe start another batch just for editing $winnt$.inf?

start64.exe "%systemroot%\system32\cmd.exe" "/c %systemroot%\syswow64\editinf.cmd

or with path whereever editinf.cmd lands when used from txtsetup.oem.

Samo approach is used in WinSetupFromUSB to start binifix5.cmd, which edits $winnt$.inf.

Another idea- could ImDisk be avoided and use boot.ini options to mount Firadisk emulated drive?

http://www.boot-land.net/forums/index.php?...ost&p=77090

Is Firadisk added as a service with start 0 by Setup when used during text mode this way?

There was a way if I recall correctly to include default options to boot.ini via txtsetup.sif or winnt.sif. Maybe txtsetup.oem could be used, or winnt.sif in the floppy image :unsure:

This way editing of $winnt$.inf may not be needed, if Firadisk creates the same device as if mounted by grub4dos.

Link to comment
Share on other sites

Direct editing of $winnt$.inf in 64 bit versions would not work:
Well, maybe I should have mentioned, first release is 32 bit only.

There are 32 bit drivers and a 32 bit fake setup.exe included so far.

The included fake setup source code does compile at 64 bit mingw environment.

Use a 64 bit fake setup.exe to edit a 64 bit $winnt$.inf.

I like to solve F6 loading first, then create a 64 bit version.

Another idea- could ImDisk be avoided and use boot.ini options to mount Firadisk emulated drive?

Some patience please. Been there already and failed so far.

ImDisk is arround since some years, works pretty stable.

Is Firadisk added as a service with start 0 by Setup when used during text mode this way?
Yes, firadisk is set to start=0. It seems to be possible, to use boot.ini in future. Or firadisk support registry in future.

Anyway you have to set ISO image location XP_RAM.ISO. This maybe difficult to set a unique location within txtsetup.oem (current approach should work at multi DVD too).

Added:

F6 does work with new firadisk 0.0.1.12.

Edited by cdob
Link to comment
Share on other sites

Thanks for sharing XP_INST.IMA
A addional hint: firadisk F6 floppy image does work at a PE too.
May I ask why the need to map XP_INST.IMA:

Twice was the work arround without full floppy firadisk support.

Compare http://www.msfn.org/board/index.php?s=&amp...st&p=881138

This is not necessary anymore at firadisk 0.0.1.12.

Once is sufficient now

map --mem /Inst/XP_INST.IMA (fd0)

Link to comment
Share on other sites

Successful tested for Install of XP-SP3 on real hardware (including internal multi-cardreader) :thumbup

Did not use USB-stick.

AFTER format of Harddisk install partition, I installed grub4dos as boot option in boot.ini menu using BOOT_IMG.exe

Then copied folder Inst with XP_INST.IMA and XP_RAM.ISO to Harddisk.

Made entry in menu.lst without the mapping for USB-stick

title Loading XP RAM install - /Inst/XP_RAM.ISO
ls /Inst/XP_RAM.ISO || find --set-root /Inst/XP_RAM.ISO
map --mem /Inst/XP_INST.IMA (fd0)
map --mem /Inst/XP_INST.IMA (fd1)
map --mem /Inst/XP_RAM.ISO (0xFF)
# map (hd0) (hd1)
# map (hd1) (hd0)
map --hook
chainloader (0xFF)/I386/SETUPLDR.BIN

After Reboot Select Loading XP RAM install from grub4dos menu

Loading of XP_RAM.ISO in only 10 seconds in firadisk RAMDISK (instead of loading in 25 minutes from USB-stick)

TXT-mode FileCopy in only 1 minute

GUI-mode has an extra immediate Reboot.

Total XP Install time 15 minutes

Then tried to do the same with XP-SP3 Slipstreamed with UpdatePack and 5 DriverPacks.

After first Reboot for GUI-mode the DriverPacks were extracted successfully.

After second Reboot for GUI-mode has problem of SetupORG.exe NOT found.

Has to look into more detail what is causing the problem ....

Edited by wimb
Link to comment
Share on other sites

...

Made entry in menu.lst without the mapping for USB-stick

title Loading XP RAM install - /Inst/XP_RAM.ISO
ls /Inst/XP_RAM.ISO || find --set-root /Inst/XP_RAM.ISO
map --mem /Inst/XP_INST.IMA (fd0)
map --mem /Inst/XP_INST.IMA (fd1)
map --mem /Inst/XP_RAM.ISO (0xFF)
# map (hd0) (hd1)
# map (hd1) (hd0)
map --hook
chainloader (0xFF)/I386/SETUPLDR.BIN

What happens with boot.ini on internal hard disk in that case?
Link to comment
Share on other sites

What happens with boot.ini on internal hard disk in that case?

Internal Harddisk partition for Install of XP was first formatted (e.g. from PE environment)

Then BOOT_IMG.exe was used to make internal Harddisk bootable with grub4dos entry in newly created boot.ini menu.

After Reboot Select Loading XP RAM install from grub4dos menu as given above.

There is no USB-stick used in my approach.

There is no boot.ini problem. (booting is all the time from the same Harddisk partition used for Install of XP)

boot.ini before Install of XP

[Boot Loader]
Timeout=20
Default=C:\btsec\RMLD1.bs
[Operating Systems]
C:\btsec\RMLD1.bs="PE 1 - Boot X78W.img from RAMDISK"
C:\grldr="Start GRUB4DOS Menu"

boot.ini AFTER Install of XP

[boot loader]
timeout=30
default=multi(0)disk(0)rdisk(0)partition(1)\WINDOWS
[operating systems]
multi(0)disk(0)rdisk(0)partition(1)\WINDOWS="Microsoft Windows XP Professional" /noexecute=optin /fastdetect
C:\btsec\RMLD1.bs="PE 1 - Boot X78W.img from RAMDISK"
C:\grldr="Start GRUB4DOS Menu"

Edited by wimb
Link to comment
Share on other sites

TXT-mode FileCopy in only 1 minute

GUI-mode has an extra immediate Reboot.

Files are read from RAM, hence the fast file copy.

The extra reboot is by intention, USB support is added. Maybe selectable in future.

Then tried to do the same with XP-SP3 Slipstreamed with UpdatePack and 5 DriverPacks.
DriverPacks are not supported yet. This is not a default XP ISO image.

Yes, there are parts for testing included. This part is not documented.

Technically it's insane to load this 7z files to RAM.

Including mass storage and chipset packs may make sense.

Contrary it's insane to include all driverpacks to ISO image. A huge data is loaded to RAM, without usage.

Haven't made a decision so far.

Link to comment
Share on other sites

Including the 5 small DriverPacks (C CP L M and W) is quite useful and the extra load of 36 MB of the OEM folder does not take too much time or space.

For Sound and Graphics DriverPacks the load is rather heavy and I decided then to provide the specific required drivers in $OEM$\$1\Drivers folder.

DriverForge is used automatic at T-9 to install these drivers by using UserExecute command in [setupParams] section of winnt.sif file.

In this way the extra load remains limited and all drivers are installed during XP Setup.

In the case of using DriverPacks, what is causing then the Error of setupORG.exe is missing ?

Is it may be a name conflict by using twice the same mechanism of fake setup of Pyron ?

It would be nice if the problem can be solved.

Link to comment
Share on other sites

SOLVED the problem of missing file setupORG.exe in case of XP Source slipstreamed with DriverPacks. :thumbup

The file setup.ex_ used to edit the floppy image must be taken from the original XP setup source,

since slipstreaming with DriverPacks makes a new setup.ex_ which when used will cause the reported problem of missing setupORG.exe

Edit the floppy image:

extract setup.ex_ from your ORIGINAL windows version

copy setup.exe to \setup\setuporg.exe

Install of XP including DriverPacks did run now very well :thumbup

NOW after second Reboot for GUI-mode the DriverPacks are extracted as it should be :rolleyes:

Loading of XP_RAM.ISO in only 10 seconds from internal Harddisk into firadisk RAMDISK is preferred,

instead of loading the RAMDISK in 25 minutes from USB-stick.

In this way one can Install XP from USB without booting from USB.

Edited by wimb
Link to comment
Share on other sites

setupORG.exe in case of XP Source slipstreamed with DriverPacks.

setupORG.exe from XP Source slipstreamed with DriverPacks is a renamed ORIGINAL setup.exe:

new name setupORG.exe

This approach and naming goes back to Pyron http://www.msfn.org/board/solved-drivers-cd-t12566.html

Acutally I assumed, you copied setupORG.exe from XP Source slipstreamed with DriverPacks to the floppy image.

And wondered about the error report.

Added: Idea for full BTS support:

Given a sorted ISO image, OEM at end of ISO image.

Use grub4dos map to load first part to RAM only.

Does grub4dos support loading half a file?

Added 2:

Example: load the first 234567 sectors to RAM.

Remember one CD sector holds 2048 byte data

title Loading XP RAM install - /Inst/XP_RAM.ISO (0xFE)+234567
ls /Inst/XP_RAM.ISO || find --set-root /Inst/XP_RAM.ISO
map --mem /Inst/XP_INST.IMA (fd0)
map /Inst/XP_RAM.ISO (0xFE)
map --hook
map --mem (0xFE)+234567 (0xFF)
map --hook
chainloader (0xFF)/I386/SETUPLDR.BIN

Added 3:

Just to confirm. Yes, the idea does work.

You may add several hundred megabyte data with BTS driverpacks method 2 to end of ISO image.

And you may RAM load first part of ISO image only. Driverpacks addon won't require more RAM usage.

Windows installation does work.

Edited by cdob
Link to comment
Share on other sites

This didn't work that great, when the first stage installer was done and it rebooted for the second stage, there was a cmd window "setup -newsetup" and a box saying "Error starting the MSI file". After you click OK it reboots and same happends again. I tried both without the stick in the USB and with the stick in the USB and same thing.

So heres what I did:

Installed the grub4dos to a USB drive with fat32 FS

Added the "Loading XP RAM install" item to the menu.lst

Deleted file "I386/setup.ex_" from the "XP_RAM.ISO"

Copied "XP_RAM.ISO" to the USB Stick at "Inst/XP_RAM.ISO"

Copied the file "SUPPORT/TOOLS/SETUP.EXE" from inside "XP_RAM.ISO" to "setup/setuporg.exe" inside "XP_INST.IMA"

(there also was a SETUP.exe at the root of the XP_RAM.ISO but it wouldn't fit the floppy image so I guess its the other one?)

(what is this WINNT.SIF that you "may add", where is it, where you add it?)

Copied "XP_INST.IMA" to the USB Stick at "Inst/XP_INST.IMA"

Booted to the stick with my Eee PC 901 and selected the XP RAM Install

First stage install went just fine without any errors.

The computer reboots to second stage installer, the second stage installer reboots itself right away

After it comes back it spits out the error I described at the top

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
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...