vmware

Best Practices and URL’s

Posted on Updated on

Here’s a great check list that I came across today…  Enjoy!

Component Check (per Best Practice)

Host Verify equipment was burned in with memory test for at least 72 hours

Host Verify all host hardware is on the VMware Hardware Compatibility List (HCL)

Host Verify all host hardware meets minimum supported configuration

Host Check CPU compatibility for vMotion and FT

Host Check ESX/ESXi host physical CPU utilization to make sure that it is not saturated or running in a sustained high utilization

Host Verify all hosts in the cluster are compatible versions of ESX/ESXi

Host Check ESX/ESXi host active Swap In/Out rate to make sure that it is not consistently greater than 0

Host Check to make sure that there is sufficient service console memory (max is 800MB)

Host Verify that ESX service console root file system is not getting full

Host Check if any 3rd party agents are running in the ESX service console

Host Verify that NTP is used for time synchronization

Network Verify that networking in configured consistently across all hosts in a cluster

Network Check to make sure there is redundancy in networking paths and components to avoid single points of failure (e.g. at least 2 paths to each network)

Network If HA is being used, check that physical switches that support PortFast (or equivalent) have PortFast enabled

Network Check that NICs for the same uplink have same speeds and duplex settings

Network Check that Management/Service Console, Vmkernel, and VM traffic is separated (physical or logical using VLANs)

Network Verify that portgroup security settings for ForgedTransmits and MACAddressChanges are set to Reject

Network Check the virtual switch portgroup failover policy for appropriate active and standby NICs for failover

Network Verify that VMotion and FT traffic is on at least a 1 Gb network

Network Check that IP storage traffic is physically separate to prevent sharing network bandwidth

Storage Verify that VMs are on a shared datastore

Storage Check that datastores are masked/zoned to the appropriate hosts in a cluster

Storage Check that datastores are consistently accessible from all hosts in a cluster

Storage Check that the appropriate storage policy is used for the storage array (MRU, Fixed, RR)

Storage Check to make sure there is redundancy in storage paths and components to avoid single point of failure (e.g. at least 2 paths to each datastore)

Storage Check that datastores are not getting full

Virtual Datacenter Check that all datacenter objects use a consistent naming convention

Virtual Datacenter Verify that hosts within a cluster maintain a compatible and homogeneous (CPU/mem) to support the required functionality for DRS, DPM, HA, and VMotion

Virtual Datacenter Check that FT primaries are distributed on multiple hosts since FT logging is asymmetric

Virtual Datacenter Verify that hosts for FT are FT compatible

Virtual Datacenter Check that reservations/limits are used selectively on VMs that need it and are not set to extreme values

Virtual Datacenter Check that vCenter Server is not running other applications and vCenter add-ons (for large environments and heavily loaded vCenter systems) and is sized appropriately

Virtual Datacenter Check that the DB log setting is Normal unless there is a specific reason to set it to High

Virtual Datacenter Check that the vCenter statistics level is set to an appropriate level (1 or 2 recommended)

Virtual Datacenter Check that appropriate vCenter roles, groups, and permissions are being used

VM Check any VMs with CPU READY over 2000 ms

VM Check any VMs with sustained high CPU utilization

VM Check any VMs with incorrect OS type in the VM configuration compared to the guest OS

VM Check any VMs with multiple vCPUs to make sure the applications are not single threaded

VM Check the active Swap In/Out rate of VMs to make sure it is not consistently greater than 0

VM Check that NTP, windows time service, or another timekeeping utility suitable for the OS is used (and not VMware Tools)

VM Check that VMware Tools are installed, running, and not out of date for running VMs

VM Check VMs that are configured and enabled with unnecessary virtual hardware devices (floppy, serial, parallel, CDROM) and any devices that prevent VMotion

VM Check VMs that are not yet on virtual hardware v7

VM Check VM configuration (memory reservation) for VMs running JVM to consider setting reservation to the size of OS+ java heap

Item URL

Documentation http://www.vmware.com/support/pubs

VMTN Technology information http://www.vmware.com/vcommunity/technology

VMTN Knowledge Base http://kb.vmware.com

Discussion forums http://www.vmware.com/community

User groups http://www.vmware.com/vcommunity/usergroups.html

Online support http://www.vmware.com/support

Telephone support http://www.vmware.com/support/phone_support.html

Education Services http://mylearn.vmware.com/mgrreg/index.cfm

Certification http://mylearn.vmware.com/portals/certification/

Technical Papers http://www.vmware.com/vmtn/resources

Network throughput between virtual machines http://kb.vmware.com/kb/1428

Detailed explanation of VMotion considerations http://www.vmware.com/resources/techresources/1022

Time keeping in virtual machines http://www.vmware.com/vmtn/resources/238

http://kb.vmware.com/kb/1006427

VMFS partitions http://www.vmware.com/vmtn/resources/608

VI3 802.1Q VLAN Solutions http://www.vmware.com/pdf/esx3_vlan_wp.pdf

