Translate Veritas disk id to EMC lun number. - Veritas Volume Manager

This is a discussion on Translate Veritas disk id to EMC lun number. - Veritas Volume Manager ; Hi All, Can anyone tell me how I can tell a LUN id number from the output of a 'vxdisk list' command? Thanks, Mark...

+ Reply to Thread
Results 1 to 3 of 3

Thread: Translate Veritas disk id to EMC lun number.

  1. Translate Veritas disk id to EMC lun number.


    Hi All,
    Can anyone tell me how I can tell a LUN id number from the output of a 'vxdisk
    list' command?
    Thanks,
    Mark

  2. Re: Translate Veritas disk id to EMC lun number.

    NO way to do that.

    vxdisk list will list the Disk Access (da) name (or the name of the
    disk in Volume Manager) to a c#t#d# (or to an enclosure-based name)


    What I suspect is that you want to know how the enclosure-based name
    (something like EMC0_1 or EMC0_12) convetrs back to a LUN.


    The reason why enclosure-based names are used, is to make it easy for
    you. The "real" name of the disk always has the form c#t#d# Biggest
    problem is that you will see that the t# will include the 20 character
    WWNN (World Wide Node Number) of the disk. So EMC0_12 might have a
    "real" name like c5t234ed852ab23c423961d0

    This is a bit difficult to manage, but if you want to see the "real"
    names next to the enclosure-based name, do "vxdisk -e list".

    Once you've got the c#t#d#, you will have to use EMC tools to get the
    LUN numbers.

    mark O'L wrote:
    > Hi All,
    > Can anyone tell me how I can tell a LUN id number from the output of a 'vxdisk
    > list' command?
    > Thanks,
    > Mark


  3. Re: Translate Veritas disk id to EMC lun number.


    Try this

    change the grep to use the ID on your devices...

    HOSTNAME=`uname -n`
    echo ""
    echo "Hostname Logical CU:LDEV Volumes"
    echo "-------- ------- ------- -------"
    USEDDISKS=`vxprint -ht|grep "sd " |grep -v root|grep -v swap|awk '{print
    $8}'|sort|uniq`
    for DISK in $USEDDISKS;do
    CULDEV=`vxdisk list $DISK | grep 7D86 | cut -b32-35`
    CU=`echo $CULDEV|cut -b1-2`
    LDEV=`echo $CULDEV|cut -b3-4`
    VOLLIST=`vxprint -ht|grep $DISK|grep -v "dm " | awk {'print $3'}|cut -d"-"
    -f1`
    for VOL in $VOLLIST;do
    VFSLINE=`egrep "$VOL |$VOL " /etc/vfstab`
    if [ $? -eq 0 ];then
    MNTPT=`echo $VFSLINE |awk '{print $3}'`
    echo "$HOSTNAME $DISK $CU:$LDEV $MNTPT "
    else
    echo "$HOSTNAME $DISK $CU:$LDEV $VOL "
    fi
    done
    done



    Me wrote:
    >NO way to do that.
    >
    >vxdisk list will list the Disk Access (da) name (or the name of the
    >disk in Volume Manager) to a c#t#d# (or to an enclosure-based name)
    >
    >
    >What I suspect is that you want to know how the enclosure-based name
    >(something like EMC0_1 or EMC0_12) convetrs back to a LUN.
    >
    >
    >The reason why enclosure-based names are used, is to make it easy for
    >you. The "real" name of the disk always has the form c#t#d# Biggest
    >problem is that you will see that the t# will include the 20 character
    >WWNN (World Wide Node Number) of the disk. So EMC0_12 might have a
    >"real" name like c5t234ed852ab23c423961d0
    >
    >This is a bit difficult to manage, but if you want to see the "real"
    >names next to the enclosure-based name, do "vxdisk -e list".
    >
    >Once you've got the c#t#d#, you will have to use EMC tools to get the
    >LUN numbers.
    >
    >mark O'L wrote:
    >> Hi All,
    >> Can anyone tell me how I can tell a LUN id number from the output of a

    'vxdisk
    >> list' command?
    >> Thanks,
    >> Mark



+ Reply to Thread