Beruflich Dokumente
Kultur Dokumente
Purpose
When performing troubleshooting with ESX storage, you may use command line tools which require you to
identify a specific disk or LUN connected to ESX. This article explores different ways to identify these disks.
Resolution
ESX 3.X
Use these commands to collect disk and LUN information from within ESX.
The command esxcfg-mpath -l generates a compact list of the LUNs currently connected to the
ESX host.
Disk vmhba32:0:0
/vmfs/devices/disks/vml.020000000060060160c0521501065cacf13f9fdd1152414944
2035 (512000MB) has 2 paths and policy of Most Recently Used
iScsi sw iqn.1998-01.com.vmware:esxhost-41e85afe<->iqn.1992-
04.com.iscsi:a0 vmhba32:0:0 Standby preferred
iScsi sw iqn.1998-01.com.vmware:esxhost-41e85afe<->iqn.1992-
04.com.iscsi:b0 vmhba32:1:0 On active
The command esxcfg-vmhbadevs -m generates a compact list of the LUNs currently connected
to the ESX host.
The following are definitions for some of the identifiers and their conventions:
vmhba<Adapter>:<Target>:<LUN>
This identifier can be used to identify either a LUN or a path to the LUN. When ESX detects that
paths associated to one LUN, each path is assigned this identifier. The entire LUN then inherits the
same name as the first path. When using this identifier for an entire LUN, the identified is called the
canonical name. When this identifier is used for a path it is called the path name. These naming
conventions may vary from ESX host to ESX host, and may change if storage hardware
replaced. This identifier is generally used for operations with utilities such as vmkfstools.
This identifier is used in the context of a canonical name and is used to identify a partition on the
LUN or disk. In addition to the canonical name, there is a :<Partition> appended to the end of
the identifier. The <Partition> represents the partition number on the LUN or Disk. If
the <Partition> is specified as 0, then it identifies the entire disk instead of only one partition.
These naming conventions may vary from ESX host to ESX host, and may change if storage
hardware replaced. This identifier is generally used for operations with utilities such as
vmkfstools.
The VML Identifier can be used interchangeably with the canonical name. Appending the
:<Partition> works in the same way described above. This identifier is generally used for
operations with utilities such as vmkfstools.
/dev/sd<Device Letter> or /dev/sd<Device Letter><Partition>
This naming convention is not VMware specific. This convention is used exclusively by the service
console and open source utilities which come with the service console. The <Device Letter>
represents the LUN or Disk and is assigned by the service console during boot. The optional
<Partition> represents the partition on the LUN or disk. These naming conventions may vary
from ESX host to ESX host, and may change if storage hardware replaced. This identifier is
generally used for operations with utilities such as fdisk and dd.
Note: VMware ESXi does not have a service console; disks are refered to by the VML Identifier.
<UUID>
The <UUID> is a unique number assigned to a VMFS volume upon the creation of the volume. It
may be included in syntax where you need to specify the full path of specific files on a datastore.
ESX 4.X
Use these commands to collect disk and LUN information from within ESX:
The command esxcfg-mpath -b generates a compact list of LUNs currently connected to the
ESX host.
mpx.vmhba0:C0:T0:L0
Device Type: Direct-Access
Size: 139890 MB
Display Name: Local ServeRA Disk (mpx.vmhba0:C0:T0:L0)
Plugin: NMP
Console Device: /dev/sdb
Devfs Path: /vmfs/devices/disks/mpx.vmhba0:C0:T0:L0
Vendor: ServeRA Model: 8k-l Mirror Revis: V1.0
SCSI Level: 2 Is Pseudo: false Status: on
Is RDM Capable: false Is Removable: false
Is Local: true
Other Names:
vml.0000000000766d686261303a303a30
The command ls -alh /vmfs/devices/disks lists the possible targets for certain storage
operations.
The following are definitions for some of identifiers and their conventions:
naa.<NAA> or eui.<EUI>
The <Partition> represents the partition number on the LUN or Disk. If the <Partition> is
specified as 0, it identifies the entire disk instead of only one partition. This identifier is generally
used for operations with utilities such as vmkfstools.
Some devices do not provide the NAA number described above. In these circumstances, an MPX
Identifier is generated by ESX to represent the LUN or disk. The identifier takes the form similar to
that of the canonical name of previous versions of ESX with the mpx. prefix. This identifier can be
used in the exact same way as the NAA Identifier described above.
vml.<VML> or vml.<VML>:<Partition>
The VML Identifier can be used interchangeably with the NAA Identifier and the MPX Identifier.
Appending :<Partition> works in the same way described above. This identifier is generally
used for operations with utilities such as vmkfstools.
vmhba<Adapter>:C<Channel>:T<Target>:L<LUN>
This identifier is now used exclusively to identify a path to the LUN. When ESX detects that paths
associated to one LUN, each path is assigned this Path Identifier. The LUN also inherits the same
name as the first path, but it is now used an a Runtime Name, and not used as readily as the above
mentioned identifiers as it may be different depending on the host you are using. This identifier is
generally used for operations with utilities such as vmkfstools.
This naming convention is not VMware specific. This convention is used exclusively by the service
console and open source utilities which come with the service console. The <Device Letter>
represents the LUN or Disk and is assigned by the service console during boot. The optional
<Partition> represents the partition on the LUN or disk. These naming conventions may vary
from ESX host to ESX host and may change if storage hardware replaced. This identifier is
generally used for operations with utilities such as fdisk and dd.
Note: VMware ESXi does not have a service console; disks are referred to by the VML Identifier.