I am Dale Hayter, a Microsoft and VMware certified Technical Consultant.

My blog has been built up over the years from my experience of working on an IT helpdesk and also from being out on-site.

VMware ESX / ESXi Command Line List

Although most of the below have appeared in earlier posts I thought it would be good to list of common ones I use.

List running VM’s on a host

esxcli vm process list

List all the Virtual Machines on a VMware ESXi Host

vm-support -V

List all mounted scsi id’s

esxcfg-scsidevs -m

List all volumes

esxcfg-volume -l

Force mount a volume

esxcfg-volume -M  or 

Find certain words in vmkernel log

grep "vmkernel:" /var/log/messages | grep "keyword"

Find all VMs that have snapshots in ESX

find /vmfs/volumes/ -name "*delta*" -type f -print0 | xargs -0 du --human-readable --total

Find all VMs that have snapshots in ESXi

find /vmfs/volumes/ -name "*delta*" -type f -print0 | xargs -0 du -h

Restart VMware ESX Service Management Agents

service mgmt-vmware restart

Restart VMware ESXi Service Management Agents

/sbin/services.sh restart

List network cards in ESXi

esxcfg-nics -l

List all the vswitches

esxcfg-vswitch -l