Search This Blog

Friday, 5 February 2010

HP Flex-10, Virtual Connect & vSphere




So there are restrictions to how you can implement this configuration. There are some really good blogs that describe it, such as

http://kennethvanditmarsch.wordpress.com/2009/11/04/understanding-hp-flex-10-mappings-with-vmware/

http://frankdenneman.wordpress.com/2009/04/26/flex-10-lessons-learned/

so I won't repeat what has been said before.

However, the restriction where you are unable to present the same VLAN to more than one FlexNIC on the LOM can be got around if you present the VLAN as a native VLAN (i.e. 0) to one FlexNIC, and apply the VLAN tag to the other FlexNIC.

This is really helpful when you have a virtual vCenter as if this wasn't possible, you would have to put it on a different VLAN to the ESX(i) hosts. However, I have configured it so that vSwitch0 on the hosts is presented with the native VLAN, and the vSwitch (or dvSwitch) that vCenter is attached to is presented with the tagged VLAN.


UPDATE: Whilst this configuration works during normal operation. In the event of loss of Virtual Connect module, or uplinks, all management networking will be lost. This is because the LOM to uplink mapping is hard coded, and whilst you can configure the mapping differently, it will break. Therefore always remember the 1 LOM to on uplink rule.

Friday, 22 January 2010

VMware Update Manager Download Service



I knew it existed, but I hadn't come across this until now, so here are my notes.

The UMDS is very useful in 2 scenarios

1. When the VUM server has no access to the internet (proxy or not)
This is a pretty obvious use case. VUM can't get the updates, so something else needs to.

2. When there are multiple VUM servers
To avoid all the VUM servers downloading all the same patches, just have UMDS do it instead, and then place them onto a shared device/folder somewhere that all the VUM servers have access to.


In both cases, the updates will be downloaded by UMDS, exported, and then placed onto some sort of shared storage that the VUM servers can see. In scenario 1, this can be a shared folder, a usb drive, or even a CD. In scenario 2, I would suggest that only a shared folder makes sense.

UMDS is not very attractive in terms of using it, it doesn't have a GUI, and you need to use the command vmware-umds which is found in the c:\program files\vmware\infrastructure\update manager folder. Here are the switches as reported by the -H (--help) option:

Basic Commands:

-H [ --help ]
Help on running (this description)

-D [ --download ]
Download Updates based on the current configuration

-E [ --export ]
Export Updates

-R [ --re-download ]
Re-download the Updates

-S [ --set-config ]
Setup Initial Configuration

-v [ --version ]
Print the UMDS version number

-i [ --info-level ] arg
The level of information shown on the console: verbose, info.



Optional arguments for Export and Re-download:

--export-store arg
The destination directory for export operation (Overrides setting from initial configuration)

-s [ --start-time ] arg
For re-download, restrict selection to include updates downloaded since this time (inclusive). Format is ISO-8601 YYYY-MM-DDThh:mm:ss[Z]. Use 'Z' at the end to indicate UTC

-t [ --end-time ] arg
For re-download, restrict selection to include updates downloaded till this
time (inclusive). Format is ISO-8601 YYYY-MM-DDThh:mm:ss[Z]. Use 'Z' at the end to indicate UTC



Arguments for setting up initial configuration:

--patch-store arg
The directory to store all the downloaded updates

--proxy arg
Proxy Server settings in host:port format.To disable proxy, use --proxy ""

-h [ --enable-host ] arg
Enable ESX Host update downloads: true or false

-w [ --enable-win ] arg
Enable Windows VM update downloads: true or false

-l [ --enable-lin ] arg
Enable Linux VM update downloads: true or false

-e [ --export-store ] arg
The default directory for exporting updates

--lang arg
Specify the languages for which updates are downloaded. Multiple values are allowed. Valid values are: ARA, CHS, CHT, DA, ELL, ENU, FI, FRA, GER, HEB, HUN, ITA,
JPN, KOR, NL, NO, PLK, PT-BR, RUS, ESN, SV, THA, TRK



