Categories
blog howto server virtualization

MONITOR PANIC: Unable to decompress PPN from swap slot for VM

VMWARE ESXi 5.1U1

My VM would power off without apparent reason.
Looking in to the logs this error appears.

MONITOR PANIC: Unable to decompress PPN from swap slot for VM

I believe the underlying storage (a single SATA disk in my case) to be at fault, or almost dying I guess.
I storage vmotion’ed the VM to another disk.

Categories
blog howto server windows

VMware image customization in progress

Recently I came across an issue with a virtual machine that was deployed from a template. After the newly created virtual machine was booted up it seemed that the generalization did not fully complete. The password was not changed and some other minor things were not as it should have been after full customization runs.

We then saw that the VM kept saying “VMware image customization in progress” on every reboot right before windows boots. If you already have configured and/or are using the VM and don’t want to start over, here’s what you can do.

Open regedit and find the key:
HKLM\SOFTWARE\VMWare,Inc.\Guest Cutomization\
or on a 64-bit system:
HKLM\SOFTWARE\Wow6432Node\VMWare,Inc.\Guest Cutomization\
Change the value for “CustomizationInProgress” to “0”.

Then navigate to the following key:
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Session Manager
Change the value for “BootExecute” to the default of “autocheck autochk *”, you should just delete the “sysprepDecryptor.exe” part and the enters after it. Be careful or your system won’t boot.

You should probably check your SID and see if it’s unique, to make sure the customization did indeed change this. Altough duplicate SID’s should be not a real problem (according to Microsoft), don’t do it on your servers!
http://technet.microsoft.com/en-us/sysinternals/bb897417.aspx

PS: In my case the customization failed because sysprep had already been run 3 times (template was cloned from previous deployed machine) and apparently you can only do it 3 times unless you add the special option not to rearm the licensing state (which vmware doesn’t add when customizing).

PS2: If you manually did sysprep but got stuck because with error

A fatal error occurred while trying to sysprep the machine

because of the rearm failure, try this: http://itfunk.wordpress.com/2013/01/09/resetting-rearm-count-in-windows-7/
Put the following in a bat file called c:\delwpa.bat

reg load HKLM\MY_SYSTEM “%~dp0Windows\System32\config\system”
reg delete HKLM\MY_SYSTEM\WPA /f
reg unload HKLM\MY_SYSTEM

reboot and using F8 choose repair computer, choose keyboard, type password and choose command prompt. Find your correct drive could be C or D or higher (depends on reserved partitions), and execute the BAT file. Rearm state will be wiped, after reboot you will see not genuine but you can rearm again 3 times now.

Categories
blog howto server virtualization

VMware ESXi 5.1 on USB stick won’t boot Proliant DL380 G5

Installation using the cdrom was succesful but after restarting the server won’t boot from the USB stick.
Make sure you set the correct BIOS options to allow to boot from USB.
bios_boot_order

bios_usb_enable

ESXIi formatwithmbr runweasel

If still doesn’t boot than it probably has to do with GPT/MBR formatting of the USB stick done by VMWARE.
You need to boot from the ESXi install CD again and right after you press enter to choose “ESXi5.1 installer ISO …” you see in the lower righthand corner the text “Shift + o” press this key combination (shift and the letter o). Now you see the text “runweasel” remove any chars after this, type a space and then “formatwithmbr”.

Now install as normal but now VMware should format your USB stick as MBR instead of GPT and you should be able to boot from it after the install finishes.

sources:
http://vmtoday.com/2012/09/esxi-5-wont-boot-from-usb/
http://communities.vmware.com/thread/430852?start=0&tstart=0
http://communities.vmware.com/message/1824957#1824957
http://community.spiceworks.com/topic/247715-sandisk-cruzer-fit-esxi-5

Categories
blog howto network virtualization windows

Delete or show hidden no longer active or present network adapters Device Manager

Open a command prompt. Start: RUN -> CMD (OK)
At the prompt type:
set devmgr_show_nonpresent_devices=1
At the prompt type:
start devmgmt.msc
In the menu view, click on “Show hidden devices”.
Now go to network adapters and uninstall the ones that you were looking to uninstall, it will be greyed out.

