<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://weblogs.asp.net/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>Jon Galloway : Virtual PC</title><link>http://weblogs.asp.net/jgalloway/archive/tags/Virtual+PC/default.aspx</link><description>Tags: Virtual PC</description><dc:language>en</dc:language><generator>CommunityServer 2007 SP1 (Build: 20510.895)</generator><item><title>My Boot-to-VHD experiment: found some tips, like it, but still haven’t found VM nirvana</title><link>http://weblogs.asp.net/jgalloway/archive/2009/10/25/my-boot-to-vhd-experiment-found-some-tips-like-it-but-still-haven-t-found-vm-nirvana.aspx</link><pubDate>Sun, 25 Oct 2009 22:57:00 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:7239172</guid><dc:creator>Jon Galloway</dc:creator><slash:comments>4</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://weblogs.asp.net/jgalloway/rsscomments.aspx?PostID=7239172</wfw:commentRss><comments>http://weblogs.asp.net/jgalloway/archive/2009/10/25/my-boot-to-vhd-experiment-found-some-tips-like-it-but-still-haven-t-found-vm-nirvana.aspx#comments</comments><description>&lt;H2&gt;Summary&lt;/H2&gt;
&lt;UL&gt;
&lt;LI&gt;Windows 7’s Boot to VHD works as advertised – native speed, virtual machine flexibility. &lt;/LI&gt;
&lt;LI&gt;I came up with some tips and tricks which you might find useful&lt;/LI&gt;
&lt;LI&gt;Having to reboot without hibernate to switch to the VHD machine means it’s a lot less useful than I’d hoped. &lt;/LI&gt;&lt;/UL&gt;
&lt;H2&gt;Background&lt;/H2&gt;
&lt;P&gt;I’ve recently been running some early releases developer tools which came with the “install on VM’s if you don’t want your computer to catch fire” warning. That seemed like a good time to back off on my “VM’s are for sissies” stance and get my VHD on. After verifying that there wasn’t already &lt;A href="http://www.microsoft.com/Downloads/details.aspx?FamilyID=21eabb90-958f-4b64-b5f1-73d0a413c8ef&amp;amp;displaylang=en" mce_href="http://www.microsoft.com/Downloads/details.aspx?FamilyID=21eabb90-958f-4b64-b5f1-73d0a413c8ef&amp;amp;displaylang=en"&gt;a suitable VHD available for download&lt;/A&gt;, I decided to follow &lt;A href="http://www.hanselman.com/blog/StepByStepTurningAWindows7DVDOrISOIntoABootableVHDVirtualMachine.aspx" mce_href="http://www.hanselman.com/blog/StepByStepTurningAWindows7DVDOrISOIntoABootableVHDVirtualMachine.aspx"&gt;Scott Hanselman’s directions to set up a Boot To VHD instance&lt;/A&gt;.&lt;/P&gt;
&lt;P&gt;Here’s a very high level overview:&lt;/P&gt;
&lt;OL&gt;
&lt;LI&gt;Download the &lt;A href="http://code.msdn.microsoft.com/wim2vhd" mce_href="http://code.msdn.microsoft.com/wim2vhd"&gt;wim2vhd&lt;/A&gt; script from CodePlex &lt;/LI&gt;
&lt;LI&gt;Install the &lt;A href="http://www.microsoft.com/downloads/details.aspx?familyid=696DD665-9F76-4177-A811-39C26D3B3B34&amp;amp;displaylang=en" mce_href="http://www.microsoft.com/downloads/details.aspx?familyid=696DD665-9F76-4177-A811-39C26D3B3B34&amp;amp;displaylang=en"&gt;Windows 7 Automated Installation Kit (AIK)&lt;/A&gt; &lt;/LI&gt;
&lt;LI&gt;Copy ImageX.exe from the the AIK install into the same folder as the wim2vhd script &lt;/LI&gt;
&lt;LI&gt;Run the script &lt;/LI&gt;
&lt;LI&gt;Mount the VHD in the Windows 7 disk management screen&lt;/LI&gt;
&lt;LI&gt;Run some funky commands to make the disk bootable&lt;/LI&gt;&lt;/OL&gt;
&lt;P&gt;There's a little goofing around at the command line, but it's only a few minutes if you follow the directions. Then your new VHD shows up as an option on boot.&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;BUT WAIT! I have a few minor modifications. &lt;/STRONG&gt;Rather than write a complete walkthrough of the process – since Scott and others have done such a good job there – I’m just going to list some footnotes to the process. I’ve very roughly outlined the steps above; I recommend you read through the following list of tips, then go and follow &lt;A href="http://www.hanselman.com/blog/StepByStepTurningAWindows7DVDOrISOIntoABootableVHDVirtualMachine.aspx" mce_href="http://www.hanselman.com/blog/StepByStepTurningAWindows7DVDOrISOIntoABootableVHDVirtualMachine.aspx"&gt;Scott’s walkthrough&lt;/A&gt; and use any of the below tips you think are helpful.&lt;/P&gt;
&lt;H2&gt;Mod #1: Getting ImageX.exe without installing the AIK&lt;/H2&gt;
&lt;P&gt;There are copies of ImageX.exe floating around on the internets. I normally wouldn’t recommending using them, I only mention that because the AIK is 1.5 GB. If you’re one of those irrational people that thinks downloading 1.5GB to get a 471KB program, you could &lt;A href="http://www.google.com/search?hl=en&amp;amp;q=imagex.exe+download" mce_href="http://www.google.com/search?hl=en&amp;amp;q=imagex.exe+download"&gt;search around for “download imagex.exe”&lt;/A&gt; If you do that, the CRC for my my 32 bit ImageX.exe – version 6.2.7600.16385 - is 54 BF FA D5. Not recommended, but it is an option.&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;Note: Dear Microsoft folks that make gigantic SDK’s, please stop. Those might have made sense before the internet, but… c’mon now. Here’s how utilities should be done: &lt;A href="http://live.sysinternals.com/" mce_href="http://live.sysinternals.com/"&gt;live.sysinternals.com&lt;/A&gt;.&lt;/EM&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If you end up downloading the &lt;A href="http://www.microsoft.com/downloads/details.aspx?familyid=696DD665-9F76-4177-A811-39C26D3B3B34&amp;amp;displaylang=en" mce_href="http://www.microsoft.com/downloads/details.aspx?familyid=696DD665-9F76-4177-A811-39C26D3B3B34&amp;amp;displaylang=en"&gt;entire (1.5GB!!!) AIK ISO&lt;/A&gt; but hate installing a bunch of junk just to use one thing, you can open the ISO in 7-zip and find the find the ImageX.exe file, by looking for F1_imagex in Neutral.cab, like so:&lt;/P&gt;
&lt;P&gt;&lt;A title=ImageX href="http://www.flickr.com/photos/36836555@N00/4030819419/" mce_href="http://www.flickr.com/photos/36836555@N00/4030819419/"&gt;&lt;IMG border=0 alt=ImageX src="http://static.flickr.com/2780/4030819419_3f4a8ec36f.jpg" mce_src="http://static.flickr.com/2780/4030819419_3f4a8ec36f.jpg"&gt;&lt;/A&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Then you can just extract that file and rename it to ImageX.exe.&lt;/P&gt;
&lt;H2&gt;Mod #2: Changing the VHD size&lt;/H2&gt;
&lt;P&gt;The wim2vhd script defaults to a 40GB dynamic disk. Normally, I don’t really care much about the size of a dynamic disk, because the actual size of the VHD is only as big as the actual used space, and you can compact a disk to recover space as needed. However, when you mount a dynamic drive, the boot manager and host filesystem appear to reserve the maximum possible size of the of the disk – 40GB. In my case (on a laptop), that wasn’t going to work.&lt;/P&gt;
&lt;P&gt;It’s not just a convenience thing, either – if you have a VHD whose maximum size exceeds the physical disk space available, you’ll get a blue screen of death:&lt;/P&gt;
&lt;P&gt;&lt;A title="BSOD - Windows 7 Boot From VHD" href="http://www.flickr.com/photos/36836555@N00/4044515884/" mce_href="http://www.flickr.com/photos/36836555@N00/4044515884/"&gt;&lt;IMG border=0 alt="BSOD - Windows 7 Boot From VHD" src="http://static.flickr.com/2654/4044515884_203851e00d.jpg" mce_src="http://static.flickr.com/2654/4044515884_203851e00d.jpg"&gt;&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;(photo credit: &lt;/EM&gt;&lt;A href="http://www.bartlannoeye.be/blog/CommentView,guid,e1efe794-0d94-4109-be6e-ff81c7b62fca.aspx" mce_href="http://www.bartlannoeye.be/blog/CommentView,guid,e1efe794-0d94-4109-be6e-ff81c7b62fca.aspx"&gt;&lt;EM&gt;Bart Lannoeye, see his post about the BSOD issue&lt;/EM&gt;&lt;/A&gt;&lt;EM&gt;)&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;You can change the created VHD disk size using the /size parameter. For my Windows 7 + Visual Studio 2010 testing purposes, a 16GB disk seemed to work well. To do that, you’d call wim2vhd with this command:&lt;/P&gt;
&lt;BLOCKQUOTE&gt;
&lt;P&gt;cscript wim2vhd.wsf /wim:e:\sources\install.wim /sku:ultimate /size:16384&lt;/P&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;The size is calculated in MB, so you calculate it as 1024 * number of GB. A 20GB would use /size:20480&lt;/P&gt;
&lt;H2&gt;Mod #3: Rearming Windows to extend the evaluation time&lt;/H2&gt;
&lt;P&gt;If you’re using a virtual machine installation of Windows for temporary testing, you can use it without activation for 30 days. However, you can extend that evaluation period 3 times, giving you a total of 4 months, which is plenty of time for most evaluation purposes. It’s really simple:&lt;/P&gt;
&lt;BLOCKQUOTE&gt;
&lt;P&gt;Run "slmgr -rearm" from a command prompt with admin rights&lt;/P&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;This isn’t a hack – it uses a command that’s been shipped with Windows since Vista first came out. It’s not really news – &lt;A href="http://www.codinghorror.com/blog/archives/000778.html" mce_href="http://www.codinghorror.com/blog/archives/000778.html"&gt;Jeff Atwood wrote about it a while ago&lt;/A&gt;, and &lt;A href="http://blogs.zdnet.com/Bott/?p=224" mce_href="http://blogs.zdnet.com/Bott/?p=224"&gt;Ed Bott followed up with a cool tip on scripting that command to run every 30 days so you don’t forget&lt;/A&gt;. But it’s a really handy note, and it bears repeating.&lt;/P&gt;
&lt;P&gt;Note: Apparently you can &lt;A href="http://technet.microsoft.com/en-us/library/cc722350(WS.10,loband).aspx" mce_href="http://technet.microsoft.com/en-us/library/cc722350(WS.10,loband).aspx"&gt;use the SkipRearm registry setting&lt;/A&gt; to &lt;A href="http://www.windowssecrets.com/comp/070315/#story1" mce_href="http://www.windowssecrets.com/comp/070315/#story1"&gt;extend that even further&lt;/A&gt;, but I don’t know if that’s covered by the EULA. I haven’t had the need to use a VM that long, so I’ve never run into that.&lt;/P&gt;
&lt;H2&gt;Mod #4 (untested): EasyBDC&lt;/H2&gt;
&lt;P&gt;You can apparently skip the rigmarole with BCDEDIT by using EasyBCD, because&lt;A href="http://neosmart.net/forums/showthread.php?t=642" mce_href="http://neosmart.net/forums/showthread.php?t=642"&gt; beta builds of EasyBCD 2.0 support the Windows 7’s VHD features&lt;/A&gt;. &lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;&lt;EM&gt;Note: I haven’t done this. I’ve used previous releases of EasyBCD and haven’t had a problem, but I haven’t used EasyBCD 2.0 as it wasn’t out when I set up my VHD.&lt;/EM&gt;&lt;/STRONG&gt;&lt;/P&gt;
&lt;H2&gt;Mod #5 (untested): Disk2vhd&lt;/H2&gt;
&lt;P&gt;The SysInternals team recently released &lt;A href="http://technet.microsoft.com/en-us/sysinternals/ee656415.aspx" mce_href="http://technet.microsoft.com/en-us/sysinternals/ee656415.aspx"&gt;Disk2vhd&lt;/A&gt;, which can capture a disk image (while running) and create a VHD. I believe that in order to use the created VHD on the same machine it was created from, you’d first need to sysprep it, since otherwise you’re essentially trying to run two identical copies of the same operating system on the same computer, and you run into problems with drive paths. I haven’t tried this yet.&lt;/P&gt;
&lt;H2&gt;Gotcha #1: Go with Windows 7 Ultimate&lt;/H2&gt;
&lt;P&gt;&lt;A href="http://geekswithblogs.net/workdog/archive/2009/10/17/135524.aspx" mce_href="http://geekswithblogs.net/workdog/archive/2009/10/17/135524.aspx"&gt;Boot to VHD only works in Windows 7 Ultimate or Enterprise, not Windows 7 Professional&lt;/A&gt;. But you can’t use the Windows Activation re-arm trick we just talked about in Enterprise (since it uses a different licensing model). So I recommend that you go with Windows 7 Ultimate Edition.&lt;/P&gt;
&lt;H2&gt;Gotcha #2: Dual Boot means no hibernation&lt;/H2&gt;
&lt;P&gt;I use hibernation quite a bit, and only do a full reboot when I have to. So, for me, dual booting was inconvenient. It meant shutting everything down – including saving any tabs I happened to have open in IE8 (since tab saving in IE8 has been pretty unreliable for me) – in order to use the VHD partition, then shutting everything in the VHD partition down to switch back to the main one. That’s a lot of friction, and it ended up that I don’t use it as often as I thought I would. &lt;/P&gt;
&lt;P&gt;As I write this, I’m setting up a VHD which I’ll just run under Virtual PC, because I can start it up without shutting everything else down. I still feel like it’s a great feature, just one that I’ll use less often than I thought.&lt;/P&gt;
&lt;P&gt;Side note: Fast switching between boot instances would be a killer feature for Windows. I’d settle for multiple hibernation instances. I’ve read that it’s not enabled because of concerns over invalidating one hibernation instance while running the second machine instance, but I disagree – let me make that decision. At least give me a registry setting or something to enable it.&lt;/P&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=7239172" width="1" height="1"&gt;</description><category domain="http://weblogs.asp.net/jgalloway/archive/tags/Tips+_2F00_+Tricks/default.aspx">Tips / Tricks</category><category domain="http://weblogs.asp.net/jgalloway/archive/tags/Virtual+PC/default.aspx">Virtual PC</category><category domain="http://weblogs.asp.net/jgalloway/archive/tags/Windows+7/default.aspx">Windows 7</category></item><item><title>Running the Mono VMWare image in VirtualPC</title><link>http://weblogs.asp.net/jgalloway/archive/2008/03/30/running-the-mono-vmware-image-in-virtualpc.aspx</link><pubDate>Sun, 30 Mar 2008 09:22:42 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:6048126</guid><dc:creator>Jon Galloway</dc:creator><slash:comments>10</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://weblogs.asp.net/jgalloway/rsscomments.aspx?PostID=6048126</wfw:commentRss><comments>http://weblogs.asp.net/jgalloway/archive/2008/03/30/running-the-mono-vmware-image-in-virtualpc.aspx#comments</comments><description>&lt;p&gt;A lot of people love VMWare, but it bugs me. I think the main reason is that it installs with a bunch of Windows services that run automatically, every second my computer is running, whether or not I use VMWare. Since I don't use virtual machines every day, that's annoying. So, after running the free VMWare Player for a few times times, I banished it from my computer.&lt;/p&gt; &lt;p&gt;The Mono team publishes a VMWare image which makes it really easy to check out Mono on Linux without installing or building anything. If you're happy with &lt;a href="http://www.vmware.com/products/player/"&gt;VMWare, you can grab their free player&lt;/a&gt; and run the image. If, like me, you'd rather run this on Virtual PC, follow along and I'll show you how.&lt;/p&gt; &lt;p&gt;&lt;em&gt;If you don't use VirtualPC, or if you don't mind having several virtual machine hosts on your computer, this post obviously isn't for you. Thanks for stopping by, though!&lt;/em&gt;&lt;/p&gt; &lt;h3&gt;Grabbing the VMWare Image&lt;/h3&gt; &lt;p&gt;You can download the Mono VMWare image from the &lt;a href="http://www.go-mono.com/mono-downloads/download.html"&gt;Mono Downloads&lt;/a&gt; page. They offer both are http and torrent download options.&lt;/p&gt; &lt;p&gt;&lt;a href="http://www.go-mono.com/mono-downloads/download.html"&gt;&lt;img height="75" src="http://www.go-mono.com/mono-downloads/vmware_icon.jpg" width="75" border="0"&gt;&lt;img height="83" src="http://mono-project.com/skins/monoproject/images/mono-logo.png" width="69" border="0"&gt;&lt;/a&gt;&lt;/p&gt; &lt;h3&gt;Converting the Virtual Hard Disk image&lt;/h3&gt; &lt;p&gt;I use &lt;a href="http://vmtoolkit.com/files/folders/converters/entry8.aspx"&gt;Vmdk2Vhd from vmToolkit&lt;/a&gt; to convert the hard disk images. It's free, although there's an annoying registration step (which you can probably &lt;a href="http://www.bugmenot.com/view/vmtoolkit.com"&gt;bypass with BugMeNot&lt;/a&gt;). The interface is really simple - browse for the vmdk file, enter the destination filename, and click the "convert" button.&lt;/p&gt; &lt;p&gt;&lt;a title="Converting VMWare to VirtualPC with Vmdk2Vhd" href="http://www.flickr.com/photos/36836555@N00/2370721490/"&gt;&lt;img alt="Converting VMWare to VirtualPC with Vmdk2Vhd" src="http://static.flickr.com/3179/2370721490_c21fb9bf2b.jpg" border="0"&gt;&lt;/a&gt;&lt;/p&gt; &lt;h3&gt;Creating the new VirtualPC Machine&lt;/h3&gt; &lt;p&gt;Start up the VirtualPC console and go through the following steps:&lt;/p&gt; &lt;ol&gt; &lt;li&gt;Select "Create A Virtual Machine" &lt;/li&gt; &lt;li&gt;Set the Operating System to "Other"&lt;/li&gt; &lt;li&gt;You'll have to decide how much memory you can allocate to the virtual machine; on my workstation with 2GB RAM, I allocated 768MB RAM.&lt;/li&gt; &lt;li&gt;Select "Use an Existing Virtual Hard Disk" and browse to the location of the VHD file you created earlier using Vmdk2Vhd. I left "Use undo disks" unchecked.&lt;/li&gt; &lt;li&gt;Hit "Finish" and you should have a new virtual machine shown in your VirtualPC console.&lt;/li&gt;&lt;/ol&gt; &lt;p&gt;&lt;a title="Mono 1.9 in VirtualPC" href="http://www.flickr.com/photos/36836555@N00/2370032635/"&gt;&lt;img alt="Mono 1.9 in VirtualPC" src="http://static.flickr.com/3130/2370032635_319aabdc5f.jpg" border="0"&gt;&lt;/a&gt;&lt;/p&gt; &lt;h3&gt;Setting up the Video Driver&lt;/h3&gt; &lt;p&gt;VirtualPC and Linux have a long standing feud over video drivers. &lt;a href="http://weblogs.asp.net/jgalloway/archive/2005/02/24/379505.aspx"&gt;VirtualPC emulates an S3 Trio video card with 16 bit color depth, while the Linux X Server defaults to 24 bit color depth&lt;/a&gt; since &lt;a href="http://channel9.msdn.com/ShowPost.aspx?PostID=260762#260762"&gt;that's what a real S3 Trio supports&lt;/a&gt;. The result is that Linux video under VirtualPC is always a pain in the neck. So keep with me as we jump through a few hoops to get Linux to recognize VirtualPC's video card.&lt;/p&gt; &lt;p&gt;When you start the virtual machine we created earlier, hit the down arrow to select failsafe defaults and hit enter. &lt;/p&gt; &lt;p&gt;Note: &lt;a href="http://www.suseforums.net/index.php?s=&amp;amp;showtopic=41522&amp;amp;view=findpost&amp;amp;p=218192"&gt;Previous openSUSE images required me to also fix the mouse by adding "i8042.noloop" to the failsafe boot parameters&lt;/a&gt;, but this appears to have been fixed for the 1.9 image.&lt;/p&gt; &lt;p&gt;&lt;a title="Mono VMWare Image Failsafe Startup" href="http://www.flickr.com/photos/36836555@N00/2373505274/"&gt;&lt;img alt="Mono VMWare Image Failsafe Startup" src="http://static.flickr.com/2336/2373505274_4aca12e230.jpg" border="0"&gt;&lt;/a&gt;&lt;/p&gt; &lt;p&gt;After the boot process completes, you should be looking at a console window. You'll need to log in (root / mono) and enter "sax2 -m 0=fbdev" like so:&lt;/p&gt; &lt;p&gt;&lt;a title="VirtualPC Linux Video - SAX2" href="http://www.flickr.com/photos/36836555@N00/2373505048/"&gt;&lt;img alt="VirtualPC Linux Video - SAX2" src="http://static.flickr.com/3227/2373505048_8b178462ca.jpg" border="0"&gt;&lt;/a&gt;&lt;/p&gt; &lt;p&gt;SaX2 churns for a bit, then comes up in graphics mode. You can change the configuration, but I just clicked on OK.&lt;/p&gt; &lt;p&gt;&lt;a title="Linux-SAX2" href="http://www.flickr.com/photos/36836555@N00/2372709863/"&gt;&lt;img alt="Linux-SAX2" src="http://static.flickr.com/2293/2372709863_e2a7a719d1.jpg" border="0"&gt;&lt;/a&gt;&lt;/p&gt; &lt;p&gt;At this point, you'll need to reboot. You can do that in the VirtualPC menu (Action / Reset), or you can just type "shutdown -r 0" at the command prompt. When it comes back up, you can boot to Mono 1.9 / openSUSE 1.3 without using the Failsafe options.&lt;/p&gt; &lt;p&gt;&lt;a title="Mono 1.9 in VirtualPC" href="http://www.flickr.com/photos/36836555@N00/2372723829/"&gt;&lt;img alt="Mono 1.9 in VirtualPC" src="http://static.flickr.com/2074/2372723829_d0f019e5c6.jpg" border="0"&gt;&lt;/a&gt;&lt;/p&gt; &lt;p&gt;We've got one more thing to set up - the network connection is disabled by default. You can connect by clicking on the network icon in the lower right-hand corner, then on "Wired".&lt;/p&gt; &lt;p&gt;&lt;a title="openSUSE Network Connection" href="http://www.flickr.com/photos/36836555@N00/2373590934/"&gt;&lt;img alt="openSUSE Network Connection" src="http://static.flickr.com/3190/2373590934_293a220534.jpg" border="0"&gt;&lt;/a&gt;&lt;/p&gt; &lt;p&gt;Stay tuned - in the next post, we'll make use of this image to take a look at Moonlight, the open source implementation of Silverlight on Linux.&lt;/p&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=6048126" width="1" height="1"&gt;</description><category domain="http://weblogs.asp.net/jgalloway/archive/tags/Virtual+PC/default.aspx">Virtual PC</category><category domain="http://weblogs.asp.net/jgalloway/archive/tags/Mono/default.aspx">Mono</category></item><item><title>We should be virtualizing Applications, not Machines</title><link>http://weblogs.asp.net/jgalloway/archive/2007/09/04/we-should-be-virtualizing-applications-not-machines.aspx</link><pubDate>Tue, 04 Sep 2007 20:49:00 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:3734849</guid><dc:creator>Jon Galloway</dc:creator><slash:comments>23</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://weblogs.asp.net/jgalloway/rsscomments.aspx?PostID=3734849</wfw:commentRss><comments>http://weblogs.asp.net/jgalloway/archive/2007/09/04/we-should-be-virtualizing-applications-not-machines.aspx#comments</comments><description>&lt;p&gt;One of the benefits of my new job at &lt;a href="http://www.vertigo.com" mce_href="http://www.vertigo.com"&gt;Vertigo Software&lt;/a&gt; is that I have more frequent opportunities to talk with my co-worker, &lt;a href="http://www.codinghorror.com/blog" mce_href="http://www.codinghorror.com/blog"&gt;Jeff Atwood&lt;/a&gt;. If everything goes right, we argue... because if we agree, neither of us is going to learn anything. Recently, we argued about virtual machines. I think &lt;b&gt;machine virtualization is hugely oversold&lt;/b&gt;. We let the technical elegance (gee whiz, a program that lets me pretend to run another computer as another program!) distract us from the fact that virtual machines are a sleazy, inelegant&amp;nbsp;hack.&lt;/p&gt; &lt;h3&gt;I was a teenage VM junkie&lt;/h3&gt; &lt;p&gt;I'm saying this as&amp;nbsp;&lt;a href="http://weblogs.asp.net/jgalloway/archive/tags/Virtual+PC/default.aspx" mce_href="http://weblogs.asp.net/jgalloway/archive/tags/Virtual+PC/default.aspx"&gt;someone who used to be a big VM advocate&lt;/a&gt;. A few years ago, I noticed that it took new developers as much as a week to get set up to develop on some of&amp;nbsp;the company's more complex systems, so I worked with application leads to set up Virtual PC images which had everything pre-installed. Sure enough, I had new developers working against complex DCOM / .NET / DB2 / "Classic" ASP environments with tons of dependencies in the time it took to copy the VPC image off a DVD-ROM.&lt;/p&gt; &lt;p&gt;One problem: &lt;b&gt;it was a lousy developer experience&lt;/b&gt;. Most of the developers kept quiet, but a new developer let me have it: "This stinks! It's totally slow! You really expect me to show up to work every day and work eight hours on a virtual machine?" He was right, it did stink. Even with extra memory and a beefy machine, virtual machines are fine for occasional use, but they're not workable for full time development. For instance, I frequently had to shut down all other applications (Outlook, browsers, etc.) so that the virtual machine would be responsive enough that I could get work done.&lt;/p&gt; &lt;p&gt;Let's admit that &lt;b&gt;the virtual machine emperor has no clothes on&lt;/b&gt;. Virtualizing machines&amp;nbsp;is a&amp;nbsp;neat parlor trick. It's&amp;nbsp;tolerable for a &lt;a href="http://flaviostechnotalk.com/wordpress/index.php/2005/06/01/virtualization-and-emulation/" mce_href="http://flaviostechnotalk.com/wordpress/index.php/2005/06/01/virtualization-and-emulation/"&gt;few short-term uses&lt;/a&gt; (demonstrations, training, playing with alpha software, or testing different operating systems) but it's not a viable solution for real development.&lt;/p&gt; &lt;h3&gt;Let's take fast computers and make them not&lt;/h3&gt; &lt;h4&gt;Resources&lt;/h4&gt; &lt;p&gt;The problem is that&amp;nbsp;virtualizing&amp;nbsp;a computer in software is&amp;nbsp;just incredibly inefficient. They waste system resources like crazy&amp;nbsp;-&amp;nbsp;they're so&amp;nbsp;inefficient that they make today's multi-core machines packed full of RAM crawl. Their blessing - they let us simulate an entire machine in software - is also their curse. Simulating an entire machine in software means they're running a separate network stack, drawing video on a pretend video card, managing pretend system resources on a pretend motherboard, playing sound on pretend soundcards, etc. Even if you &lt;a href="http://www.codinghorror.com/blog/archives/000639.html" mce_href="http://www.codinghorror.com/blog/archives/000639.html"&gt;spend some&lt;/a&gt; &lt;a href="http://blogs.ipona.com/dan/archive/2007/08/22/8419.aspx" mce_href="http://blogs.ipona.com/dan/archive/2007/08/22/8419.aspx"&gt;time&lt;/a&gt; and / or &lt;a href="http://www.invirtus.com/" mce_href="http://www.invirtus.com/"&gt;money optimizing your virtual machine image&lt;/a&gt;, virtual machine images are still pigs compared to working on real machines.&lt;/p&gt; &lt;p&gt;&lt;i&gt;Note: Machine Virtualization is a complex subject, and I'm glossing over things a little here. Virtual PC and VMWare both use &lt;/i&gt;&lt;a href="http://en.wikipedia.org/wiki/Native_virtualization" mce_href="http://en.wikipedia.org/wiki/Native_virtualization"&gt;&lt;i&gt;native virtualization&lt;/i&gt;&lt;/a&gt;&lt;i&gt; combined with virtual machine additions to leverage physical hardware as much as possible, trapping and emulating only what's necessary. So, VM's don't emulate all hardware resources, but the fact that they need to essentially filter all CPU instructions isn't a very efficient use of system resources.&lt;/i&gt;&lt;/p&gt; &lt;h4&gt;Size&lt;/h4&gt; &lt;p&gt;Then there's the problem of space. Even an optimized image with a significant amount of software - say, a development environment and a database - runs a few GB.&amp;nbsp;While we can make space for them on today's&amp;nbsp;large drives the problem there is in transportation and backup. Multi-GB virtual drive files are a pain to move around. And even if you do optimize them, you're keeping multiple copies of things like "C:\WINDOWS\Driver Cache\", "C:\WINDOWS\Microsoft.NET\", etc.&lt;/p&gt; &lt;h4&gt;Updates and virus scanning&lt;/h4&gt; &lt;p&gt;Many people mistakenly believe that they don't need to worry about safety (patches, automatic updates, virus scanners) on virtual machines since the host machine is taking care of those things. Not so. Each virtual machine with internet or network access is more than capable of becoming infected or compromised in the browser over port 80, or of spreading viruses which exploit network issues (e.g. SQL Slammer on port 1433). A virtual machine needs to be patched and protected, but since it's not on regularly it's not as likely to have been Auto-Updated. So, if you're planning to work on a virtual machine, you should plan to spend twice as much time and effort on operating system maintenance.&lt;/p&gt; &lt;h4&gt;Host machine services&lt;/h4&gt; &lt;p&gt;A&amp;nbsp;personal pet peeve is the vampire services that VMWare runs. Yes, their &lt;a href="http://www.vmware.com/products/player/" mce_href="http://www.vmware.com/products/player/"&gt;VMWare Player&lt;/a&gt; is free, but just by installing it you install a bunch of Windows Services which autostart with your computer and run until you uninstall the VMWare Player, even if you never open a single VM.&lt;/p&gt; &lt;h4&gt;Isolating your work environment makes it harder to get work done&lt;/h4&gt; &lt;p&gt;By its very nature, virtualizing an environment means that your files run on what might as well be a separate computer. That means that it's difficult to take advantage of programs on the base machine. Yes, you can share clipboards and map drives to a virtual machine (while it's running), but that's about it. If, for instance, you run Outlook on the base machine and Visual Studio in a virtual machine - you end up jumping through some hoops to send the output of a program via e-mail, or view tabular data from SSMS in Excel, or add an emailed&amp;nbsp;logo to your web application. These are all simple enough to get around, but add significant friction to your daily work.&lt;/p&gt; &lt;h3&gt;Why are we virtualizing entire machines again? Isn't there a better solution?&lt;/h3&gt; &lt;p&gt;I sure think so, or this post would just be a useless rant. I try to avoid those.&lt;/p&gt; &lt;h4&gt;How about running unvirtualized software?&lt;/h4&gt; &lt;p&gt;For instance, I've been developing on Visual Studio 2008 since Beta 1, and I've got it installed side by side with Visual Studio 2005. No problems. I recently upgraded to Visual Studio 2008 Beta&amp;nbsp;2 with no problems. Truth be told, this wasn't my gutsy idea - &lt;a href="http://blog.wekeroad.com/" mce_href="http://blog.wekeroad.com/"&gt;Rob Conery&lt;/a&gt; did it, and (as with a few other things) I followed him over the cliff -&amp;nbsp;fortunately in this case it was&amp;nbsp;not a&amp;nbsp;real actual&amp;nbsp;cliff. As software consumers, we should be able to expect software that we can trust enough, you know, actually install and use. I understand that beta software is beta software, and I'm a fan of releasing software early and often, but I should be able to expect that beta software won't trash my machine. As a side note here, I continue to be really impressed by the ever-increasing quality&amp;nbsp;of Visual Studio releases.&lt;/p&gt; &lt;p&gt;The best way for developers to better the situation is to write software which is&amp;nbsp;well compartmentalized, so we don't need to put it in an artificial container. This is commonly done by&amp;nbsp;making good use&amp;nbsp;of an &lt;a href="http://en.wikipedia.org/wiki/Comparison_of_Application_Virtual_Machines" mce_href="http://en.wikipedia.org/wiki/Comparison_of_Application_Virtual_Machines"&gt;application virtual machine&lt;/a&gt; (like the common language runtime, the Java language runtime, etc.). These technologies tend to steer you towards writing well isolated software, but for the sake of legacy integration they don't prevent you from going back to old, bad habits like writing to the Windows registry, modifying or installing shared resources, installing COM objects, or storing files and settings in the wrong place. Software written to run on a software virtual machine isn't guaranteed to&amp;nbsp;be isolated, but it's generally more likely to play nice.&lt;/p&gt; &lt;p&gt;Folks talk about running under a non-administrator account, but I'm not completely convinced. While that solution does prompt you before modifying your system, it hasn't really been that helpful in my experience. Too much software just stops working under a lower privileged account. At that point you're back to the choice - install&amp;nbsp;the software as&amp;nbsp;an administrator or don't install it, but once you install as administrator you've pretty much said "Sure, do whatever you want to my system, please don't trash it." Hopefully software and users will both move together into an "administrator not required" world, but it's difficult as a software user to make that move before software vendors have fully embraced it.&lt;/p&gt; &lt;h4&gt;Those other applications that won't play nice.&lt;/h4&gt; &lt;p&gt;So what do you do with applications that insist on modifying your system? Short of the Virtual Machine Nuclear Option, is there a way to handle software which, by design, makes fundamental changes to your system?&lt;/p&gt; &lt;p&gt;&lt;i&gt;Yes, I'm thinking of you, Internet Explorer, and I'm shaking my head. You don't play nice - IE7 won't share a computer with IE6 without a fight. I know you've got a lot of excuses, and I still don't buy them (check out&amp;nbsp;this &lt;/i&gt;&lt;a href="mms://wmcomwm.fplive.net/wmcom/mssoma/NGW048.wmv" mce_href="mms://wmcomwm.fplive.net/wmcom/mssoma/NGW048.wmv"&gt;&lt;i&gt;video&lt;/i&gt;&lt;/a&gt;&lt;i&gt;&amp;nbsp;at 1:05:30, that's me bugging the IE team about this at MIX06). To my way of thinking, IE is a browser, and if the .NET Framework folks have figured out how to run entire platforms side by side, you can manage to do that with an application which renders web pages. I felt strongly enough about this to put a significant amount of time (okay, a ridiculous amount of time)&amp;nbsp;into &lt;/i&gt;&lt;a href="http://www.google.com/search?hl=en&amp;amp;q=+site%3Aweblogs.asp.net%2Fjgalloway+ie7+standalone" mce_href="http://www.google.com/search?hl=en&amp;amp;q=+site%3Aweblogs.asp.net%2Fjgalloway+ie7+standalone"&gt;&lt;i&gt;developing and supporting workarounds&lt;/i&gt;&lt;/a&gt;&lt;i&gt; - not really for my use, but for thousands of web developers (judging from the downloads and hits). I thought&amp;nbsp;the IE team's&amp;nbsp;suggestion to go and use VPC was... well, pretty unhelpful, especially considering that the need to run IE6 and IE7 on the same machine was to try to write forward compatible HTML which still worked with IE6's messed up rendering. I'll move off the IE example before this turns more rantlike...&lt;/i&gt;&lt;/p&gt; &lt;p&gt;The point there, I guess, is that &lt;b&gt;virtual machines are sleazy hacks which users can decide to use, but software vendors should be ashamed to require&lt;/b&gt;. So... no matter how much we wish we could install all our applications on one machine, some applications won't play nice. As it is now, the only out we've got is to virtualize the entire machine. Is there a way to &lt;a href="http://en.wikipedia.org/wiki/Sandbox_%28computer_security%29" mce_href="http://en.wikipedia.org/wiki/Sandbox_%28computer_security%29"&gt;sandbox applications&lt;/a&gt; which won't &lt;a href="http://en.wikipedia.org/wiki/Sandbox_%28software_development%29" mce_href="http://en.wikipedia.org/wiki/Sandbox_%28software_development%29"&gt;sandbox themselves&lt;/a&gt;?&lt;/p&gt; &lt;h3&gt;Waiting for an Application Virtualization host&lt;/h3&gt; &lt;p&gt;Yes - there's a better solution which has gone almost completely unnoticed: application virtualization. I've been reading about application virtualization technology for a while, but have been frustrated with how long it's taken to actually see it in practice. The idea is to host a program in a sandbox that virtualizes just the things we don't want modified - for instance, registry and DLL's.&lt;/p&gt; &lt;p&gt;&lt;a href="http://en.wikipedia.org/wiki/GreenBorder" mce_href="http://en.wikipedia.org/wiki/GreenBorder"&gt;GreenBorder&lt;/a&gt;&amp;nbsp;and &lt;a href="http://www.microsoft.com/systemcenter/softgrid/default.mspx" mce_href="http://www.microsoft.com/systemcenter/softgrid/default.mspx"&gt;SoftGrid&lt;/a&gt; are two commercial solutions to this problem. The good news and bad news about both of these programs is that they've been bought in the past year - GreenBorder was bought by Google, and SoftGrid was bought by Microsoft. The good news part of that is that the technology is backed by major, established companies; the bad news is that the technology may be folded into larger product offerings (Hello, FolderShare? You guys got eaten by SkyDrive, but the best features haven't made it over yet... And Groove, sure miss the file preview in Groove 2007...).&lt;/p&gt; &lt;h3&gt;SoftGrid&lt;/h3&gt; &lt;p&gt;Here's a diagram from &lt;a href="http://www.microsoft.com/technet/technetmag/issues/2007/08/SoftGrid/default.aspx" mce_href="http://www.microsoft.com/technet/technetmag/issues/2007/08/SoftGrid/default.aspx"&gt;Microsoft's SoftGrid documentation&lt;/a&gt;:&lt;/p&gt; &lt;p&gt;&lt;img src="http://www.microsoft.com/technet/technetmag/issues/2007/08/SoftGrid/fig03.gif" mce_src="http://www.microsoft.com/technet/technetmag/issues/2007/08/SoftGrid/fig03.gif"&gt;&lt;/p&gt; &lt;p&gt;Pretty cool, that's exactly what I'd like to be able to do. The problem (at least as I see it) is that this cool SystemGuard stuff is wrapped up inside a bigger Application Streaming system. The benefit is that existing&amp;nbsp;applications can be wrapped up into packages which deploy kind of like ClickOnce applications - they're sandboxed, automatically updated, and centrally managed:&lt;/p&gt; &lt;p&gt;&lt;a href="http://www.flickr.com/photos/36836555@N00/1323170455/" title="SoftGrid" mce_href="http://www.flickr.com/photos/36836555@N00/1323170455/"&gt;&lt;img src="http://static.flickr.com/1176/1323170455_273f36670f.jpg" alt="SoftGrid" mce_src="http://static.flickr.com/1176/1323170455_273f36670f.jpg" border="0"&gt;&lt;/a&gt;&amp;nbsp;&lt;/p&gt; &lt;p&gt;That's neat if you're looking at this as a complement to SMS from an enterprise IT point of view, but it's not helpful for individuals who just want to be able to install software on their local machine. I'm especially un-excited about application streaming after having to use &lt;a href="http://en.wikipedia.org/wiki/Zenworks" mce_href="http://en.wikipedia.org/wiki/Zenworks"&gt;Novell ZENWorks&lt;/a&gt; at a former job at a financial company. Virtualized Microsoft Office must sound great to IT folks, but it wasn't very productive for end users.&lt;/p&gt; &lt;h3&gt;GreenBorder&lt;/h3&gt; &lt;p&gt;&lt;a href="http://www.greenborder.com/" mce_href="http://www.greenborder.com/"&gt;GreenBorder&lt;/a&gt; takes a smaller scope - it just sandboxes browsers, making the border of the "safe" browser green (get it?).&lt;/p&gt; &lt;p&gt;&lt;img src="http://i.n.com.com/i/ne/p/2006/GreenBorderPro2.jpg" mce_src="http://i.n.com.com/i/ne/p/2006/GreenBorderPro2.jpg"&gt; &lt;/p&gt; &lt;p&gt;That's a cool idea, but it's&amp;nbsp;completely web-centric. I'd expect Google's use of it to stay that way. So, it's nice for safe browsing, but not helpful if you want to sandbox an arbitrary application on your computer.&lt;/p&gt; &lt;h3&gt;&lt;b&gt;Sandboxie&lt;/b&gt;&lt;/h3&gt; &lt;p&gt;&lt;b&gt;UPDATE&lt;/b&gt;: I just remembered another application virtualization program I've been meaning to look into: &lt;a href="http://www.sandboxie.com/" mce_href="http://www.sandboxie.com/"&gt;Sandboxie&lt;/a&gt;. The unregistered version of Sandboxie is free, and registration is only $25. From their site:&lt;/p&gt; &lt;blockquote&gt; &lt;p&gt;&lt;b&gt;Sandboxie&lt;/b&gt; changes the rules such that &lt;i&gt;write&lt;/i&gt; operations do not make it back to your hard disk.  &lt;/p&gt;&lt;p&gt;&lt;img src="http://www.sandboxie.com/img/FrontPageSystem2.png" alt="" mce_src="http://www.sandboxie.com/img/FrontPageSystem2.png"&gt; &lt;/p&gt;&lt;p&gt;The illustration shows the key component of &lt;b&gt;Sandboxie&lt;/b&gt;: a transient storage area, or &lt;b&gt;sandbox&lt;/b&gt;. Data flows in both directions between programs and the sandbox. During &lt;i&gt;read&lt;/i&gt; operations, data may flow from the hard disk into the sandbox. &lt;u&gt;But data never flows back from the sandbox into the hard disk. &lt;/u&gt; &lt;/p&gt;&lt;p&gt;If you run Freecell inside the &lt;b&gt;Sandboxie&lt;/b&gt; environment, &lt;b&gt;Sandboxie&lt;/b&gt; &lt;i&gt;reads&lt;/i&gt; the statistics data from the hard disk into the sandbox, to satisfy the read requested by Freecell. When the game later &lt;i&gt;writes&lt;/i&gt; the statistics, &lt;b&gt;Sandboxie&lt;/b&gt; intercepts this operation and directs the data to the sandbox.  &lt;/p&gt;&lt;p&gt;If you then run Freecell without the aid of &lt;b&gt;Sandboxie&lt;/b&gt;, the &lt;i&gt;read&lt;/i&gt; operation would bypass the sandbox altogether, and the statistics would be retrieved from the hard disk.  &lt;/p&gt;&lt;p&gt;The transient nature of the sandbox makes it is easy to get rid of everything in it. If you were to throw away the sandbox, by deleting everything in it, the &lt;i&gt;sandboxed&lt;/i&gt; statistics would be gone for good, as if they had never been there in the first place.&amp;nbsp;&lt;/p&gt;&lt;/blockquote&gt; &lt;p&gt;I'll have to give that a try the next time I want to test something... but since I'm completely sure it'll work well, should I test it in a Virtual Machine? Hmm... &lt;/p&gt;&lt;p&gt;&lt;b&gt;MORE UPDATES&lt;/b&gt;:  &lt;/p&gt;&lt;p&gt;&lt;a href="http://www.xenocode.com/" mce_href="http://www.xenocode.com/"&gt;&lt;b&gt;Xenocode&lt;/b&gt;&lt;/a&gt; - I got an e-mail from Kenji Obata at Xenocode, letting me know that Xenocode virtualizes applications inside of standalone EXE's. It looks like a well thought out solution, but &lt;a href="http://www.xenocode.com/Products/Studio/Pricing.aspx" mce_href="http://www.xenocode.com/Products/Studio/Pricing.aspx"&gt;a single developer license costs $499&lt;/a&gt;. This is worth a look for professional or enterprise application virtualization without buying into the whole SoftGrid style application streaming deployment thing. &lt;/p&gt;&lt;p&gt;In the funny timing department, my copy of &lt;a href="http://www.redmondmag.com" mce_href="http://www.redmondmag.com"&gt;Redmond Magazine&lt;/a&gt; just arrived today. The September issue has an overview of application virtualization, and compares &lt;a href="http://www.getsvs.com" mce_href="http://www.getsvs.com"&gt;&lt;b&gt;Altiris Software Virtualization Solution (SVS)&lt;/b&gt;&lt;/a&gt; with &lt;a href="http://www.landesk.com" mce_href="http://www.landesk.com"&gt;&lt;b&gt;LANDesk Application Virtualization&lt;/b&gt;&lt;/a&gt;. &lt;/p&gt;&lt;p&gt;Let me know if there are more Application Virtualization systems I've missed, or if you've used any of these please comment with your experiences.&lt;/p&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=3734849" width="1" height="1"&gt;</description><category domain="http://weblogs.asp.net/jgalloway/archive/tags/Software+Development/default.aspx">Software Development</category><category domain="http://weblogs.asp.net/jgalloway/archive/tags/Virtual+PC/default.aspx">Virtual PC</category><category domain="http://weblogs.asp.net/jgalloway/archive/tags/General+Software+Development/default.aspx">General Software Development</category></item><item><title>Can Operating Systems tell if they're running in a Virtual Machine?</title><link>http://weblogs.asp.net/jgalloway/archive/2006/10/27/Can-Operating-Systems-tell-if-they_2700_re-running-in-a-Virtual-Machine_3F00_.aspx</link><pubDate>Sat, 28 Oct 2006 06:06:00 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:744714</guid><dc:creator>Jon Galloway</dc:creator><slash:comments>31</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://weblogs.asp.net/jgalloway/rsscomments.aspx?PostID=744714</wfw:commentRss><comments>http://weblogs.asp.net/jgalloway/archive/2006/10/27/Can-Operating-Systems-tell-if-they_2700_re-running-in-a-Virtual-Machine_3F00_.aspx#comments</comments><description>&lt;p&gt;&lt;em&gt;Or,&amp;nbsp;do androids know they&amp;#39;re dreaming of electric sheep...&lt;/em&gt;&lt;/p&gt; &lt;p&gt;&lt;img style="margin: 0px 0px 0px 15px" src="http://static.flickr.com/105/273848409_df67fe97ff_m.jpg" alt="" align="right" /&gt; There was &lt;a href="http://www.virtualization.info/2006/10/microsoft-denies-some-vista-editions.html"&gt;some recent news on Windows Vista EULA restrictions relating to Virtual Machines&lt;/a&gt;. &lt;strong&gt;Vista Home Editions aren&amp;#39;t&amp;nbsp;allowed to be run inside a Virtual Machine, and Vista Ultimate in a VM will restrict access to applications which use DRM.&lt;/strong&gt; We&amp;#39;re still waiting for clarification from Microsoft, but &lt;a href="http://www.windows-now.com/blogs/robert/archive/2006/10/15/Official-Clarification-on-Licensing-Coming-Shortly.aspx"&gt;it seems like the popular interpretations are basically right&lt;/a&gt;.&lt;/p&gt; &lt;p&gt;This raises the question - is this a EULA restriction, or is it going to be enforced. Can it be enforced? Can an operating system tell if it&amp;#39;s running in a Virtual Machine?&lt;/p&gt; &lt;p&gt;That&amp;#39;s really two questions: &lt;/p&gt; &lt;ol&gt; &lt;li&gt;&lt;strong&gt;Can Operating Systems currently detect if they&amp;#39;re running in a VM? &lt;/strong&gt; &lt;/li&gt;&lt;li&gt;&lt;strong&gt;Will&amp;nbsp;Operating Systems always be able to detect if they&amp;#39;re running in a VM?&lt;/strong&gt;&lt;/li&gt;&lt;/ol&gt; &lt;p&gt;Well, I only know what I read. Let me know if you disagree...&lt;/p&gt; &lt;h3&gt;Can Operating Systems currently detect if they&amp;#39;re running in a VM?&lt;/h3&gt; &lt;p&gt;&lt;strong&gt;Yes, they can.&lt;/strong&gt; Right now they do it&amp;nbsp;through a couple of techniques&amp;nbsp;- &lt;a href="http://www.google.com/search?q=detect+running+in+virtualpc"&gt;direct hardware fingerprinting&lt;/a&gt; and inferred hardware fingerprinting.&lt;/p&gt; &lt;p&gt;&lt;strong&gt;Direct hardware fingerprinting&lt;/strong&gt; is pretty straightforward. Virtual Machines have predictable hardware profiles, so you can just query for &amp;quot;virtual hardware&amp;quot; that&amp;#39;s only available in VM&amp;#39;s and can&amp;#39;t easily be changed. &lt;a href="http://blogs.msdn.com/virtual_pc_guy/archive/2005/10/27/484479.aspx"&gt;The Virtual PC Guy&lt;/a&gt; describes this approach &lt;a href="http://blogs.msdn.com/virtual_pc_guy/archive/2005/10/27/484479.aspx"&gt;here&lt;/a&gt;:&lt;/p&gt; &lt;blockquote&gt; &lt;p&gt;The easiest way to detect that you are inside of a virtual machine is by using &amp;#39;hardware fingerprinting&amp;#39; - where you look for hardware that is always present inside of a given virtual machine.&amp;nbsp; In the case of Microsoft virtual machines - a clear indicator is if the motherboard is made by Microsoft... &lt;em&gt;[WMI&amp;nbsp;Script to check the motherboard vendor]&lt;/em&gt;&lt;br /&gt;If the motherboard is made by &amp;quot;Microsoft Corporation&amp;quot; then you are inside of one of our virtual machines.&lt;/p&gt;&lt;/blockquote&gt; &lt;p&gt;The &lt;strong&gt;inferred hardware fingerprinting approach&lt;/strong&gt; is a bit more dodgy. It&amp;nbsp;works by&amp;nbsp;making direct machine level calls to the virtualized CPU that will reveal if the CPU is real or virtual. Some of these call instructions that the VMM&amp;#39;s don&amp;#39;t currently support. Others make system calls that will only succeed on specific virtual hardware, usually because of special machine calls the VM&amp;#39;s implement to allow communication with the host OS and optimize use of host OS resources (e.g. the&amp;nbsp;Virtual Machine Additions for Virtual PC / Virtual Server&amp;nbsp;, or VMWare&amp;#39;s VMware Command Line Tools). This kind of stuff is pretty slick, but it makes &amp;quot;undocumented system calls&amp;quot; look boring.&lt;/p&gt; &lt;p&gt;Here are some examples of indirect hardware fingerprinting:&lt;/p&gt; &lt;ul&gt; &lt;li&gt;A &lt;a href="http://www.codeproject.com/system/VmDetect.asp"&gt;program on CodeProject&lt;/a&gt; that can detect if it is running in either VPC or VMWare.  &lt;/li&gt;&lt;li&gt;More information on &lt;a href="http://www.virtualization.info/2004/03/how-application-can-detect-if-is_17.html"&gt;detecting the VMWare host through the presence of special IO ports&lt;/a&gt; implemented as system calls  &lt;/li&gt;&lt;li&gt;&lt;a href="http://invisiblethings.org/papers/redpill.html"&gt;The Red Pill approach&lt;/a&gt;, which exploits the fact that the interrupt descriptor table registor (IDTR) is relocated by VMM&amp;#39;s. It writes to the IDTR via an SIDT instruction, the reads from the ITDR. If the values don&amp;#39;t match, the code is executing in a VM.&lt;/li&gt;&lt;/ul&gt; &lt;p&gt;Of course, this approach is subject to the whims of each VMM release, and &lt;a href="http://www.codeproject.com/system/VmDetect.asp?df=100&amp;amp;forumid=162437&amp;amp;select=1091866#xx1091866xx"&gt;it may vary from host OS to host OS&lt;/a&gt;. &lt;/p&gt; &lt;p&gt;These two approaches remind me of &lt;a href="http://blogs.msdn.com/ie/archive/2005/10/12/480242.aspx"&gt;the two ways to target CSS to different browsers&lt;/a&gt; - &lt;a href="http://msdn.microsoft.com/library/default.asp?url=/workshop/author/dhtml/overview/ccomment_ovw.asp"&gt;ask them nicely&lt;/a&gt;, or&amp;nbsp;&lt;a href="http://centricle.com/ref/css/filters/"&gt;beat it out of them&lt;/a&gt;.&lt;/p&gt; &lt;h3&gt;Will Operating Systems always be able to detect if they&amp;#39;re running in a VM?&lt;/h3&gt; &lt;p&gt;&lt;img src="http://static.flickr.com/12/97012281_a3f9a8a694_m.jpg" alt="" align="right" /&gt; Of course, that&amp;#39;s not a question I can answer with certainty until I can get my hands on a &lt;a href="http://en.wikipedia.org/wiki/Flux_capacitor"&gt;flux capacitor and 1.21 gigawatts&lt;/a&gt;. That won&amp;#39;t keep me from speculating, though...&lt;/p&gt; &lt;p&gt;Let&amp;#39;s step back a second and think about whether or not we want Operating Systems to know if they&amp;#39;re running in a virtual environment. In the context of the recent Vista EULA flap, we might want to say no - the EULA restriction is stupid, and it&amp;#39;s a good thing that they can&amp;#39;t enforce it.&lt;/p&gt; &lt;p&gt;But let&amp;#39;s talk about &lt;a href="http://theinvisiblethings.blogspot.com/2006/06/introducing-blue-pill.html"&gt;The Blue Pill&lt;/a&gt;. It&amp;#39;s a theoretical malware application of VM technology&amp;nbsp;in which a rootkit&amp;nbsp;consumes the host operating system and runs as a hypervisor (a hardware virtual machine manager). Once it&amp;#39;s done that, it can do whatever it wants without the operating system knowing it&amp;#39;s been compromised:&lt;/p&gt; &lt;blockquote&gt; &lt;p&gt;&lt;strong&gt;The idea behind Blue Pill is simple: your operating system swallows the Blue Pill and it awakes inside the Matrix controlled by the ultra thin Blue Pill hypervisor. This all happens on-the-fly (i.e. without restarting the system)&lt;/strong&gt; and there is no performance penalty and all the devices, like graphics card, are fully accessible to the operating system, which is now executing inside virtual machine. This is all possible thanks to the latest virtualization technology from AMD called SVM/Pacifica. [via &lt;a href="http://theinvisiblethings.blogspot.com/2006/06/introducing-blue-pill.html"&gt;invisiblethings.blogspot.com&lt;/a&gt;]&lt;/p&gt;&lt;/blockquote&gt; &lt;p&gt;It&amp;#39;s&amp;nbsp;mesmerizing and scary at the same time, kind of like &lt;a href="http://www.boohbah.com/zone.html"&gt;BooBah&lt;/a&gt;.&amp;nbsp;There&amp;#39;s some doubt as to whether it&amp;#39;s code or just talk at this point:&lt;/p&gt; &lt;blockquote&gt; &lt;p&gt;However, there is great doubt throughout computer security circles as to whether blue pill is real or a mere stunt, since details and a working sample of the source code have not been made available, contravening the industry wide standard of &lt;a href="http://en.wikipedia.org/wiki/Full_disclosure"&gt;full disclosure&lt;/a&gt;. [via &lt;a href="http://en.wikipedia.org/wiki/Blue_pill_%28malware%29"&gt;Wikipedia&lt;/a&gt;]&lt;/p&gt;&lt;/blockquote&gt; &lt;p&gt;Regardless, the concept has been validated. Microsoft Research and a group from University of Michigan proposed SubVirt (&lt;a href="http://www.eecs.umich.edu/~pmchen/papers/king06.pdf"&gt;pdf&lt;/a&gt;), a VMM rootkit, in May 2006. Their paper is a fascinating schizophrenic game of cat and mouse: well, you could detect this by &lt;em&gt;blah&lt;/em&gt;, but then we could&amp;nbsp;&lt;em&gt;zhoop&lt;/em&gt;, and&amp;nbsp;even if you &lt;em&gt;flurped&lt;/em&gt; we could just &lt;em&gt;breeble&lt;/em&gt;. The SubVirt rootkit doesn&amp;#39;t take advantage of hypervisor technology and requires a reboot, but on the other hand it seems to be more mature.&lt;/p&gt; &lt;blockquote&gt; &lt;p&gt;We built VMBRs (Virtual Machine Based Rootkits) based on two available virtual-machine monitors, including one for which source code was unavailable. On today&amp;rsquo;s x86 systems, VMBRs are capable of running a target OS with few visual differences or performance effects that would alert the user to the presence of a VMBR. &lt;strong&gt;In fact, one of the authors accidentally used a machine which had been infected by our proof-of concept VMBR without realizing that he was using a compromised system!&lt;/strong&gt; [Subvirt paper &lt;a href="http://www.eecs.umich.edu/~pmchen/papers/king06.pdf"&gt;pdf&lt;/a&gt;]&lt;/p&gt;&lt;/blockquote&gt; &lt;p&gt;The point remains, though - we probably want our operating systems to know if they&amp;#39;re running on virtual machines. It sounds like they should always be able to do that. Anthony Liguori, and IBM software engineer who has worked on the &lt;a href="http://en.wikipedia.org/wiki/Xen"&gt;Xen&lt;/a&gt; hypervisor for two years, says:&lt;/p&gt; &lt;blockquote&gt; &lt;p&gt;Hardware virtualization requires a technique know as &amp;quot;trap and emulation&amp;quot;. The idea is that the hardware traps certain instructions and the VMM emulates those instructions in such a way as to make the software believe it is running in a virtual machine. &lt;strong&gt;Software emulation implies that these instructions take much longer to complete when executed under a VMM then on normal hardware. This fact is what can be used to detect the presence of a VMM.&lt;/strong&gt; [via &lt;a href="http://www.virtualization.info/2006/08/debunking-blue-pill-myth.html"&gt;virtualization.info&lt;/a&gt;]&lt;/p&gt;&lt;/blockquote&gt; &lt;p&gt;You may have noticed that&amp;nbsp;I jumped from talking about software VMM&amp;#39;s (VMWare, VirtualPC) to&amp;nbsp;both software and&amp;nbsp;hardware VM rootkits. From what I&amp;#39;ve read, it looks like this is going to be a cat and mouse game, but the VM rootkits will always need to deal with&amp;nbsp;the timing issues that Anthony mentioned. The SubVirt authors discussed this, too:&lt;/p&gt; &lt;blockquote&gt; &lt;p&gt;&lt;img style="margin: 0px 10px 0px 0px" src="http://static.flickr.com/54/149523517_c1b4d2213a_t.jpg" alt="" align="left" /&gt;A VMBR adds CPU overhead to trap and emulate privileged instructions, as well as to run any malicious services. &lt;strong&gt;These timing differences can be noticed by software running in the virtual machine by comparing the running time of benchmarks against wall-clock time.&lt;/strong&gt; A VMBR can make the detector&amp;rsquo;s task more difficult by slowing down the time returned by the system clock, but the detector can overcome this by using a clock that can be read without interference from the VMBR (e.g., the user&amp;rsquo;s wristwatch). [Subvirt paper &lt;a href="http://www.eecs.umich.edu/~pmchen/papers/king06.pdf"&gt;pdf&lt;/a&gt;]&lt;/p&gt;&lt;/blockquote&gt; &lt;p&gt;Well, I hope we can do better than wristwatch checks. I&amp;#39;d&amp;nbsp;hope that an OS could check the time of day once an hour and notice a 1% drag due to VM hosting, or at least pick it up over the course of a full day. Not great, but at least it&amp;#39;d be detectable.&lt;/p&gt; &lt;p&gt;&lt;img src="http://static.flickr.com/120/281100287_78479038ae.jpg" alt="" align="left" /&gt;There&amp;#39;s one more secret weapon against bad VMM&amp;#39;s. It&amp;#39;s probably the best&amp;nbsp;defense, but you&amp;nbsp;probably aren&amp;#39;t going to like it. I&amp;#39;m talking about the TPM, the Trusted&amp;nbsp;Platform Module. Microsoft&amp;#39;s &lt;a href="http://en.wikipedia.org/wiki/Next-Generation_Secure_Computing_Base"&gt;Next Generation Secure Computing Base&lt;/a&gt; Digital Rights Management (DRM) technology (called Palladium back when Vista&amp;nbsp;was Longhorn) ran on the&amp;nbsp;TPM.&amp;nbsp;Trusted computing works by using a hardware crypto chip which verifies&amp;nbsp;hardware and&amp;nbsp;software loaded by the hypervisor (which runs above the hardware virtualization layer, which runs above the&amp;nbsp;good old&amp;nbsp;CPU&amp;#39;s... sheesh, this is getting complicated...).&lt;/p&gt; &lt;p&gt;&lt;strong&gt;It&amp;#39;s as if&amp;nbsp;an OS running on a Trusted Computing platform was using HTTPS (SSL) to talk to hardware and trusted software like DRM software, but with much stronger crypto.&lt;/strong&gt; That&amp;#39;s a good thing from the point of view of safeguarding against rootkits. It&amp;#39;s bad news if you want to use software that works by virtualizing hardware (such as virtual soundcards which record streaming music like TotalRecorder, or virtual DVD drives which let you read ISO images like Daemon Tools or Alcohol 120). &lt;strong&gt;It&amp;#39;s also bad news if you want full access to DRM protected content, since DRM processing protected by a TPM is quite a bit more robust than the flimsy DRM stuff they&amp;#39;re using today.&lt;/strong&gt; DRM&amp;#39;d media running on a Trusted platform could be sent from disk to soundcard with the same kind of anti-tampering assurance you&amp;#39;d expect when you connect to your bank&amp;#39;s website across the big, bad internet. Hmm. Well, we&amp;#39;ve got a little while to think this through, since it&amp;#39;s mostly been removed from Vista and won&amp;#39;t ship until future versions of Windows.&lt;/p&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=744714" width="1" height="1"&gt;</description><category domain="http://weblogs.asp.net/jgalloway/archive/tags/Software+Development/default.aspx">Software Development</category><category domain="http://weblogs.asp.net/jgalloway/archive/tags/Microsoft/default.aspx">Microsoft</category><category domain="http://weblogs.asp.net/jgalloway/archive/tags/Goofy+nerd+stuff/default.aspx">Goofy nerd stuff</category><category domain="http://weblogs.asp.net/jgalloway/archive/tags/Virtual+PC/default.aspx">Virtual PC</category><category domain="http://weblogs.asp.net/jgalloway/archive/tags/General+Software+Development/default.aspx">General Software Development</category></item><item><title>Installing Windows Vista October CTP (Build 5231) on VPC with VM Additions</title><link>http://weblogs.asp.net/jgalloway/archive/2005/10/20/427986.aspx</link><pubDate>Thu, 20 Oct 2005 07:55:00 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:427986</guid><dc:creator>Jon Galloway</dc:creator><slash:comments>5</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://weblogs.asp.net/jgalloway/rsscomments.aspx?PostID=427986</wfw:commentRss><comments>http://weblogs.asp.net/jgalloway/archive/2005/10/20/427986.aspx#comments</comments><description>I installed the &lt;a href="http://msdn.microsoft.com/windowsvista/"&gt;Windows Vista October CTP (Build 5231)&lt;/a&gt; on Virtual PC yesterday. There were a few gotchas that I thought I'd share in case it saves anyone else some time. &lt;ol&gt; &lt;li&gt;Virtual PC can't capture an ISO image greater than 2.2 GB, so you need to use something like &lt;a href="http://www.daemon-tools.cc/dtcc/portal/download.php?mode=ViewCategory&amp;amp;catid=5"&gt;Daemon Tools&lt;/a&gt; on your host machine to mount the ISO as a virtual drive, then capture it as a physical drive in VPC.&lt;/li&gt; &lt;li&gt;Vista won't install on a RAW partition, which is what an unformatted VPC Virtual Hard Drive (VHD) image gives you. You can do &lt;a href="http://odetocode.com/Blogs/scott/archive/2005/07/27/2000.aspx"&gt;some tricky commandline DISKPART stunts&lt;/a&gt;, or you can just create the partition in the install process knowing that Vista still won't like it, reboot the VPC instance, and this time VPC will recognize the partition it created. I went with the second option.&lt;/li&gt; &lt;li&gt;This Vista build can't access Windows Update. You just get a message saying you need to use Automatic Updates and tells you how to set that up. Knowing that unpatched machines on the net can get haxxor'd in 20 minutes on average, I set the Auto Update time to the next hour and disabled the VPC network connection until that time. Silly me, there weren't any Auto Updates since it had just been released, but I still think minimizing Internet time before patching a machine is the best plan.&lt;/li&gt; &lt;li&gt;The VPC VM Additions Installation hangs on this Vista build, and the graphics are absolute hell without them (640x480 at 8 bit, I believe). The &lt;a href="http://www.aspdeveloper.net/Virtual_PC/rn-739-31197_VM_Additions_hang_on_Vista_Build_5219.aspx"&gt;trick&lt;/a&gt; is as follows: leave the hung installation running, go into the Control Panel and remove the VGA Display Driver, and say Okay when prompted to reboot. When the system comes back up, you'll have the state of the art S3 Trio display driver. It got wiggy on me when I tried to change the Display Resolution, so I rebooted again and was able to change the resolution and things were great. Dog slow, but great. If you cancel the install or kill the wrong msiexec process, the install rolls back and the drivers get removed, causing the magic not to happen.&lt;/li&gt;&lt;li&gt;I kind of lied about the VM Additions. The video drivers are installed, and they make a big difference, but the rest of the VM Additions aren't installed. That means no folder sharing, etc. They &lt;a href="http://blogs.msdn.com/virtual_pc_guy/archive/2005/08/02/447036.aspx"&gt;might release VM Additions for Vista Beta 1&lt;/a&gt;, but I'm not holding my breath.&lt;br /&gt; &lt;/li&gt; &lt;/ol&gt;I'll leave it to &lt;a href="http://www.winsupersite.com/reviews/winvista_5231.asp"&gt;the pundits&lt;/a&gt; to describe what's new in this build, but the most interesting things for me so far are &lt;a href="http://www.winsupersite.com/images/reviews/vista_ctp2_08.jpg"&gt;WMP 11&lt;/a&gt;, &lt;a href="http://www.retrosight.com/mediacenter/screenshot/Media_Center_Windows_Vista_5231/Small/Music_Library_Windows_Vista.png"&gt;Media Center Vista&lt;/a&gt; (which it sounds like is going to be inclueded in Vista, no longer a separate product), and the latest &lt;a href="http://www.winsupersite.com/images/reviews/vista_ctp2_32.jpg"&gt;IE7&lt;/a&gt; build.&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=427986" width="1" height="1"&gt;</description><category domain="http://weblogs.asp.net/jgalloway/archive/tags/Virtual+PC/default.aspx">Virtual PC</category></item><item><title>MSDN Subscriptions - Visual Studio 2005 Team System Beta 2 VPC</title><link>http://weblogs.asp.net/jgalloway/archive/2005/07/21/420144.aspx</link><pubDate>Thu, 21 Jul 2005 22:31:00 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:420144</guid><dc:creator>Jon Galloway</dc:creator><slash:comments>6</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://weblogs.asp.net/jgalloway/rsscomments.aspx?PostID=420144</wfw:commentRss><comments>http://weblogs.asp.net/jgalloway/archive/2005/07/21/420144.aspx#comments</comments><description>&lt;p&gt; &lt;/p&gt;&lt;div xmlns="http://www.w3.org/1999/xhtml"&gt;&lt;a href="http://www.mostlylucid.co.uk/archive/2005/07/01/1874.aspx"&gt;Scott told us&lt;/a&gt; it was coming, and here it is - a VS 2005 &lt;a href="http://www.microsoft.com/windows/virtualpc/default.mspx"&gt;Virtual PC image&lt;/a&gt; with Team System installed. It's on MSDN Subscriber Downloads (at subscription levels that will get VSTS when released, I think) under: &lt;/div&gt; &lt;div xmlns="http://www.w3.org/1999/xhtml"&gt;&lt;font color="green"&gt;&lt;strong&gt;&amp;nbsp;- Developer Tools&lt;/strong&gt;&lt;/font&gt;&lt;/div&gt; &lt;div xmlns="http://www.w3.org/1999/xhtml"&gt;&lt;font color="green"&gt;&lt;strong&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;- Visual Studio 2005&lt;/strong&gt;&lt;/font&gt;&lt;/div&gt; &lt;div xmlns="http://www.w3.org/1999/xhtml"&gt;&lt;font color="green"&gt;&lt;strong&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;- Visual Studio 2005 Beta 2&lt;/strong&gt;&lt;/font&gt;&lt;/div&gt; &lt;div xmlns="http://www.w3.org/1999/xhtml"&gt;&lt;font color="green"&gt;&lt;strong&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;- English&lt;/strong&gt;&lt;/font&gt;&lt;/div&gt; &lt;div xmlns="http://www.w3.org/1999/xhtml"&gt;&lt;font color="green"&gt;&lt;strong&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;- Visual Studio 2005 Team System Beta 2 VPC (English)&lt;/strong&gt; &lt;br /&gt;&lt;/font&gt;&lt;/div&gt;&lt;div style="border: 1px solid black; padding: 5px; background-color: gainsboro;"&gt;&lt;em&gt;&lt;b&gt;"Visual Studio 2005 Team System Beta 2 VPC (English) "&lt;/b&gt; &lt;br /&gt; &lt;br /&gt;This just popped up in the MSDN Subscription &lt;/em&gt; &lt;a href="http://msdn.microsoft.com/subscriptions/rss.xml"&gt;&lt;em&gt;RSS feed&lt;/em&gt; &lt;/a&gt;&lt;em&gt;. &lt;br /&gt; &lt;br /&gt;At 2.6GB (compressed) it contains:&lt;br /&gt;"Microsoft Windows Server 2003 Standard Edition (expires September 16, 2006) &lt;br /&gt;Microsoft Visual Studio 2005 Team Suite Beta 2 (expires May 1, 2006) &lt;br /&gt;Microsoft Visual Studio 2005 Team Foundation Server Beta 2 &lt;br /&gt;Microsoft .NET Framework 2.0 Redistributable Package Beta 2 &lt;br /&gt;Microsoft SQL Server 2005 Community Technology Preview &lt;br /&gt;Microsoft Office 2003 Standard Edition &lt;br /&gt;Microsoft Live Communication Server 2003" &lt;br /&gt; &lt;br /&gt;This SO rocks. I dig it when MS releases stuff as VPC images. It saves SO much time...&lt;br /&gt; &lt;br /&gt;Downloading now.&lt;br /&gt; &lt;br /&gt; &lt;strong&gt;Update #1, 7/20/2005 @ 5:01PM PDT:&lt;/strong&gt; &lt;br /&gt;Downloaded, unrar'ed (8.6GB uncompressed), VPC Differencing Disk created and now it's running.&lt;br /&gt; &lt;br /&gt;Much faster than if I did all the installs myself.&lt;br /&gt; &lt;br /&gt;The only issue I've run into so far is the Live Communications Service would not start. The Service's logon account being used, LCService, password had expired. All I had to do was that account's password to never expire and then the service started with no problems.&lt;br /&gt; &lt;br /&gt;Even with only giving the VPC 512MB RAM it seems to be running pretty fast...&lt;br /&gt; &lt;br /&gt;This really does rock. Good job Microsoft. &lt;/em&gt; &lt;p&gt;&lt;/p&gt; &lt;p&gt;Source:&amp;nbsp;&lt;a href="http://coolthingoftheday.blogspot.com/2005/07/msdn-subscriptions-visual-studio-2005.html"&gt;MSDN Subscriptions - Visual Studio 2005 Team System Beta 2 VPC&lt;/a&gt;&lt;/p&gt;&lt;/div&gt; &lt;font face="Verdana" size="2"&gt; &lt;p&gt;&amp;nbsp;&lt;/p&gt; &lt;/font&gt; &lt;font face="Verdana" size="2"&gt;&lt;p&gt;&lt;a href="http://imhoproject.org/"&gt;&lt;font face="Verdana" size="1"&gt;powered by IMHO 1.2&lt;/font&gt;&lt;/a&gt;&lt;/p&gt;&lt;/font&gt;&lt;!-- Powered by IMHO Instant Blogger Copyright (c) 2004 A.Boschin - http://www.elite.boschin.it --&gt; &lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=420144" width="1" height="1"&gt;</description><category domain="http://weblogs.asp.net/jgalloway/archive/tags/Microsoft/default.aspx">Microsoft</category><category domain="http://weblogs.asp.net/jgalloway/archive/tags/Virtual+PC/default.aspx">Virtual PC</category></item><item><title>Your system has no paging file...</title><link>http://weblogs.asp.net/jgalloway/archive/2005/06/13/412026.aspx</link><pubDate>Mon, 13 Jun 2005 11:45:00 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:412026</guid><dc:creator>Jon Galloway</dc:creator><slash:comments>3</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://weblogs.asp.net/jgalloway/rsscomments.aspx?PostID=412026</wfw:commentRss><comments>http://weblogs.asp.net/jgalloway/archive/2005/06/13/412026.aspx#comments</comments><description>&lt;FONT face=Verdana size=2&gt;
&lt;P&gt;My computer crashed hard a week ago. I&amp;nbsp;repaired the 
Windows install, but since then I've been getting the following message when any 
of the three interactive users logs on:&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;Limited Virtual Memory&lt;BR&gt;Your system has no paging file, or the paging 
file is too small.&amp;nbsp;&amp;nbsp;&lt;!--StartFragment --&gt; To fix this problem, go to 
&lt;B&gt;System&lt;/B&gt; in Control Panel, click the &lt;B&gt;Advanced&lt;/B&gt; tab, and under 
&lt;B&gt;Performance&lt;/B&gt;, click &lt;B&gt;Settings&lt;/B&gt;. On the &lt;B&gt;Advanced&lt;/B&gt; tab, click 
&lt;B&gt;Change&lt;/B&gt;. Click &lt;STRONG class=uiterm&gt;Custom size&lt;/STRONG&gt;, and then type an 
initial or maximum page file size.&lt;/EM&gt;&lt;/P&gt;
&lt;/FONT&gt;
&lt;FONT face=Verdana size=2&gt;&lt;P&gt;Unfortunately &lt;A href="http://support.microsoft.com/default.aspx?scid=kb;en-us;316528"&gt;KB 
316528&lt;/A&gt;&amp;nbsp;doesn't apply and &lt;A href="http://support.microsoft.com/default.aspx?scid=kb;en-us;315270&amp;Product=winxp"&gt;KB 
31270&lt;/A&gt; didn't work.&amp;nbsp;Frustrating. Further Googling just gave me that 
creepy thing where several people report a problem and no one answers it. Any 
ideas?&lt;/P&gt;
&lt;P&gt;Looks like time to repave. I was going to take this opportunity to upgrade to 
XP Pro 64 Bit (CPU is an AMD64, &lt;A href="http://www.winsupersite.com/reviews/windowsxp_x64_preview2.asp"&gt;Virtual PC 
won't run on XP 64&lt;/A&gt; (&lt;A href="http://groups-beta.google.com/group/microsoft.public.virtualpc/msg/baf5a501c8225f32?hl=en"&gt;yet&lt;/A&gt;&amp;nbsp;- 
although I'm sure it's in the works). Drat.&lt;/P&gt;&lt;/FONT&gt;&lt;!-- Powered by IMHO Instant Blogger Copyright (c) 2004 A.Boschin - http://www.elite.boschin.it --&gt;
&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=412026" width="1" height="1"&gt;</description><category domain="http://weblogs.asp.net/jgalloway/archive/tags/Lazy+Web+Requests/default.aspx">Lazy Web Requests</category><category domain="http://weblogs.asp.net/jgalloway/archive/tags/Goofy+nerd+stuff/default.aspx">Goofy nerd stuff</category><category domain="http://weblogs.asp.net/jgalloway/archive/tags/Virtual+PC/default.aspx">Virtual PC</category></item><item><title>[VPC] Compressing VHD files</title><link>http://weblogs.asp.net/jgalloway/archive/2005/05/07/406074.aspx</link><pubDate>Sat, 07 May 2005 15:51:00 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:406074</guid><dc:creator>Jon Galloway</dc:creator><slash:comments>5</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://weblogs.asp.net/jgalloway/rsscomments.aspx?PostID=406074</wfw:commentRss><comments>http://weblogs.asp.net/jgalloway/archive/2005/05/07/406074.aspx#comments</comments><description>&lt;p&gt; As&lt;A href="http://weblogs.asp.net/jgalloway/archive/2005/05/07/406069.aspx"&gt; mentioned some time ago&lt;/a&gt;, we're shuttling VHD files around the office to share preconfigured developer environments. Even &lt;a href="http://blogs.technet.com/megand/archive/2004/12/10/279808.aspx"&gt;precompacted&lt;/a&gt;, VHD files are still pretty huge - 5 to 10 GB. They can compress down quite a bit, though - as much as 70% or so.&lt;/p&gt; &lt;p&gt;The built in "compressed file" support in Windows can choke on files this size. I've been using &lt;a href="http://www.7-zip.org/"&gt;7-zip&lt;/a&gt;, a free compression program, to shrink mine. It includes support for ZIP, but self-extracting SFX's can cut a few hundred more MB's off the file size. That can save several minutes on a network file copy, or make the difference between whether the file will fit on a DVD. For example:&lt;/p&gt; &lt;p&gt;VHD - 5.4GB&lt;br /&gt;Zipped VHD - 2.1GB (38%)&lt;br /&gt;SFX VHD - 1.7GB (31%)&lt;/p&gt; &lt;p&gt;Here are some batch files which I'm using to compress the images. They use the command line version of 7-Zip.&amp;nbsp; I'm sure these batch files can be improved, or I could add a right click option to VHD files or something - I'm open to suggestions. The main thing I wanted to share, though, is the command line settings for max compression SFX and ZIP compression:&lt;/p&gt; &lt;p&gt;SFX (Self Extracting EXE):&lt;/p&gt; &lt;div style="background-color: gainsboro;"&gt; &lt;p&gt;d:\&lt;br /&gt;cd "d:\virtual machines\VS2005\"&lt;br /&gt;c:\Utils\File\7zip\7za.exe a -sfx -mx=9 VS2005Beta2.exe VS2005Beta2.vhd&lt;/p&gt;&lt;/div&gt; &lt;p&gt;Zip:&lt;/p&gt; &lt;div style="background-color: gainsboro;"&gt; &lt;p&gt;d:\&lt;br /&gt;cd "d:\virtual machines\VS2005\"&lt;br /&gt;c:\Utils\File\7zip\7za.exe a -tzip VS2005.zip VS2005.vhd -mx=9&lt;br /&gt;&lt;/p&gt;&lt;/div&gt;&lt;!-- Powered by IMHO Instant Blogger Copyright (c) 2004 A.Boschin - http://www.elite.boschin.it --&gt; &lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=406074" width="1" height="1"&gt;</description><category domain="http://weblogs.asp.net/jgalloway/archive/tags/Virtual+PC/default.aspx">Virtual PC</category></item><item><title>[VPC] Using Virtual PC for developer portability</title><link>http://weblogs.asp.net/jgalloway/archive/2005/05/07/406069.aspx</link><pubDate>Sat, 07 May 2005 15:30:00 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:406069</guid><dc:creator>Jon Galloway</dc:creator><slash:comments>4</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://weblogs.asp.net/jgalloway/rsscomments.aspx?PostID=406069</wfw:commentRss><comments>http://weblogs.asp.net/jgalloway/archive/2005/05/07/406069.aspx#comments</comments><description>&lt;P&gt;
&lt;FONT face=Verdana size=2&gt;I've been 
using VPC quite a bit lately. At work, we've got a few applications which can 
take days to get set up for development - one app is ASP.NET mixed with VB DCOM 
on DB2, another is even more confusing. Both take a few days to configure, and 
that's if you follow the directions and ask the guys who built it. That kills 
developer portability - a 30 minute bug fix becomes a 30 hour bug fix if the 
developer hasn't gone through the installation initiatiation on that system 
yet.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;So when our groups officially merged recently and 
cross-training was looking unavoidable, I worked with the leads on each of these 
systems to configure a VPC development image. The nice thing with this is that 
the system is correctly configured by someone that knows what they're doing. The 
image is fully patched and includes&amp;nbsp;Visual Studio, configured websites, 
appropriate database client tools, virus scanning software, and source control 
client software.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;Now, moving a new developer onto a project is as 
simple as installing VPC (about 5 minutes), copying the image (DVD / network 
share / USB2 external hard drive), and starting it up. Of course, the developer 
needs to check out the latest code from source control, but they just need to 
pull down the deltas since the image was built.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;&lt;/FONT&gt;&lt;FONT face=Verdana size=2&gt;I know this is old 
news and elementary VPC usage for some developers. At Microsoft, for instance, 
&lt;A href="http://blogs.technet.com/megand/archive/2005/04/29/404343.aspx"&gt;QA 
tests on VPC's so they can give an image in the error state to the developer to 
debug&lt;/A&gt;. However, it's saved our group so much time lately that I wanted to 
share our success story. More VPC goodies and links to 
follow.&lt;/P&gt;&lt;/FONT&gt;&lt;!-- Powered by IMHO Instant Blogger Copyright (c) 2004 A.Boschin - http://www.elite.boschin.it --&gt;
&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=406069" width="1" height="1"&gt;</description><category domain="http://weblogs.asp.net/jgalloway/archive/tags/Virtual+PC/default.aspx">Virtual PC</category></item></channel></rss>