UNIX – Determine Physical Device of specific File System

While trying to troubleshoot a possible I/O disk performance issue on AIX 7.2:

$ oslevel -r
7200-05

$ oslevel
7.2.0.0

I’m trying to understand how to identify the target device (iostat), without installing additional packages, as the AIX server has no access to the internet or local repository.

What I’ve learned so far:

pwd -P will show the physical directory:

$ cd /etc/opt/legacy/module/conf/tmpdir

$ pwd
/etc/opt/legacy/module/conf/tmpdir

$ pwd -P
/tmp

df will show the matching file system:

$ df | grep "/tmp"
/dev/hd3        31457280  30641296    3%      189     1% /tmp

Which from the above command output, turns out to be: /dev/hd3

iostat will show the input/output of all Devices:

System configuration: lcpu=16 drives=11 ent=1.00 paths=264 vdisks=0

tty:      tin         tout    avg-cpu: % user % sys % idle % iowait physc % entc
          0.2          8.4               10.9   4.6   84.1      0.4   0.4   41.4

Disks:         % tm_act     Kbps      tps    Kb_read   Kb_wrtn
hdisk1            0.0       0.0       0.0        754        56
hdisk0            0.0       0.0       0.0          0         0
hdisk17           0.0       0.1       0.0        774   1384212
hdisk16           0.0       0.0       0.0      54626    432704
hdisk18           0.0       0.0       0.0        754        56
hdisk9            0.0       0.1       0.0    1638802    461272
hdisk8            0.0       0.0       0.0      54750     19032
hdisk5            0.0       0.0       0.0       1142     28476
hdisk3            0.0       0.0       0.0          0         0
hdisk4            0.0       0.0       0.0      16840         0
hdisk2            0.0       0.0       0.0       4210    138592

And iostat -Dl will show the all devices response time (I/O):

$ iostat -Dl

System configuration: lcpu=16 drives=11 paths=264 vdisks=0

Disks:                      xfers                                read                                write                                  queue               
--------------- -------------------------------- ------------------------------------ ------------------------------------ --------------------------------------
                  %tm    bps   tps  bread  bwrtn   rps    avg    min    max time fail   wps    avg    min    max time fail    avg    min    max   avg   avg  serv
                  act                                    serv   serv   serv outs              serv   serv   serv outs        time   time   time  wqsz  sqsz qfull
hdisk1            0.0   0.0    0.0   0.0    0.0    0.0   4.4    0.4   21.7     0    0   0.0   1.7    1.2    6.0     0    0   0.0    0.0    0.0    0.0   0.0   0.0
hdisk0            0.0   0.0    0.0   0.0    0.0    0.0   0.0    0.0    0.0     0    0   0.0   0.0    0.0    0.0     0    0   0.0    0.0    0.0    0.0   0.0   0.0
hdisk17           0.0  66.0    0.0   0.0   66.0    0.0   1.4    0.2    4.8     0    0   0.0   3.6    1.3   16.3     0    0   0.0    0.0    0.0    0.0   0.0   0.0
hdisk16           0.0  31.7    0.0   5.4   26.3    0.0   1.1    0.2   14.4     0    0   0.0   2.3    1.1   18.6     0    0   0.6    0.0   20.8    0.0   0.0   0.0
hdisk18           0.0   0.0    0.0   0.0    0.0    0.0   2.6    0.3   11.7     0    0   0.0   1.9    1.2    7.2     0    0   0.0    0.0    0.0    0.0   0.0   0.0
hdisk9            0.0 121.0    0.0  94.1   26.9    0.0   0.9    0.2   22.3     0    0   0.0   1.9    1.1   14.3     0    0   0.0    0.0    0.1    0.0   0.0   0.0
hdisk8            0.0   7.7    0.0   6.3    1.4    0.0   0.8    0.2   27.5     0    0   0.0   2.0    1.1   13.8     0    0   0.0    0.0    0.1    0.0   0.0   0.0
hdisk5            0.0   3.0    0.0   0.1    2.9    0.0   1.3    0.2   12.0     0    0   0.0   1.7    1.1   16.7     0    0   0.0    0.0    0.1    0.0   0.0   0.0
hdisk3            0.0   0.0    0.0   0.0    0.0    0.0   0.0    0.0    0.0     0    0   0.0   0.0    0.0    0.0     0    0   0.0    0.0    0.0    0.0   0.0   0.0
hdisk4            0.0   0.8    0.0   0.8    0.0    0.0   4.2    0.2   36.2     0    0   0.0   0.0    0.0    0.0     0    0   0.0    0.0    0.0    0.0   0.0   0.0
hdisk2            0.0  16.5    0.0   0.2   16.3    0.0   4.8    0.3   34.0     0    0   0.0   1.8    1.1   19.2     0    0   0.1    0.0    5.0    0.0   0.0   0.0
$

How do I find the correct device (hdisk), that hosts the target file system: /dev/hd3?

Is this possible without installing additional packages?

Asked By: edwio

||

As hdisk?? are physical disks and hd?? are logical disks you need to execute:

lslv -l hd3

to get the physical disks where this LV is located. If you want to see physical partitions you can use:

lslv -m hd3

Warning: the last list can be quite long

Answered By: Romeo Ninov
Categories: Answers Tags: ,
Answers are sorted by their score. The answer accepted by the question owner as the best is marked with
at the top-right corner.