In my previous post about getting Windows 7 onto the fantastic Dell Mini 9 I talked about solving things like the driver issues and antivirus. This time I’m going to cover how I installed Windows 7 onto the 8Gb SSD version of the Mini 9.
Interestingly, Windows 7 will actually install in about 8Gb. However, when I tried to run through my previously documented steps, it told me that it did not recommend installing to a disk of less that 8303Mb. The Dell had about 7.5Gb free for the install as I wanted to leave the Dell system partition alone. When I tried to install the process reset partway through and I could not stop it doing it.
So I had a think. My final solution, in a nutshell, is the following:
- Install to a VPC with a small disk but stop before the final step where it runs the OOBE (preparing to start for the first time…)
- Boot the VPC from another source and compress the contents of the disk.
- Create an image of the new disk and transfer that to the Dell.
- Complete the installation.
The good news is – it works!
So, let’s run through that again and put a bit more detail into it.
To do this yourself you’ll need the following:
- The drivers and software for the Dell Mini I listed in my previous post.
- The Windows 7 x86 install iso.
- The Windows 7 WAIK beta (to create WinPE media)
- Virtual PC 2007
- It’s also easier to have Windows 7 running on the PC you’re going to use to host the VPC for reason which will become clear soon.
Step 1: Create the VPC
I guess you don’t really need to limit the VPC to the same memory and disk as the Dell, but I did. Create a new VPC using the Vista template as the base. Set the memory to 1Gb and set the hard disk size to 8192Mb. While you’re at it, use the virtual disk wizard to create another VHD of the default size (16Gb, it’s more than enough) and call it something like ImageDisk. Don’t attach it to the virtual machine just yet.
Step 2: Install Windows 7 from the ISO
Attach your Windows 7 ISO to the virtual machine and boot from it. Choose your language as normal and select the 8Gb disk to install to. Don’t disappear and leave the installer to it, however – you need to pay attention.
The installer will copy files and uncompress them. It then does a couple more steps and does a reboot. At this point, because I’m paranoid, I shut down the VPC and copied the VHD file.
Let the VPC reboot. Again, pay attention. The installer carries on for a little while and then the system will restart. Again, shut the VPC down before it boots for a second time. Once again, I copied the VHD out of paranoia.
Step 3: Compress the disk contents
There’s an irony here – the installer has just merrily uncompressed all your files and now you want to shrink them back down again. Ah, well…
Boot the VPC from the installation CD. When you get the install screen up press Shift+f10 to open a command prompt.
Change to the root of the c: drive and type the following:
c:\windows\system32\compact.exe /c /s /i
This will run through and compress all the files except hidden and system files like the page file and hibernate file. It takes a while, but it will take a heck of a lot less time on your VPC than it would if we tried this on the Dell.
Once it’s finished, type:
c:\windows\system32\shutdown /s /t 0
or power off the VPC.
Step 4: Create a Win PE disk
I’m not going to run through the process of creating a WinPE disk. Install the WAIK and follow the instructions. You should end up with an ISO file that can be used to boot the VPC. Make sure you copy imagex.exe onto it!
Step 5: Image the VPC
We now need to create a .wim image of the installation we’ve partially completed. The easiest way to do that when using a VPC won Windows 7 is to mount a second VHD file and create the image on that. We can then attach the VHD to our Windows 7 host PC and copy off the image file.
First of all, we need to partition and format the VHD we create to store the image. On your Windows 7 host computer, start Computer Management as an Administrator (type ‘com’ into the start menu, right click the computer management icon, chose ‘run as administrator’).
Right-click on the Disk Management icon beneath Storage in the left hand pane and choose ‘Attach VHD’. Browse for your VHD file and click OK to mount it. You should see the new disk appear in the right hand panel.
We can do everything we need in Computer Management, but I find diskpart to be quicker. Open an administrative command prompt and type diskpart to fire it up.
We need to create a new partition. Computer Management helpfully tells us the number of our VHD so we can type that into diskpart. For example:
select disk 1
Then to create a partition:
create partition primary
And then, being eclectic, I use Computer Management to quick format it as NTFS because it’s easier to right-click the disk and choose ‘Format’!
Now we have a formatted partition, we can right-click the disk in computer management and detach the VHD. You can do that in Diskpart as well, I know…
Now edit your VPC configuration and add the second VHD. Boot the VPC from the WinPE ISO you created and you will end up with a command prompt.
The next bit is easy:
imagex /capture <drive letter of our system disk, hopefully c:> <drive letter of our big empty disk, possibly d:>\Mini9.wim “Mini9”
The sytem will chug for a while and you will be left with a shiny wim file on the second VHD. Mine was about 2.7Gb.
Step 6: Transfer the image onto the Dell
The easiest way to do this is to create a WinPE USB stick with your wim file on it as well. You’ll need to format your USB stick as NTFS and then xcopy the WinPE disk contents onto it. Make sure you use the /S (subdirectories), /H (copy hidden and system), /E (copy empty directories) and I usually tack on the /Y (don’t prompt) for a quiet life:
xcopy <source drive>\. <usb drive>\ /s /h /e /y
Then copy your .wim file on as well.
I usually use the Windows 7 install media to delete the original OS partition from the Dell, simply because the UI is nicer than using diskpart. You may differ. If you follow the WAIK instructions and use the diskpart ‘clean’ command you risk losing the Dell partition as well.
Armed with a nice empty Dell disk, boot from your USB WinPE disk.
First we need to partition the disk:
diskpart
list partition`
<you need to remember the number of the big partition! I’m going to assume it’s 1 for now>
select partition 1
active
format fs=ntfs
assign
exit
And now you should have a nice big empty partition which you need to work out what drive letter WinPE has assigned (it may or may not be c:)
To put your image onto the disk use the following:
imagex.exe /apply <usb disk path>\Mini9.wim 1 <dell disk>:\
Once again, site back and wait. When the imaging is completed you can shutdown the Dell, remove your USB stick and follow the same procedure as I talked about before to get your drivers installed.
Still to do…
I haven’t sorted out applications yet. There’s only about 1.6Gb free on the disk after this process is completed. I am looking at using the SD card for applications in the same way as I talked about in my post about Vista and junctions.