Categories
blog howto virtualization

Upgrade ESXi (free) 4.0 to 4.1.0 U1 (Update 1)

Are you upgrading from 4.0 to 4.1U1 ? Then read on or you will end up like me browsing trough the ZIP file and the XML files inside to find out the correct bulletin name. It’s not pleasant to do this when you just entered maintenance mode in a small time frame to stop production vm’s.

Procedure from the Upgrade guide:

Procedure
1 Download the following upgrade ZIP bundle from the VMware Web site to a location that is accessible
to the vSphere CLI machine.
upgrade-from-ESXi4.0-to-4.1.0-0.0.build#-release.zip
The upgrade ZIP bundle contains and esxupdate bulletin and an upgrade bulletin.
2 Power off any virtual machines that are running on the host and place the host into maintenance mode.
3 Install the esxupdate bulletin by running the following command on the vSphere CLI machine.
vihostupdate –server host name or IP address -i -b location of the ESXi upgrade ZIP bundle –
B ESXi410-GA-esxupdate
4 Install the upgrade bulletin by running the following command on the vSphere CLI machine.
vihostupdate –server host name or IP address -i -b location of the ESXi upgrade ZIP bundle -B ESXi410-GA
5 Verify that the bulletins are installed on the ESXi host by running the following command.
vihostupdate.pl –server host name or IP address –query
6 Reboot the host.

What they fail to mention is that the bulletin name in step 4 has changed. So in step 4 the command should now read:

vihostupdate –server host name or IP address -i -b location of the ESXi upgrade ZIP bundle -B ESXi40-TO-ESXi41UPDATE01

PS: After the upgrade I had some problems connecting to the management IP. I did a restart management but no effect. I then changed the mgmt IP and I could connect. However I had to update my client before I could login.

Categories
linux server virtualization

GhettoVCB ESX(i) VM’s backup: E-mail logfile

UPDATE: GhettoVCB now has it’s own function to send a report mail. It only works on ESXi > 4.1.

I’m using an excellent script to backup my virtual machines called GhettoVCB. This script works perfect. I wanted to get the daily logfile in my e-mal inbox. I have ESXi (4.0) and i don’t know whether it can e-mail by itself, i think not. But i used a linux VM i am running, to pull the logfile and mail it to me. The linux VM is set up with sendmail and outgoing mailhost is configured. I you don’t have a linux VM, a windows VM or PC can work too. You can use wget for windows to pull the file (syntax would maybe change a little bit) and then blat to mail the file. I won’t go in detail about this.

I have altered the GhettoVCB script to make the backups & logiles use this date syntax “date +%F”. I find it easier to read for humans. You have to adjust this in the Cronjob that calls the ghettoVCB script, the logfile is given as a paramter.
In the script below, please adjust the youruser and yourpass to valid login credentials for browsing the datastore trough https. Usually the user you login with directly on the ESXi. Also adjust the you@domain.tld, place your e-mail address. Pretty simple & basic but it works excellent. Last point, adjust the 192.168.x.y to your ESXi’s IP address.

#grab esxi backup log file and mail it v0.1
#Note the WGET part should be 1 line, no line breaks
#Adjust the youruser & yourpass to valid credentials for logging in to ESXi (browse the datastore)
#Adjust the IP address (192.168.x.y) to your ESXi ip addresss
#In the wget line below, my logs were located in a folder called backup on a datastore called 750GBdisk2
#You could check the syntax of the link by browsing to your datastore and locate the backup log files then look at the addressbar
cd /tmp
wget "https://192.168.x.y/folder/backup/ghettoVCB-backup-$(date +\%F).log?dcPath=ha-datacenter&dsName=750GBdisk2" --user youruser --password yourpass --no-check-certificate
cat /tmp/ghettoVCB* | mail -s "Backup log ESXi4" you@domain.tld
rm -rf /tmp/ghettoVCB*