Jump to content











Photo

Boot VHD with win7u to all PC/VM

vhd sysprep

  • Please log in to reply
7 replies to this topic

#1 alisseo

alisseo

    Newbie

  • Members
  • 20 posts
  •  
    Italy

Posted 03 March 2012 - 05:37 PM

This'is my first tutorial. Hove to make Win7u (i make whit 32b) inside a vhd file portable to every pc you want, whit all software you want preinstalled.
Scenario i want install X same software to X different computer without delete the original OS.

Necessary:

-A "PC" whit windows seven installed
-AIK installed or imagex.exe
-EasyBCD 2.1.2 or VisualBCD or BCDedit BCDboot Bootsect.
-One original cd of Windows Seven Ultimate http://www.mydigital...-digital-river/
-7zip or winiso or winmount or virtualcd
-Optional SPAT6.0.9.9 Beta 3
-a little time!


1. Create the vhd file

-Go to Start Rclick to Computer and select Manage
-Clik to Disk Management
-in action menu select create VHD and locate to root C:\win7.vhd of your HD whit size major of 8000mb=8gb (the minimum for win7) type fixed,
the size depend to what you want put inside the os
-then Rclik to blue icon and Initialize Disk whit the MBR style then OK
-Rclik to white area to vhd disk and hit New Simple Volume when the format Wizard is started not change anything, bat remark the unite where the vhd is mounted, in my case is H:

OR

-use diskpart to cmd:
diskpart

		create vdisk file=C:\win7.vhd maximum=8000 type=fixed

		select vdisk file=C:\win7.vhd

		attach vdisk

		create partition primary

		format fs=NTFS quick label="Win7 ultimate 32 VHD"

		assign letter=H

		exit

-now the image win7.vhd is ready and mounted

For improve the different vhd file read to point.9 here tanks sambul61

2. Virtualize the original cd of windows 7 or extract (not necessary) the install.wim

3. Now put the os in the vhd file. start CMD:

imagex /info x:\sources\install.wim

(where "x" is the cd unit, or change the patch to your wim file) the result of this command show you the windows edition present into the wim file.
You need only the "indice number" es: "4" for Ultimate edition.

imagex /apply x:\sources\install.wim 4 H:\

4. Setting the Boot loader to the vhd file

bootsect /nt60 H: /force /mbr

	cd H:\windows\system32

	bcdboot H:\windows\ /s H:

Detach the VHD from real PC to DiskManagement or

diskpart

	select vdisk file=C:\win7.vhd

	detach vdisk

	exit

5. Now the vhd is ready to use whit system inside partially installed.
Put this vhd to vm or add to first choice (default) to the boot list to real PC whit EasyBCD or BCDedit, VisualBCD.

-bcdedit:
bcdedit /copy {originalguid} /d "Windows 7 vhd"

	bcdedit /set {newguid} device vhd=[C:]\win7.vhd

	bcdedit /set {newguid} osdevice vhd=[C:]\win7.vhd

	bcdedit /set {newguid} detecthal on


Boot from him and complete the installation of win7, then install what you wont have, driver or software whit activation and setting you prefer, windows don't lost this.
When you have installed all, reboot the os and then turn off.
Restart the pc to original os where you create the win7.vhd for making a backup.

6. Prepare the image for all pc/vm. Reboot to the win7.vhd and make a sysprep whit:

-start cmd, go to	 %SystemRoot%\System32\sysprep\

	-and give:		sysprep.exe /oobe /generalize /shutdown
or
-use Spat6, extract to desktop and start it without change any setting, clik to sysprep then Ok, wen is finish turn off the os.

The difference is this:
the 1st one when restarting to the new Pc ask for the new account and little setup (time, keyboard,windows activation),
the old account work olso bat is necessary make a new one. (symple resolve whit "control userpasswords2" when the os run)
the 2st metod reboot directly to original account, bat test you for know.
Together methods, is possible to made only 3 time

7. Give to every pc
When the vhd system is down restart the original OS and now is the moment to put (ctrl+c/ctrl+v) the win7.vhd to news vm/pc and
add the win7.vhd to bcd list whit EasyBCD or repeat the point.5

**don't go to manage DiskManagement inside the vhd os**
**all command/soft in this tutorial need administrator rights**

Sorry for my English

Alisseo
  • Nuno Brito likes this

#2 Wonko the Sane

Wonko the Sane

    The Finder

  • Advanced user
  • 13745 posts
  • Location:The Outside of the Asylum (gate is closed)
  •  
    Italy

Posted 04 March 2012 - 10:26 AM

At first sight, I do not understand first part of point 4 (setting the bootloader), I mean if you initialized partitioned the image under Windows 7 it will have ALREADY the 7 MBR code; as well since you format the partition under 7 it will have ALREADY the 7 PBR code. :dubbio:

:cheers:
Wonko

#3 alisseo

alisseo

    Newbie

  • Members
  • 20 posts
  •  
    Italy

Posted 04 March 2012 - 12:49 PM

What do you say? This is a step not necessary!?!? :whistling:

#4 Wonko the Sane

Wonko the Sane

    The Finder

  • Advanced user
  • 13745 posts
  • Location:The Outside of the Asylum (gate is closed)
  •  
    Italy

Posted 04 March 2012 - 02:24 PM

What do you say? This is a step not necessary!?!? :whistling:

Yes, it is not necessary.
When you partition a not initialized disk under any NT OS, the MBR code will be written to the MBR.
When you format a volume or partition under any NT OS, the PBR code will be written to the PBR or bootsector.
Since you initialize and partition and format under the same NT OS, there is no need to re-write these codes.
Running:

bootsect /nt60 H: /force /mbr

you simply overwrite *something* with *something else* which is absolutely identical.

:cheers:
Wonko

#5 alisseo

alisseo

    Newbie

  • Members
  • 20 posts
  •  
    Italy

Posted 06 March 2012 - 02:20 PM

yesterday i test it to 3 different computer and window7 worked fine bat some software lost the activation :dubbio: :frusty:
any idea?!

Edited by alisseo, 06 March 2012 - 02:22 PM.


#6 steve6375

steve6375

    Platinum Member

  • Developer
  • 6629 posts
  • Location:UK
  • Interests:computers, programming (masm,vb6,C,vbs), photography,TV,films,guitars
  •  
    United Kingdom

Posted 06 March 2012 - 07:12 PM

yesterday i test it to 3 different computer and window7 worked fine bat some software lost the activation :dubbio: :frusty:
any idea?!

What software? What version? How did you activate the software to begin with?

#7 alisseo

alisseo

    Newbie

  • Members
  • 20 posts
  •  
    Italy

Posted 06 March 2012 - 08:37 PM

What software? What version? How did you activate the software to begin with?



Some software need to are activated online with serial.
others with the first beginning with the original CD
all software is with securom

I'm thinking of exporting the registry keys but I can not find the activation value. ../public/style_emoticons/default/horse.gif
an exe run scan can help me?!I do not know what to do

#8 Husain-The New Rookie

Husain-The New Rookie

    Newbie

  • Members
  • 10 posts
  • Location:Burhanpur ,{M.P} India
  • Interests:Computer Related Everything
  •  
    India

Posted 14 May 2012 - 07:49 PM

u should use portable apps or creat ur own ones
that way it might work
u should use VMWARE ThinApp





Also tagged with one or more of these keywords: vhd, sysprep

0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users