none
Hyper-v Pass-Through Disk LUN number varies inside & outside of VM

    Question

  • Dear Friends,

    Would you please help on below query..

    One of the VM in my Hyper-v2012 R2 environment have multiple Pass-through disk's. LUN number's are showing different. when I check  disk on Hyper-V host where LUN presented and the same disk when I check from Guest OS, LUN number is showing different. Would like to know fundamentals why LUN number is showing different inside Guest and outside(Host) for the same disk. Kindly help me in providing clarifications

    Thanks

    Ram Prasad


    Warm Regards Ram Prasad

    Monday, February 27, 2017 8:30 AM

Answers

  • If you want to expand a LUN, you need to tell your storage people what the LUN  is on the storage array, not what the OS LUN is.  For example, I used to have an EMC VNX in my lab.  I had several physical hosts booting from the VNX.  The VNX defined a new LUN for each new volume I created.  Let's just say these LUNs were 1, 2, 3, and 4.  For each of the four hosts booting from the VNX, each host referenced its LUN as 0.  Masking and zoning was used to associate the host to the LUN(s) it was allowed to use.

    If you have several LUNs in one zone, and all LUNs are the same size and were associated at the same time, it can be a little challenging to determine which LUN on the host is which LUN on the storage array.  Different arrays have different tools.  You will need to work with your storage people to figure things out.

    In the future, you might want to stop using pass-through disks for your VMs.  There are few instances where it makes sense to use pass-through disks within VMs.  You lose some of the capabilities provided by VMs, and you do not gain anything in performance.


    . : | : . : | : . tim

    • Marked as answer by RamPrasad A Thursday, March 02, 2017 4:05 AM
    Wednesday, March 01, 2017 2:05 PM

All replies

  • Different operating system instances.  Each operating system assigns its own LUNs. No reason that two different operating system instances must have the same LUN.

    . : | : . : | : . tim

    Monday, February 27, 2017 1:26 PM
  • Hi Tim,

    Thanks for your response.

    My HOST OS is 2012R2 & Guest OS is 2012 r2, Is  LUN number changes when using Pass-through disk if both OS same. Appreciate if you provide more explanation on this or any relevant KB help's me..


    Warm Regards Ram Prasad

    Tuesday, February 28, 2017 8:45 AM
  • A LUN is assigned by the OS at the time the volume is attached to the OS.  If the volume was attached in a different sequence, the LUN would be different.  It doesn't make any difference what OS is running.

    I am curious why you are concerned about this.  The only LUN that makes a difference for Windows is that the OS must reside on LUN 0.  Otherwise, the LUN makes no difference.

    For example, your host could have 12 different volumes, each assigned to its own unique LUN, and it presents each of these 12 volumes as pass-through disks to 12 different VMs.  Each VM would see its pass-through disk as LUN 1, but the host has LUNs 1 through 12.


    . : | : . : | : . tim


    Tuesday, February 28, 2017 1:43 PM
  • Hi Tim,

    Let me explain in detail with example .. LUN's are coming from FC storage and I have below LUN's on My HOST & VM with same disk size

    On HOST Disk 20 LUN16 800 GB
    On HOST Disk 21 LUN17 800 GB
    On HOST Disk 22 LUN18 800 GB
    On HOST Disk 23 LUN18 800 GB

    Inside VM , below drives are mapped with different LUN numbers

    H Drive-  800 GB -LUN 200
    I Drive-  800 GB -LUN 205
    J Drive-  800 GB -LUN 207
    K Drive-  800 GB -LUN 208

    My application team requested J drive to expand and now the Question is what is the LUN number do I need to share to storage team to expand LUN and how can I correlate both. Hope you got my query and requirement..


    Warm Regards Ram Prasad

    Wednesday, March 01, 2017 6:18 AM
  • If you want to expand a LUN, you need to tell your storage people what the LUN  is on the storage array, not what the OS LUN is.  For example, I used to have an EMC VNX in my lab.  I had several physical hosts booting from the VNX.  The VNX defined a new LUN for each new volume I created.  Let's just say these LUNs were 1, 2, 3, and 4.  For each of the four hosts booting from the VNX, each host referenced its LUN as 0.  Masking and zoning was used to associate the host to the LUN(s) it was allowed to use.

    If you have several LUNs in one zone, and all LUNs are the same size and were associated at the same time, it can be a little challenging to determine which LUN on the host is which LUN on the storage array.  Different arrays have different tools.  You will need to work with your storage people to figure things out.

    In the future, you might want to stop using pass-through disks for your VMs.  There are few instances where it makes sense to use pass-through disks within VMs.  You lose some of the capabilities provided by VMs, and you do not gain anything in performance.


    . : | : . : | : . tim

    • Marked as answer by RamPrasad A Thursday, March 02, 2017 4:05 AM
    Wednesday, March 01, 2017 2:05 PM
  • Many Thanks Tim for your clarification. I will check with my storage team..

    Warm Regards Ram Prasad

    • Marked as answer by RamPrasad A Thursday, March 02, 2017 4:05 AM
    • Unmarked as answer by RamPrasad A Thursday, March 02, 2017 4:05 AM
    Thursday, March 02, 2017 4:05 AM