![]() |
![]() |
This is obsolete, use VirtualBox now.
You can use VMware to turn Windows XP into a Linux application that starts cleanly the same way each time, regardless of what the user or viruses do to it. The feature list includes:
# Install Ubuntu 7.10 from cd # log in -> Application -> Accessories -> Terminal $ sudo -i # reinsert 7.10 cd for apt-get's use $ apt-get -y install build-essential emacs22 emacs22-el elisp-manual # you might add these for your development convenience $ apt-get -y install openssh-server tkdiff $ apt-get -y update $ apt-get -y dist-upgrade # wait while all this is downloaded and installed. I had to hit enter # on one text-based query box. # reboot and remove cd before boot # log in $ sudo -i # so that ssh incoming to root works $ passwd root
# Make window focus follow mouse $ gconftool-2 --set /apps/metacity/general/focus_mode mouse --type string # Make gnome applications accept Emacs editing keys $ gconftool-2 --set /desktop/gnome/interface/gtk_key_theme Emacs --type string # Make the left Windows key dig through windows -> System -> Preferences -> Keyboard Shortcuts -> Window Management -> Raise obscured window, otherwise lower -> Left Windows logo key -> System -> Preferences -> Appearance -> Fonts -> Subpixel smoothing (LCDs) -> System -> Preferences -> Appearance -> Visual Effects -> None
-> Application -> Accessories -> Terminal $ sudo -i # Install VMware-server-1.0.6-91891.tar.gz $ tar -zxvf VMware-server-1.0.6-91891.tar.gz $ cd vmware-server-distrib $ ./vmware-install.pl In which directory do you want to install the binary files? [/usr/bin] /depot/vmware-server-1.0/bin # When you see this error, ignore it, just hit enter: Please specify a port for remote console connections to use [902] inetd: no process killed Unable to make the Internet super-server (inetd) re-read its configuration file. Please restart inetd by hand: killall -v -HUP inetd Hit enter to continue. # Take prompted suggestions for everything else, except: In which directory do you want to keep your virtual machine files? [/var/lib/vmware/Virtual Machines] /depot/vmware-virtual-machines # Enter no-cost serial number you received from vmware.com
$ /depot/vmware-server-1.0/bin/vmware -> Create a new virtual machine Typical 1. Microsoft Windows Windows XP Professional Name: "XP" Location: /depot/vmware-virtual-machines/XP Use Network Address Translation (NAT) Disk size 8 Gig Allocate all disk space now Split disk into 2GB files -> Edit virtual machine settings # On a Dell Optiplex GX270 from 2004, with 2 Gig of memory 752 Meg of memory
# Insert Win XP Pro cd # close Ubuntu file browser which opens on cd -> Power on this virtual machine # Do Windows XP install as prompted by Windows Format the partition using the NTFS file system (Quick)
It means your cd is a bad copy and you need a replacement. If you put the cd into the tray in Ubuntu and try to tar off the I386/asms directory, tar will report read errors on the bad files. Replace the cd, quit VMware, delete the XP directory, and redo the virtual machine creation and XP install from scratch. Continue as if we didn't get that error:An error has been encountered that prevents Setup from continuing One of the components that Windows needs to continue setup could not be installed. The parameter is incorrect. Press OK to view the Setup log file Error: Installation Failed: D:\I386\asms. Error message: the parameter is incorrect.
hostname is "VMware", organization is "something appropriate for you", username is "user" -> Shut Down from Start menu
-> Power on this virtual machine # Insert the Office 2003 cd, Windows will autorun it Do you want to check for updates? Yes Installed service pack 3 update for Office 2003 Did not choose beta updater version Closed Office 2003 update web site browser when prompted Turned on automatic Windows update (to prevent error messages) Did Windows update Installed ActiveX control it asked for Installed updating program it asked for Update includes Service Pack 3 Rejected Internet Explorer version 7 Downloaded MacAfee to Desktop Cleaned IE, -> Tools -> Internet Options Set start page deleted Cookies deleted Temporary files deleted downloaded files cleared Browsing history
Make sure to select Perpetual License
-> VMware -> VM -> Install VMware tools # Must use Complete instead of Typical to get File Sharing driver Setup type: Complete InstallShield completes Accept video improvement suggestions VMware tools icon in taskbar Options -> Time sync between VM and host -> Start -> Shut Down -> VMware -> File -> Quit
$ emacs /depot/vmware-virtual-machines/XP/XP.vmx delete: uuid.location uuid.bios add: uuid.action = "create" usb.present = "TRUE" usb.generic.autoconnect = "FALSE" sound.present = "TRUE" sound.fileName = "-1" sound.autodetect = "TRUE" sound.virtualDev = "es1371" sharedFolder.maxNum = "1" sharedFolder.option = "alwaysEnabled" sharedFolder0.present = "TRUE" sharedFolder0.enabled = "TRUE" sharedFolder0.readAccess = "TRUE" sharedFolder0.writeAccess = "TRUE" sharedFolder0.hostPath = "/" sharedFolder0.guestName = "root" sharedFolder0.expiration = "never" isolation.tools.hgfs.disable = "FALSE"
$ cd /depot/vmware-virtual-machines/XP $ tar -cf /someplace-safe/XP-this-date.tar .
If you did -> VM -> Snapshot -> Remove Snapshot, most of these changes will be reversed. To reverse all of them, go back to the tar copy.$ /depot/vmware-server-1.0/bin/vmware # Do not power on virtual machine. -> Snapshot These files get modified: XP.vmx XP.vmsd These files get added: XP-Snapshot1.vmsn XP-000001.vmdk XP-000001-s005.vmdk XP-000001-s004.vmdk XP-000001-s003.vmdk XP-000001-s002.vmdk XP-000001-s001.vmdk
$ for i in XP.vmx *000001* ; do cp -va $i $i.master ; done
The .vmx file must be writable by whoever is running the player. Both user-triggered option changes and notes to itself about generated ethernet addresses and so forth get written to it:root@here# cd / ; tar -cf - depot/vmware-virtual-machines/XP | ssh root@elsewhere 'cd / ; tar -xvpf -' root@elsewhere# cd /depot/vmware-virtual-machines/XP
$ chmod 777 . $ chmod 644 * $ chmod 755 XP.vmx*
$ mkdir -p /depot/windows-1.0/bin
$ cd /depot/windows-1.0/bin
$ cat > windows
#!/bin/bash -e
trap '
SAVEDSTATUS=$?
set +x
if [ -z "$CLEANEXIT" ]
then
echo "$0: ERROR Unexpected exit with return value of $SAVEDSTATUS"
exit $SAVEDSTATUS
fi' EXIT
#-----
BASE="/depot/vmware-virtual-machines"
EXT="XP"
SNAPFILES="${EXT}.vmx
${EXT}-000001.vmdk
${EXT}-000001-s001.vmdk
${EXT}-000001-s002.vmdk
${EXT}-000001-s003.vmdk
${EXT}-000001-s004.vmdk
${EXT}-000001-s005.vmdk"
cd "$BASE/$EXT"
rm -f $SNAPFILES *.log
for i in $SNAPFILES
do
cp -a "${i}.master" "$i"
done
vmplayer "$EXT.vmx"
# Reset entirely so the native VMware Server 'open a machine' dialog
# will still work
rm -f $SNAPFILES *.log
for i in $SNAPFILES
do
cp -a "${i}.master" "$i"
done
#-----
CLEANEXIT=1
exit 0
^D
$ chmod +x windows
Add /depot/windows-1.0/bin to PATH in whatever way you do that
locally.
$ tar -zxvf VMware-player-2.0.4-93057.i386.tar.gz $ cd vmware-player-distrib $ ./vmware-install.pl $ vmplayer # accept license -> Player -> Quit
$ /depot/windows-1.0/bin/windows -> Player -> Shared Folders -> Always enabled # In Windows Explorer, your Linux root directory is at: \\.host\Shared Folders # This file is created by Player $ chmod 644 /depot/vmware-virtual-machines/XP/XP.vmxf
If you get a duplicate machine warning when you run Player, click OK and ignore it.
When you choose to evolve what is on the Windows, such as to set up a
PostScript driver and network printers, I suggest going back to the
pre-snapshot tar copy, making the changes to a copy of that, and
moving forward from there.
You type "\\.host\Shared Folders" into a Windows explorer and it doesn't find the host, yet you've added the file sharing entries to the .vmx file, and enabled File Sharing in VMware at powerup time. Is the Windows driver installed for VMware file sharing? Here's how to check:
Look at the bottom for:-> Start -> Help and Support Search: network diagnostics Fix a Problem o Network Diagnostics Scan your System
If it isn't there, do:Modems and Network Adaptors [+]Network Clients VMware Shared Folders <--- !!!
And this time pick:-> VMware -> VM -> Install VMware tools
Setup type: Complete
It seems that VMware server doesn't have the feature to collapse a snapshot back into the base hard drive image; the choices are either to run on the snapshot forever, or to Revert, make unrevertable changes, then take another Snapshot. This suggests a tar copy as a snapshot operation to provide the feature missing from VMware Server.
http://searchvmware.techtarget.com/tip/0,289483,sid179_gci1277577,00.html
The easiest way to recombine these snapshots into a single virtual hard disk file is to download a 30-day trial version of VMware Workstation 5. Using Workstation it is possible to clone a virtual hard disk or collapse a snapshot chain back to one virtual hard disk file.
| (C) University of Florida, Gainesville, FL 32611; (352) 392-1941. This page was last updated Tue Sep 25 00:30:37 EDT 2012 |
![]() |