digiturf.net

Dynamically expand the LUN ( 1st at Storage Side ) in AIX.

QUESTION ::  HOW TO DYNAMICALLY EXTEND DISK IN AIX, AFTER STORAGE TEAM INCREASED THE LUN SIZE AT THEIR END.

DETAILS from STORAGE TEAM:

FileSystem to Grow  ::      /db2/fs001

LUN Allocated           ::      hdiskpower10 100 125 6000144000000010700803B124345AA7

1. (root@q111pstricfreg):/# lspv | grep -i hdiskpower10       – Execute it to FIND to which volume group this disk / PV is added to / associated with…!
hdiskpower10    000130e3e549c064       datavg          active

2. (root@q111pstricfreg):/# getconf DISK_SIZE /dev/hdiskpower10        –  This SHOWS the NEW INCREASED SIZE.
129024

(root@q111pstricfreg):/# lspv hdiskpower10 | grep -i TOTAL          –  But #lspv still shows OLD SIZE Only.
TOTAL PPs:          1598 (102272 megabytes)  VG DESCRIPTORS:   1

3.  cfgmgr

4.  chvg -g datavg         – ” -g ” Scans for any DISK Size changes for all disks that are part of “datavg” mentioned here.

5. (root@q111pstricfreg):/# lspv hdiskpower10 | grep -i TOTAL     – After #chvg, the size of the disk shows 25 GB extra space.
TOTAL PPs:   014 (128896 megabytes)  VG DESCRIPTORS:   1

6. (root@q111pstricfreg):/# df -g /db2/fs001                      – Check the SIZE of FS before adding the space to it / extnding LV.
Filesystem    GB blocks      Free %Used    Iused %Iused Mounted on
/dev/fslv14      157.81     20.72   87%       69     1% /db2/fs001

7. (root@q111pstricfreg):/# lsvg -l datavg | grep -i /db2/fs001   – Find the LV Details that are associated with FS “/db2/fs001”, in order to add space to FS, we 1st need to extend LV
fslv14              jfs2       2525    2525    5    open/syncd    /db2/fs001                                                              associated with it.

8. (root@q111pstricfreg):/# extendlv fslv14 25G                   –  Extending / Adding 25GB space to LV, so that it can be used to increase the Filesystem space.

9. (root@q111pstricfreg):/# chfs -a size=+25G /db2/fs001          –  Adds 25 GB space to filesystem now.
Filesystem size changed to 383385600

10. (root@q111pstricfreg):/# df -g /db2/fs001                     –  Verify with PREVIOUS output above to find that SPACE is added now.
Filesystem    GB blocks      Free %Used    Iused %Iused Mounted on
/dev/fslv14      182.81     45.71   75%       69     1% /db2/fs001

+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
SOME COMMANDS THAT MIGHT BE USEFUL TO GET PRECISE INFORMATION WHILE TRYING TO DO THIS ARE AS FOLLOWS ::

(root@q111pstricfreg):/# lspv -p hdiskpower10
hdiskpower10:
PP RANGE  STATE   REGION        LV NAME             TYPE       MOUNT POINT
1-320   used    outer edge    fslv19              jfs2       /db2/fs006
321-324   used    outer edge    fslv04              jfs2       /dba
325-331   used    outer edge    fslv10              jfs2       /db2/db2p095b
332-403   used    outer edge    fslv14              jfs2       /db2/fs001
404-456   used    outer middle  fslv14              jfs2       /db2/fs001
457-806   used    outer middle  fslv19              jfs2       /db2/fs006
807-1208  used    center        fslv19              jfs2       /db2/fs006
1209-1598  used    inner middle  fslv19              jfs2       /db2/fs006
1599-1611  used    inner middle  fslv14              jfs2       /db2/fs001
1612-1998  used    inner edge    fslv14              jfs2       /db2/fs001
1999-2014  free    inner edge

(root@q111pstricfreg):/# lsvg -p datavg
datavg:
PV_NAME           PV STATE          TOTAL PPs   FREE PPs    FREE DISTRIBUTION
hdiskpower11      active            2014        16          00..00..00..00..16
hdiskpower10      active            2014        16          00..00..00..00..16
hdiskpower9       active            1598        0           00..00..00..00..00
hdiskpower8       active            2014        16          00..00..00..00..16
hdiskpower7       active            1598        0           00..00..00..00..00
hdiskpower6       active            2014        16          00..00..00..00..16
hdiskpower2       active            1598        0           00..00..00..00..00
hdiskpower1       active            1598        0           00..00..00..00..00
hdiskpower0       active            1598        0           00..00..00..00..00
hdiskpower3       active            1998        0           00..00..00..00..00
hdiskpower12      active            1598        0           00..00..00..00..00
hdiskpower5       active            3998        0           00..00..00..00..00
hdiskpower4       active            3998        105         00..00..00..00..105

(root@q111pstricfreg):/# lslv -l fslv14
fslv14:/db2/fs001
PV                COPIES        IN BAND       DISTRIBUTION
hdiskpower10      525:000:000   10%           072:053:000:013:387
hdiskpower2       1200:000:000  26%           320:320:319:241:000
hdiskpower12      365:000:000   52%           000:192:000:000:173
hdiskpower5       526:000:000   61%           000:323:000:000:203
hdiskpower4       309:000:000   100%          000:309:000:000:000

(root@q111pstricfreg):/# lslv fslv14
LOGICAL VOLUME:     fslv14                 VOLUME GROUP:   datavg
LV IDENTIFIER:      000130e30000d6000000012fe549cb55.12 PERMISSION:     read/write
VG STATE:           active/complete        LV STATE:       opened/syncd
TYPE:               jfs2                   WRITE VERIFY:   off
MAX LPs:            3000                   PP SIZE:        64 megabyte(s)
COPIES:             1                      SCHED POLICY:   parallel
LPs:                2925                   PPs:            2925
STALE PPs:          0                      BB POLICY:      relocatable
INTER-POLICY:       minimum                RELOCATABLE:    yes
INTRA-POLICY:       middle                 UPPER BOUND:    1024
MOUNT POINT:        /db2/fs001             LABEL:          /db2/fs001
MIRROR WRITE CONSISTENCY: on/ACTIVE
EACH LP COPY ON A SEPARATE PV ?: yes
Serialize IO ?:     NO
DEVICESUBTYPE : DS_LVZ
COPY 1 MIRROR POOL: None
COPY 2 MIRROR POOL: None
COPY 3 MIRROR POOL: None

Tagged on: ,

Leave a Reply