VMware

This Question is Answered

1 "helpful" answer available (6 pts)
12 Replies Last post: Aug 16, 2008 2:52 AM by snapper  

Matching VMFS volumes between a ESX 3.5 host and a VCB proxy posted: Aug 7, 2008 6:25 AM

Click to view TiJa's profile Enthusiast 48 posts since
Oct 6, 2006
Hi all,

I am trying to find a way to match the SAN LUNs that have been presented to a VCB proxy server in our VI 3.5 environment with the LUN ID's/VMFS ID's I can see in the service console of our ESX 3.5U2 hosts. However, I see some discrepancies that I cannot explain with my (limited) knowledge of VMFS.

On the ESX 3.5 hosts, I log onto the service console and issue the following commands to obtain the VMFS ID's:
ls -al /vmfs/volumes
esxcfg-vmhbadevs -m
The results are (obviously) consistent and the ID's I obtain are the following:
(A) vmhba1:4:1:1 /dev/sdc1 483cf914-29b60dc5-dbfd-001cc497e630
(B) vmhba1:0:2:1 /dev/sdb1 48858dc4-f4e218d1-d3a8-001cc497e630
I added the letters for later reference. The next step is to go to our VCB proxy server which runs a Windows 2003 Enterprise Edition. This is a physical machine that has the same LUN's & some additional LUN's from other ESX servers presented and has the latest VCB 1.5 installed. Here, I use the vcbSanDbg.exe command to discover the VMFS volumes that are presented to that host (the exact command is vcbSanDbg.exe | findstr "ID" ). The output is the following:
(1) info ID: LVID:48761b97-dacedf9f-ebb9-0017085d0f91/48761b97-a4f562bd-6875-0017085d0f91/1 Name: 48761b97-a4f562bd-6875-0017085d
(2) info ID: LVID:48761bc6-7b4afa63-97d9-0017085d0f91/48761bc5-3f508baa-2f5d-0017085d0f91/1 Name: 48761bc5-3f508baa-2f5d-0017085d
(3) info ID: LVID:483cf913-458f9fa5-a749-001cc497e630/483cf913-05b4f526-45b5-001cc497e630/1 Name: 483cf913-05b4f526-45b5-001cc497
(4) info ID: LVID:479da7b6-877867e9-dd06-001cc497e630/479da7ac-55fe7dfe-378c-001cc497e630/1 Name: 479da7ac-55fe7dfe-378c-001cc497
(5) info ID: LVID:477c2b4a-969e01e0-8d49-001cc495fb46/477c2b4a-7db36616-30ea-001cc495fb46/1 Name: 477c2b4a-7db36616-30ea-001cc495
(6) info ID: LVID:48843bec-28cc17a4-ca9e-001cc495fb46/48843bec-154cf784-871a-001cc495fb46/1 Name: 48843bec-154cf784-871a-001cc495
The problem is linking the two outputs; as you can see, the VMFS ID's are not entirely the same, but there is some resemblance:

(A) vmhba1:4:1:1 483cf914-29b60dc5-dbfd-001cc497e630 is more or less (2) LVID:xyz / 483cf913-05b4f526-45b5-001cc497e630 / 1
(B) vmhba1:4:2:1 479da7c1-4494cd90-d327-001cc497e630 is more or less (4) LVID: xyz / 479da7ac-55fe7dfe-378c-001cc497e630 / 1

Is this just a pure coincidence? Am I missing something, and in that case, is there some other way of retrieving the VMFS ID's of LUNs presented to a Windows host?

Thanks for any help!


Tim

Click to view kjb007's profile Guru 5,486 posts since
Sep 18, 2006

Are you sure you've presented to vcb the same LUN ID's as the ESX host sees?

-KjB

Click to view kjb007's profile Guru 5,486 posts since
Sep 18, 2006

I have seen these configs fail when the Lun ID's are not the same, so I would venture that this is the first check. If this is correct, then the process continues.

Not much more help to you, but the Lun IDs matching is the very start of the entire process.

-KjB

Click to view seniord's profile Enthusiast 80 posts since
Apr 13, 2007
Try running the VCB Diagnostic Tool; http://www.vmware.com/download/eula/vcbsdt_eula.html. You can also see the LUN IDs in Windows Disk Managment.

