New Virtualisation Website Launched!

Hi All, I have just launched my new website http://www.elasticsky.co.uk
Lots of info on the VCP, practice exam questions, video demos, and more to be added.
Please check it out!

Add static route to VMware ESX 4 Host

23 June 2010
by Paul McSharry

In a infrastructure with multiple networks,  it can be necessary to configure the routing on the ESX hosts rather than at the router.

This is  achieved using the below command

route add – net <network ID > netmask <subnet mask> gw <gateway interface>

ie :   route add -net 10.44.0.0 netmask 255.255.0.0 gw 192.168.0.12

In the above example,  all traffic for the 10.14.X.X network will be routed via 192.168.0.12

Note:  This route will not be persistent through reboots.  If the ESX host is restarted the route will need to be re-added. 

To ensure the route is persistent add the command to the bottom of the following config  file using a text editor /etc/rc.local

For example

Change directory  –  cd /etc/
Open Text Editor – nano rc.local
Specfiy the route at the end of the file  -
route add -net 10.44.0.0 netmask 255.255.0.0 gw 192.168.0.12 
Exit Text Editor  - ctrl -x , Yes to confirm

Enable the Root user SSH access in vSphere ESX 4

20 June 2010
by Paul McSharry

As a security meaure,  SSH access to the service console  using the Root account is disabled by default on vSPhere ESX 4.   Although not best practice,  there are times you may wish to enable access to the Root user.

Method – CLI commands show in bold

  1. Login as Root to the ESX console
  2. Go to the SSH directory  –  cd /etc/ssh
  3. Open the ssh_config  file –  nano sshd_config
  4. Change PermitRootLogin no  to PermitRootLogin yes
  5. Save and exit the config file   – CTRL+ X , click Y to confirm
  6. Restart the SSHD service  – service sshd restart
  7. Amend the service console firewall rules -   esxcfg-firewall -e sshClient and esxcfg-firewall -e sshServer

The Root account should now be able to connect remotely using SSH

Please note, this applies to ESX only,  ESXi does not have a Service Console.   Access is provided using the remote command line interface or pearl toolkit.  SSH access can be configured to the  support mode, however it is enabled in a different manner.

Inconsistent Virtual Machine folders after renaming a machine.

25 May 2010
by Paul McSharry

When a virtual machine is renamed ,  the underlying datastore folder is unchanged.    This can cause confusion in various scenarios.

To overcome this quickly and easily,  simply migrate the virtual machine datastore using storage vmotion.  During the process the virtual machine files are renamed automatically.