AIX mount points physical disks

Posted on 2011-10-06
Last Modified: 2012-05-12
we have these mountpoints

/dev/oraclelv01     33.62     11.24   67%    74222     3% /ora01
/dev/oraclelv02     33.69     31.97    6%       21     1% /ora02
/dev/oraclelv03     67.88     62.31    9%       19     1% /ora03
/dev/oraclelv04     67.81     62.18    9%      317     1% /ora04
/dev/oraclelv05     33.88     32.88    3%       20     1% /ora05
/dev/oraclelv06     33.88     33.13    3%       17     1% /ora06
/dev/oraclelv07     67.81     64.89    5%       22     1% /ora07
/dev/oraclelv08     67.75     59.06   13%      103     1% /ora08

we want to know which ones are on physically separate disks? this AIX
Question by:it-rex
    LVL 14

    Assisted Solution

    lslv ...      Lists information about the logical volumes.
    lspv ...      Lists physical volume details

    lslv  -l  /dev/oraclelv01  
    LVL 68

    Accepted Solution



    lslv -l oraclelv01
    lslv -l oraclelv02

    You will see the physical disk(s) each logical volume is on.

    You can also issue

    lspv -l hdiskx

    to see which LVs are occupying a given physical disk.

    Or find out the name of the volume group where all these volumes are in (lslv oraclelv01 etc.)

    and issue

    lsvg -M vgname

    to see physical volume/logical volume relationship per physical partition (the smallest allocation unit of an LV).

    By the way, this Q is closely related to AIX. Why didn't you ask it in that zone?
    I'm aware that the question wizard doesn't suggest the AIX zone.
    A workaround is to visit the zone and click "Ask a new question" there.


    LVL 11

    Author Comment

    but we are concerned about how the disks
    hdisk* were created on the SAN side .
    my understanding is that these hdisk* tht composes these lv's and VG's could be from 1 or more physical splinders on the SAN storage.

    please advise.
    LVL 68

    Expert Comment

    It's not possible to find get this info using AIX commands.

    You must find out the LUN ID of the hdisk in question with

    lscfg -l hdiskx

    and use this LUN ID on your SAN box to get allocation details.

    Which SAN storage hardware do you use?

    If in doubt please post the output of the above command, I think I will be able to assist you finding out the LUN ID.
    LVL 68

    Expert Comment

    A more straightforward way to find the LUN ID:

    lsattr -HE -a lun_id -l hdiskx
    LVL 6

    Expert Comment

       Unless there's another ID that Z1(via lscfg) represents, these don't match for us.

    lsattr returns "30"
    lscfg retruns "3B", which is what our Storage team sees as the LDEV ID on the SAN.

    The "30" appears to come from the "L#" in the physical location field.
    I'm guessing this may vary by SAN Vendor.

    On one of our VIO servers:

    # lsattr -HE -a lun_id -l hdisk33
    attribute value           description            user_settable

    lun_id    0x3000000000000 Logical Unit Number ID False
    # lscfg -vl hdisk33
      hdisk33          U78A5.001.WIH6507-P1-C12-T1-W50060E80100542DD-L3000000000000  Hitachi Disk Array (Fibre)

            Machine Type and Model......DF600F
            Part Number.................
            ROS Level and ID............30303030
            Serial Number...............87011549
            EC Level....................
            FRU Number..................1549
            Device Specific.(Z0)........00000432B3001102
            Device Specific.(Z1)........003B
            Device Specific.(Z2).........
            Device Specific.(Z3).........
            Device Specific.(Z4)........2...
            Device Specific.(Z5)........
            Device Specific.(Z6)........
    LVL 68

    Expert Comment


    the LUN ID of your disk is definitely "30", as returned by lsattr.

    lscfg returns this ID as well, see the "-L30..." part in the location data.

    The "Z1" value seems to be a particularity of HDS.

    It could well be that HDLM would update this field with information obtained directly from the SAN box.

    The IBM DS8000 constructs the LUN IDs passed to AIX according to this pattern:

    "40"[left 2 digiits of volid]"40"[right two digits of volid]

    That's why I asked for the particular SAN storage type (and implicitly for the driver used).
    Taking this info along with "lscfg" we could perhaps advance a bit further.


    LVL 11

    Author Comment

    lsattr -HE -a lun_id -l hdisk4


    lsattr: 0514-528 The "lun_id" attribute does not exist in the predefined
            device configuration database.
    LVL 6

    Expert Comment

    are you on an LPAR running behind a vio server?
    If so, you'll have to look at the disks from the VIO server

    LVL 11

    Author Comment

    we are using VIO yes
    what to do?
    LVL 6

    Assisted Solution

    Well,  this takes a few steps, and not being there, you're going to have to interpret some..

    On the lpar we've been working with, run the following comand
    * lscfg|grep hdisk
       the output will look similar to:
    * hdisk3           U9117.MMA.1067AF5-V54-C149-T1-L8400000000000000  Virtual SCSI Disk Drive

    Make a note of the "C149" value on your system whatever it shows up

    * log in to your vio server as padmin.
    * run "lsmap -all | grep C149"
    You may get multiple lines, find the exact match --- output will look like:

    $ lsmap -all|grep C149
    vhost49         U9117.MMA.1067AF5-V1-C149                    0x00000036

    NOTE the vhost#

    * Run the following command:
    lsmap -vadapter vhost49       (obviously substituting your vhost#)

    YOu'll be looking for the "backing device"   --- here's an example:

    $ lsmap -vadapter vhost49
    SVSA            Physloc                                      Client Partition ID
    --------------- -------------------------------------------- ------------------
    vhost49         U9117.MMA.1067AF5-V1-C149                    0x00000036

    VTD                   unx302vs03
    Status                Available
    LUN                   0x8300000000000000
    Backing device        rvg302lv02

    VTD                   unx302vs04
    Status                Available
    LUN                   0x8400000000000000
    Backing device        hdisk100

    You can see we have 2 "luns" on this lpar (at least from this vio server, it is possible to have multiple results

    The first backing device is a logical volume within a VG on the vio server.
    The second backing device is a lun the VIO server is just feeding through.

    if you have hdisk values, then, as WMP posted, find the lunid of those disks.
    IF you have logical volumes you're mapping to, then you need to find the disks those lv are on.

    $ lslv -pv rvg302lv02
    PV                COPIES        IN BAND       DISTRIBUTION
    hdisk309          060:000:000   100%          000:060:000:000:000

    We can see that the logical volume rvg302lv02 resides in its entirety on hdisk309

    then we look up the lunid on hdisk309

    LVL 11

    Author Closing Comment

    thanks all

    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone.

    Featured Post

    How to run any project with ease

    Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
    - Combine task lists, docs, spreadsheets, and chat in one
    - View and edit from mobile/offline
    - Cut down on emails

    Suggested Solutions

    Title # Comments Views Activity
    Problem Imaging Computers With Clonezilla 2 63
    reinstall 1 43
    Skill Development 15 98
    Image not there 4 0
    Attention: This article will no longer be maintained. If you have any questions, please feel free to mail me. Please see for the updated article. It is avail…
    Let's say you need to move the data of a file system from one partition to another. This generally involves dismounting the file system, backing it up to tapes, and restoring it to a new partition. You may also copy the file system from one place to…
    This tutorial goes over how to archive and restore FreeBSD jails that are managed by ezjail.
    Video by: Phil
    This video goes over how to configure and start a jail in FreeBSD.  This video is meant to supplement the article included with this course.

    760 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    7 Experts available now in Live!

    Get 1:1 Help Now