Saturday, August 30, 2008

Set user account logon credentials in Windows virtual guest

I use virtualized guests to test out different applications, updates, or trying some new "hack". For one of my guests, I needed to set the account credentials to automatically log in with the appropriate credentials. Below are the steps I used to set this up.

Note - please don't use these steps on your physical host. These steps allow access to the computer (virtual or physical) just by turning on the PC.

Uncheck the "Users must enter a user name and password to use this computer"

Click 'Apply'

You will be prompted for a user account name and password. Enter in the ID you want to use for future sessions.

When you restart the OS, the user account you selected will be the account used when the OS restarts.

Teracopy - Making file copy movement easier

I recently downloaded the Teracopy application and have found this little utility to be a great add-on to the Windows Explorer shell. The context menus aid in copying or moving files from one location to another. May not sound like a big deal outside of what Windows Explorer is already able to perform, but the additional functionality of pausing the file movement is a great bonus.

As shown in the image above, the ability to 'skip' or 'pause' file movement comes in very handy.

Teracopy webpage LINK

Friday, August 29, 2008

Compacting Virtual PC 2007 Disk

I have been using Virtual PC off and on since the 2004 iteration. One area that I have come across is shrinking the disk. I started to read through the manual/help file provided and found this:

(Search 'Using Virtual Disk Precompactor' in the help file for the textual version).

Let's get started and see what happens:

Things needed:
  • Time and patience
  • Make sure you have the Virtual Disk Precompactor.iso for Windows guests. (Linux guest compacting will be posted later).

Some quick tidbits and begin:

  • My virtual disk is set to 64GB logical partition within the guest.
  • My host system shows the "vhd" at 21GB right now.
  • Empty 'Recycle Bin'.
  • Run disk clean up on my logical drive.
  • Run your favorite defrag utility on the drive within the guest.
  • Capture the Virtual Disk Precompactor.iso file from PC\\Program Files\Microsoft VirtualVirtual Machine Additions\ (your installation directory will vary)
  • When the CD mounts, you will be prompted if you want to automatically start the program.
  • If you have more than one disk in the guest, choose no so you can select the disk to precompact. This is done with the '-setdisks' command option. If you don't do this AND you have multiple disks, running the program will compact ALL of the disks.
  • Go get some coffee, a beer, soda, can of tuna...this may take awhile. I timed my run:
Start time: 5:42 PM
4 bars o' progress: 5:53 PM
End time: 6:19 PM

Back to bullets...
  • Shut down the guest
  • Go through the Virtual Disk Manager in the Virtual PC 2007 Console
Start time: 6:19 PM
4 bars o' progress: 6:28 PM
10 bars o' progress: 6:38 PM

At this point, I realized that running the compact and having the disk retain the same name is going to create a bottleneck. So I changed the destination to another drive - completely separate from the source drive where the original VHD lives.

I canceled and then restarted the compact. Note, you are going to need a ton of extra disk space on the destination drive if you use this method.

Start time: 6:41 PM
5 bars: 6:50 PM
10 bars: 6:55 PM
15 bars: 7:02 PM
20 bars: 7:11 PM
End time: 7:26 PM

Without the information on my computer, applications or services I have running, and the hardware from one disk to another, the times mentioned above are only to illustrate how long these steps may take.

The destination disk, for me, ended at 11.8GB. That's a 43% reduction in the disk sized used.

From a virtual machine perspective, a couple of items I usually will run with:
  • Turn off 'System Restore'. I see no real need for this in a virtual machine
  • Turn off 'Virtual Memory'. Swapping to a virtual disk causes a waste of IO between the host and guest.
  • Turn off 'Automatic Updates'. I run manual updates and select only those I want/need.
Obviously, if you use these functions specifically in your virtualization purposes, use them.

Good luck.

Using Virtual Disk Precompactor