So the common setup commands will be:

vmware-umds -S -h true
vmware-umds -S -w false
vmware-umds -S -l false

If you only want to download host patches and not Virtual Machine patches. I haven't found a way of only downloading certain versions of host patches such as only the ESXi 4 patches. You will end up downloading ALL the patches for ALL the versions.

When you have run the commands above, you can now download the patches by running:

vmware-umds -D

This will download the patches into the repository you specified during install. BEWARE - this takes a LONG time!



UPDATE

See http://kb.vmware.com/selfservice/microsites/search.do?language=en_US&cmd=displayKC&externalId=1015663 to see how to only download ESX 4 patches

Wednesday, 13 January 2010

vCenter installation



  • When creating the database first, run the script provided in the VMware installation and setup guide, but change the password.
  • I also used the script to create the Update Manager database, but I changed the username.
  • For 64 bit servers, run the odbc.exe in c:\windows\SysWoW64\odbcad32.exe, and configure the System DSN from there.
  • It's best to use a service account for the vCenter and Update Manager services, and it is also better to create these before install, rather than changing them after.
  • These service accounts will need to have run as a service, act as part of the operating system rights, plus be local admins on the vCenter server.
  • The service account will also need access to the SQL vCenter database created in point 1
  • When installing vCenter, make sure you are logged on with a domain account with local admin rights rather than a local account. It will also need rights to the SQl server. I got error "25004: Failed to create vcenter server repository" right at the end of the install which i think was due to this causing issues with connection to the SQL server.
  • When installing, I found it much quicker to unzip the vCenter iso/zip onto a drive on the vCenter server, rather than connecting the iso to the CD or opening the zip from a remote server.

Sunday, 3 January 2010

ESXi Hints and Tips

Some useful information for using ESXi

Its worth finding out about and installing vMA

  • Use vicfg-cfgbackup to save the configuration of a host. This backup can then be used if it is necessary to restore the host at a later point in time.
  • To view the log files of a host, simply point your browser at https://hostname.vmware.com/host
  • To view the datastore files of a host, simply point your browser at https://hostname.vmware.com/folder
  • Us the vCLI command vifs to transfer files to/from ESXi hosts
  • The command esxcli is used for multi-pathing module management
  • It is not possible to have persistent HA logs either by using a datastore or syslog server as they are only stored locally on the server.

http://communities.vmware.com/community/vmtn/vsphere/esxi

Thursday, 17 December 2009

PowerCLI to alter VM BIOS setting



I've been asked by a client how to change the BIOS boot order of a Virtual Machine so that they can PXE boot it first to build it, and then change it to boot from the hard disk afterwards.

So, I've not discovered any information where it is possible to actually change the order of boot devices, but it IS possible to allow/disallow certain devices. So, the code is as follows


Connect-VIServer ipaddress
$spec = New-Object VMware.Vim.VirtualMachineConfigSpec
$spec.extraConfig += New-Object VMware.Vim.OptionValue
$spec.extraConfig[0].key = "bios.bootDeviceClasses"
$spec.extraConfig[0].value = "allow:net"

(get-view (Get-VM -Name "Virtual Machine").ID).ReconfigVM_Task($spec)

Thursday, 3 December 2009

vSphere client crashes with C++ error



If you have installed Converter onto vCenter for vSphere 4, make sure that you don't have the VirtualCenter 2.5 client installed along with the vSphere Client as you will get this c++ error.


I haven't tested it, but http://communities.vmware.com/thread/118140?start=30&tstart=0 states that you can run the two versions if you follow the instructions.

Update Manager Proxy settings



Just discovered something important when you are creating proxy settings in update manager for vSphere 4.

You must make sure that the account you are using for the proxy server

a) exists!!
b) is the service account that Update Manager is running under.