Message was edited by: seniord

Sorry - read your message too quickly, notice you have already used this tool.
Click to view Steven Rodenburg's profile Enthusiast 124 posts since
Sep 28, 2005

I'd say the cause of the discrepancy's is that the ESX servers and the VCB Windows server have a completely different take on thing as soon as you get higher than the fundamental building-blocks of a FC or iSCSI SAN.
They "happen" to be able to see the same LUN's because the SAN administrator has set the FC zoning to enable that (which of course, is the correct way) for example.

However, the Windows VCB box and the ESX boxes see, fundamentaly speaking, only the same WWN's (or in iSCSI land, the IQN's).
That is all they have incommon. How the ESX and Windows boxes present those LUN's to their user-interfaces is a whole different matter.

So all you have to go on is WWN's or IQN's as long as the VCB box does not ask anyone in the ESX/VI world what VMFS volume name an ESX box uses (the long names under /vmfs/volumes ). The VCB box would need to know how the ESX boxes translate LUN's from the lowest levels to the name you see in the Service Console under /vmfs/volumes.
For that the VCB box should ask that question to VC which in turn, askes that question to ESX and so on.

Click to view dconvery's profile Virtuoso 1,888 posts since
May 10, 2006

I belive that part of the "LVID" in Windows is based on the switch port WWN/ switch node WWN depending on zoning method.

Dave

Click to view snapper's profile Enthusiast 52 posts since
Sep 19, 2004

I could be mistaken, but this is the process I use, that has worked reliably between our VCB host and ESX server.

Step 1. Find the correct LUN mappings on ESX hosts by running the following command:
esxcfg-mpath -lv | grep ^Disk | awk '{print $3,$5,$2}' | while read line; do echo ${line:14:32}; echo ${line}; done

This will display a list of UID and corresponding devices (which you can get the LUN from; ie vmhba1:0:5 is LUN 5)

The important part is the 32 digit number. Use this to locate the corresponding device from the output of vcbsandbg.exe

ie, vcbsandbg.exe > c:\LUNs.log

Open LUNs.log and search for the above 32 digit number. If the LUN is present, it should appear in the form of:

Found SCSI Device: NAA:<number>
the following line should display the number of paths it is present on. The line after will display the CTL which will display the LUN.

You now have a way of matching LUNs and disk presentations between ESX and VCB. This will include RDMs as well.

Hope this helps resolve the issue.

Cheers,
SP


Click to view snapper's profile Enthusiast 52 posts since
Sep 19, 2004
Cool - glad it helped. I actually use a slight more lengthy process, one that links all the important details together.

ie, LUN, Controller,NAA,size,free space, and the VMFS friendly name or RDM.
I use a modified version of the ESX health check (http://sourceforge.net/projects/esxhealthscript) to generate this on a nightly cron and ftp the html output to an internal website.
This way external people (ie, the SAN guys) can see important LUN information, verify their presentations (using the NAA / vdisk UID) etc and see our VMFS friendly name to link it all together.Oh, and for checking the VCB LUNs as well.

Script is now attached. Simply make it executable by chmod +x <filename> and execute ./getluns.sh

Should return something similar to:
LUN,VMFS_name,Device,HBA,Target,DiskID,Size,Used,Free,Used%
5,DDC1_PAT_HDS_05,/dev/sdf,vmhba1,0,60560768023e01e8f80000000000002d,449G,362G,87G,80%


ps. The shortened version you posted above can be modified to include the full disk ID:

esxcfg-mpath -lv | grep ^Disk | awk '{print $3,$5,$2}' | cut -c15-46,59-
Cheers,
SP

Don't forget to award points where appropriate :)

Message was edited by: snapper

Attachments:

VMware Developer

SDKs, APIs, Videos, Learn and much more in the Developer community.

Learn More

Developer Sample Code

Increase your developer productivity with VMware API sample code.

Learn More

VMworld Sessions & Labs

Online access to the latest VMworld Sessions & Labs and online services.

Learn more

Purchase PSO Credits Online

Purchase credits to redeem training and consulting services online.

Buy Now

Community Hardware Software

View reported configurations or report your own.

Learn More

VMware vSphere

Come witness the next giant leap in virtualization.

Register Today

Communities