vSphere Troubleshooting Series: Part 2 – vSphere Troubleshooting Tools

Before you can troubleshoot issues, you need to understand the various tools that are out there. In this section, we will discuss some of the tools that VMware provides and how to identify the log locations for additional troubleshooting.

VMware Command Line Tools

You can run command-line tools on an ESXi host in several ways:

  • The vSphere ESXi shell itself, which includes:
    • esxcli commands (esxcli network, esxcli storage, esxcli vm, etc)
    • A set of esxcfg-* commands: The esxcfg commands are deprecated but you will likely still see some older documentation with them. The recommendation today is to use esxcli.
    • The host shell can be accessed a couple of different ways, either by using the local DCUI (Direct Console User Interface) or via SSH.
      • Local access by using the Direct Console User Interface (DCUI):
        1. Enable the vSphere ESXi Shell service, either in the DCUI or vSphere Web Client. Typically, this is running by default.
        2. Access the ESXi Shell from the DCUI by pressing Alt-F1 after logging in.
        3. When finished, disable the ESXi Shell service when not using it.
      • Remote access by using PuTTY or an SSH client.
        1. Enable the SSH service on your ESXi host, either in the DCUI or through the vSphere Web Client.
        2. Use PuTTY or your preferred SSH Client to access the ESXi host.
        3. Disable the SSH Service when finished.
  • vSphere Management Assistant (This tool has been deprecated. 6.5 is final release):
    • A virtual appliance that includes components for running vSphere commands:
    • esxcli
    • vmware-cmd
    • vicfg-* commands
    • vi-fastpass authentication components for automated authentication to vCenter or ESXi hosts. This saves you from having to type your name and password with every command that is ran.
  • VMware PowerCLI:
    • VMware PowerCLI provides an easy-to-use Windows PowerShell interface for command-line access to administration tasks or for creating executable scripts.

VMware Log Locations for Troubleshooting

VMware stores logs for their products in various locations. It’s important to know where to look when you’re having problems quickly and efficiently.

  • vCenter Log Locations:
    • Location for vCenter Server on Windows 2008/2012:
      • %ALLUSERSPROFILE%\VMWare\vCenterServer\logs
    • Location for VMware vCenter Server Appliance:
      • /var/log/vmware/
        • Includes logs for SSO, Inventory Service and the Web Client.
      • Useful ESXi Host Logs:
        • log: Host management service logs.
        • log: Service initialization, watchdogs, scheduled tasks, DCUI.
        • log: Core VMkernel logs. Storage and Networking device events.
        • log: Warning and alert log messages.
        • log: ESXi host startup and shutdown, uptime details, resource consumption.
      • vCenter vpxd.log
        • This log file is the main vCenter Server log file. If you ever contact VMware for support, it is highly likely that they will ask you for this file. Don’t confuse this with vpxa, that is the vCenter agent and runs on the ESXi hosts.
        • You can monitor and view the logs easily through the vSphere Web Client, under the Monitor tab (Figure 1), with an SSH session at /var/log (Figure 2) or in the DCUI under “View System Logs” under System Customization (Figure 3).

The vSphere Syslog Collector

You can gather logs at the above locations or setup a single location for all of your ESXi hosts to point to. It uses port 514 for TCP and UDP, and port 1514 for SSL. The Syslog collector is installed on both the Windows based vCenter and the vCenter Appliance.

The vm-support Command

In addition to the Syslog Collector, you can also gather logs with the vm-support command. It collects data from the ESXi hosts and compresses the following data:

  • Log files
  • System status
  • Configuration files

The tool does not require any arguments and it create a zip file using the host name and time stamp.

The vCenter Bash Shell

You can also use the vCenter Bash Shell from the vCenter Appliance console under troubleshooting options. From the Bash shell, you can verify the status of a service and start or restart services.

Part 3 of this troubleshooting series can be found here: http://www.ryanbirk.com/vsphere-troubleshooting-series-part-3-vsphere-installation-troubleshooting/

This entry was posted in Troubleshooting, vSphere. Bookmark the permalink.

One Response to vSphere Troubleshooting Series: Part 2 – vSphere Troubleshooting Tools

  1. Pingback: vSphere Troubleshooting Series: Part 1 – Introduction | Ryan Birk – Virtual Insanity

Leave a Reply

Your email address will not be published. Required fields are marked *