12/09/2009

Kickstart and FT logging

One of the great features of vSphere is the option to make your vm's fault tolerant.
For those who are not yet aware of what this function does, just a short description.

Under normal conditions, your vm will run on 1 physical esx host. You can move it to another physical host by using vmotion if you use shared storage.

With Fault Tolerance, your vm will run simultaneously on 2 physical hosts, again using shared storage.
Your primary vm will be the one that's accessed all the time, the secondary vm will take over in case of physical problems with the esx host where the primary vm is situated.
As the secondary vm is synched (vlockstep) all the time, your vm is not protected against guest crashes. If your guest OS fails on the primary host, your secondary vm will fail too! As said before, you require shared storage, your secondary vm will use the same vmdk files!
And the saga continues, once your secondary vm becomes primary, a new secondary will be created on another esx in the same cluster (if a host is available).
For more details, just read the following pdf of vmware, as you have some requirements.

As certain commands where removed or not yet known to script the installation using kickstart, it was hard to find out how to enable the FT logging. Using the VI client you can enable FT logging on your vmkernel port, but scripting this was harder.

So here it is, just add following lines in your kickstart script.
To create your FT port on vSwitch0
esxcfg-vswitch -A "Fault Tolerance" vSwitch0
To add an ip address to your FT port
esxcfg-vmknic -a -i [FT IP ADDRESS] -n 255.255.255.0 "Fault Tolerance"
If you use vlan's, set the vlan of the FT port
esxcfg-vswitch -v [VLAN of FT IP] -p "Fault Tolerance" vSwitch0

Enabling vmotion will require following code :
vmware-vim-cmd hostsvc/vmotion/vnic_set vmk0
I created 2 vmkernel ports, 1 for vmotion (vmk0) and 1 for FT (vmk1).

And here it is, to enable FT on your vmkernel port
vmware-vim-cmd hostsvc/advopt/update FT.Vmknic string vmk1

Checking afterwards in your VI client will show you that FT is enabled on your vmkernel port.

Gr,

David

01/09/2009

Whoami

As this is the first post, let me start to write who I am.

I am David, working in IT since 1998, starting with basic helpdesk support and an Architectural background.

After 4 years I started to work in the Back Office where we had to care of AD, Exchange, File and print servers, ... After a couple of years I moved to another company as I was blocked in my function to give 3rd line support for all the products they sell.
As I didn't really feel ok in that position, I moved again to a costumer where I started to help in their migration from w2k to XP and Exchange migration. After the migration I continued to provide global end-user support, making scripted pc installations, software distribution without admin rights, AD and Exchange.

Since 2007 I moved to the Infrastructure team. A difficult decision, but one of the best decisions ever made. No more clients, only infrastructure to maintain. Daily tasks are installing and maintaining all HP servers (blades & rack servers), HP Storage (EVA 5000/8000/8100), San switches and after a couple of months I took over the virtual infrastructure (ESX 3.01).

With mainly a Windows background, no linux or esx knowledge at all an entire new world opened.
After following the ESX 3 Install and configure, I started to update our hosts to 3.0.2. A couple months later, with some help and a lot of googling, a design was made how our virtual infrastructure should look like with 3.5. We started to use clusters, HA, DRS, ... and most important, scripted installations. Using the UDA appliance we deployed our 10 esx servers fully configured and ready to use. Meanwhile I followed the DSA course to get some more troubleshooting and background knowledge.

Since june I'm reviewing our current virtual infrastructure as we are moving into the direction of an almost complete virtual datacenter.
With vsphere arriving in may, I immediately had to start to test all new features (as I could not participate in the beta program) and see how they could improve our infrastructure.
As I'm not an update person, I rewrote and adapted our existing kickstart scripts to easily move to vsphere.

That's about it, now let's post some issues and solutions we've tackled during our migration.

Cheers,

David