VMware Virtual Networking Concepts http://www.vmware.com/resources/techresources/997

Using EMC Celerra IP Storage (VI3 http://www.vmware.com/resources/techresources/1036

VMware vCenter Update Manager documentation http://www.vmware.com/support/pubs/vum_pubs.html

VMware vCenter Update Manager Best Practices http://www.vmware.com/resources/techresources/10022

Performance Best Practices for VMware vSphere 4.0 http://www.vmware.com/resources/techresources/10041

Recommendations for aligning VMFS partitions http://www.vmware.com/vmtn/resources/608

Performance Troubleshooting for VMware vSphere http://communities.vmware.com/docs/DOC-10352

Large Page Performance http://www.vmware.com/resources/techresources/1039

VMware vSphere PowerCLI http://www.vmware.com/support/developer/windowstoolkit/

VI3 security hardening http://www.vmware.com/vmtn/resources/726

VMware HA: Concepts and Best Practices http://www.vmware.com/resources/techresources/402

Java in Virtual Machine on ESX http://www.vmware.com/files/pdf/Java_in_Virtual_Machines_on_ESX-FINAL-Jan-15-2009.pdf

CPU scheduler in ESX 4.0 http://www.vmware.com/resources/techresources/10059

Dynamic Storage Provisioning (Thin Provisioning) http://www.vmware.com/resources/techresources/10073

Understanding memory resource management on ESX http://www.vmware.com/resources/techresources/10062

ESX 4 – Windows 7 VM cannot connect via RDP

Posted on Updated on

Today I noticed when rebooting my Windows 7 VM under ESX 4 remote desktop would not allow connections until I logged on locally.

I also noticed vCenter Server reported VMTools wasn’t running.

 

I did a bit of research and found that Remote Desktop Services was in manual mode.
By changing the startup type to Automatic it not only fixed the Remote Desktop issue but vCenter Server reported in properly as well.

ESX 3.5 – Network DNS Settings

Posted on Updated on

Here’s the quick way to see your DNS settings from command line..

cat /etc/resolv.conf

ESX 3.5 – Keyboard Issues displaying wrong characters

Posted on Updated on

I ran into an issue getting an ESX 3.5 server to join a Virtual Center 2.5 server today..

For some reason I couldn’t get it to join my VC server and when I tried to I would get the error bad password or user name. Connecting the VI client straight to the server failed, trying to use the web interface failed, but I could remote into the server via an IP KVM and log on without issue.

What I found was my keyboard map on this individual server was set to UK and not US.

Here is how I resolved this issue.

Logged in to the host as root

cd /etc/sysconfig
vi keyboard
Press esc twice
Press insert to edit
Changed KEYTABLE=”uk″ to KEYTABLE=”us″
Press esc twice
Enter :qw > to save the file and exit
Reboot the ESX server
And now it works like a champ..

Book – VMware vSphere 4.0 Quickstart Guide

Posted on Updated on

I bought this book today… based on some blog posts I found (see below).
I must say it is one of the best.. It is a pocket reference so be aware the print is a bit small…

Download the Power-CLI Scripts from the book here…
http://www.yellow-bricks.com/wp-content/uploads/quickstartguide.zip

Here are some notes about the book.. From this URL…
http://www.boche.net/blog/index.php/2009/11/23/vsphere-4-0-quick-start-guide-released-on-amazon/

What a great way to kick off the new week – The highly anticipated book, vSphere 4.0 Quick Start Guide: Shortcuts down the path of Virtualization, has arrived at Amazon.com! I look at this new release as the 2nd edition or vSphere edition of RapidApp’s Quick Start Guide to ESX 3.0 which is still available and was a huge success.

The vSphere 4.0 Quick Start Guide was written by a lineup of new authors who are well known rock stars in the virtualization community: Bernie Baker, Thomas Bryant, Duncan Epping, Dave Mischenko, Stewart Radnidge, and Alan Renouf. I obtained a preview copy of this book at VMworld 2009 in San Francisco and I can tell you that this it is absolutely amazing. Nowhere else will you find as much information in such a small and convenient footprint. Its small size allows you to put it in your pocket and take it virtually anywhere: On the plane, on the bus, into a meeting, or into the datacenter. As with the first edition, there are several blank pages in this book which allow you space to write down notes, command line information, configuration maximum changes, information about your environment, helpful URLs, etc. The authors did a great job on this book and considering the cumulative years of experience and combined expertise packed into this book, you can’t beat the price. I don’t think a better value exists. My copy has been traveling with me daily in my laptop bag. I give it two thumbs up.

ESX 3.5 – 5 critical vmware esx cli network commands

Posted on Updated on

I found this really cool article today… It’s not my work, but it is a great reference…

http://www.petri.co.il/5-critical-vmware-esx-cli-network-commands.htm

5 Critical VMware ESX CLI Network Troubleshooting Commands
by David Davis, vExpert, VCP, CCIE 9369 – December 23, 2008

Have you ever made a change to your VMware ESX Server Network configuration using the Virtual Infrastructure (VI) Client and then lost communications with the server? If you had to go to the ESX Service console to troubleshoot the virtual network configuration, would you know the commands to do it? In this article, you will learn the 5 most critical ESX CLI commands you need to know to troubleshoot networking issues.
#1) service network restart
The service X restart command is an excellent command that allows you to restart any service running on your ESX Server. In our case, we are using the network keyword to restart network services. This is the command you should run after making changes to your ESX networking configuration. You can also do network start or network stop. This brings down all network interfaces, then brings up the interfaces configured to start at boot.

#2) ifconfig
The second command is ifconfig. Similar to the Windows command, ipconfig, this command is used to view the status of all network interfaces on the system. However, it can do a lot more than just view an interface, it can reconfigure interfaces, bring them down, or back up. You can change the IP address of your interfaces with ifconfig.

#3) esxcfg-vswif
Next, we have the ESX command that allows you to view the status of or reconfigure the VMware Service console network interface. That SC network interface is called “vswif” and the first interface is always “vwsif0”. To view the status of it, you can use the -l (L for list)
#4) esxcfg-vswitch
The fourth command on the list is the esxcfg-vswitch command. This command is used to view the status of or reconfigure the VMware virtual switches (called vswitch). These vswitches are used to connect the physical NIC in the server (called vmnic) to the ESX port groups (such as the “Service Console” and the “VM Network” port groups). To view the status of your vswitches, you can use the -l (L for list) command, like this:

#5) esxcfg-nics
Lastly, we have the esxcfg-nics command. This command is used to view the status of or reconfigure the VMware Physical Network interface cards that are installed in the physical server. These physical NICs are called “vmnic” and they start with “vmnic0”. The vmnics are connected to vswitches to connect the physical network to the virtual networks.
To view the status of your vmnics, you can use the -l (L for list) command,
Summary
Believe me, there was a time that I was stuck at the ESX service console interface, trying to resolve a networking issues, and struggling to find the right commands to do it. I hope that you will save this URL or print this article to keep it handy the next time you are in a similar situation because that know that these 5 commands can help you get out of any VMware ESX Server networking configuration or troubleshooting issue.

ESX 3.5 – Change the default gateway

Posted on Updated on

From the command prompt enter
Netstat –nr — this Command will help you to id the actual gateway address

You now need to change your default gateway, you can do this by editing the network file located at /etc/sysconfig/network. To do this at the command prompt, follow the steps below.

“cd /etc/sysconfig”
“vi network”

Then while in vi, go to the location of the default gateway using the arrow keys.
Hit “i” which will perform an insert and change the default gateway to your liking.
Hit the escape key twice to exit insert mode.
type “:wq” to write (i.e save) and quit.

ESX 3.5 – Remove a PortGroup

Posted on Updated on

During the graphical installation of ESX 3.5 there is a single checkbox that states “Create Network for Virtual Machines” Usually I uncheck this box and create a new vSwitch for VM’s

However, if you don’t uncheck this box it will create the portgroup “VM Network” on the same vSwitch as the “Service Console” port group. If you run vCenter Server it’s easy enough to repair, however here is how it’s done from the console level…

Here is how you remove it from command line…

Esxcfg-vswtich –l –Show all the vSwitches and associated portgroups
Esxcfg-vswtich vSwitch0 –D “VM Network” – Actually Removes it

Here is the actual output…

ESX 3.5 – Change a VLAN Tag on a PortGroup

Posted on Updated on

I setup 4 ESX servers the other day and the wrong vlan tag was entered. MyLAN admin is out of the office, so I have two choices… One Bug him like crazy (Calls and Emails) or two wait till he returns to change the VLAN tag
I like Option 3 – Change the VLAN tag myself…
I found this here and it work perfectly…
http://www.geekshangout.com/?q=node/17

Check which vSwitch the Service Console is on (and the name of the Service Console) with esxcfg-vswitch -l
To remove the vlan id completely, just set it to 0 (in case you have set it by accident on an access port)
esxcfg-vswitch vSwitch0 -v 0 -p “Service Console”
To set a vlan id on the service console (in case you forgot to define this during the installation)
esxcfg-vswitch vSwitch0 -v X -p “Service Console” (enter the vlan number where X is)

Here is my actual output (VLAN tags have been changed to protect the innocent!)

ESX 3.5 – NTP Time Server Restart

Posted on Updated on

I found the following commands to work really well when you need to restart your NTP sevice on your ESX server.

Logon to the console level..

Commands >> Effect
# service ntpd restart >> Restart the service.
# chkconfig –level 345 ntpd on >> Enable the NTP daemon to autostart when the server is rebooted.
# hwclock –systohc >> Set the local hardware clock to the NTP synchronized local system time.

#hwclock –show {Press Enter} << Shows you the current clock
Fri 23 Apr 2010 08:17:41 AM MST -0.989683 seconds