AIX

AIX

Connect with fellow AIX users and experts to gain knowledge, share insights, and solve problems.


#Power
#Power
 View Only
  • 1.  Unable to Migrate PV from hdisk12 to other disks in same vg

    Posted 3 days ago

    Issue:

    • Trying to migrate hdisk12 from backupvg to oradatavg

    • migratepv fails with "0516-810 migratepv: Not enough room on destination physical volumes"

    • backuplv is striped across 6 disks (hdisk12-17) with 1000 LPs total

    • hdisk13-16 have 0 free PPs, hdisk17 has 193 free PPs (fragmented)

    • Filesystem has 89% free space (447GB free of 500GB)

    Current State:

    • hdisk12: 198 LPs (40..39..39..40..40 distribution)

    • hdisk13-16: 199 LPs each (completely full)

    • hdisk17: 6 LPs with 193 free PPs (fragmented ranges)

    • Striping pattern prevents redistribution

    Attempted Solutions:

    • migratepv hdisk12 hdisk13 hdisk14 hdisk15 hdisk16 hdisk17 - fails

    • LV reduction not possible due to striping constraints

    • Online migration required (can't unmount /backup)

    Question:
    What's the safest approach to migrate hdisk12 while maintaining data integrity, given the striping constraints and online requirement?

    ** Need to free hdisk12 from backupvg.

    While tried migratepv 
    2[root/root]:[/]# migratepv hdisk12 hdisk13 hdisk14 hdisk15 hdisk16 hdisk17
    0516-810 migratepv: Not enough room on destination physical volumes.

    --------------------------------------------------------------------------------


    2[root/root]:[/]# df -gt /backup
    Filesystem    GB blocks      Used      Free %Used Mounted on
    /dev/backuplv    500.00     52.37    447.63   11% /backup
    2[root/root]:[/]# lsvg -l backupvg
    backupvg:
    LV NAME             TYPE       LPs     PPs     PVs  LV STATE      MOUNT POINT
    backuplv_log        jfs2log    1       1       1    open/syncd    N/A
    backuplv            jfs2       1000    1000    6    open/syncd    /backup
    2[root/root]:[/]#
    2[root/root]:[/]# lslv -l backuplv
    backuplv:/backup
    PV                COPIES        IN BAND       DISTRIBUTION
    hdisk12           198:000:000   19%           040:039:039:040:040
    hdisk13           199:000:000   20%           040:040:039:040:040
    hdisk14           199:000:000   20%           040:040:039:040:040
    hdisk15           199:000:000   20%           040:040:039:040:040
    hdisk16           199:000:000   20%           040:040:039:040:040
    hdisk17           006:000:000   100%          000:006:000:000:000
    2[root/root]:[/]# lslv -l backuplv_log
    backuplv_log:N/A
    PV                COPIES        IN BAND       DISTRIBUTION
    hdisk12           001:000:000   100%          000:001:000:000:000
    2[root/root]:[/]#
    2[root/root]:[/]# lspv -l hdisk12
    hdisk12:
    LV NAME               LPs     PPs     DISTRIBUTION          MOUNT POINT
    backuplv              198     198     40..39..39..40..40    /backup
    backuplv_log          1       1       00..01..00..00..00    N/A
    2[root/root]:[/]# lspv -l hdisk13
    hdisk13:
    LV NAME               LPs     PPs     DISTRIBUTION          MOUNT POINT
    backuplv              199     199     40..40..39..40..40    /backup
    2[root/root]:[/]# same result for hdisk14 hdisk15 hdisk16
    ksh: same:  not found.
    2[root/root]:[/]# lspv -l hdisk17
    hdisk17:
    LV NAME               LPs     PPs     DISTRIBUTION          MOUNT POINT
    backuplv              6       6       00..06..00..00..00    /backup
    2[root/root]:[/]#
    2[root/root]:[/]# lsvg -p backupvg
    backupvg:
    PV_NAME           PV STATE          TOTAL PPs   FREE PPs    FREE DISTRIBUTION
    hdisk12           active            199         0           00..00..00..00..00
    hdisk13           active            199         0           00..00..00..00..00
    hdisk14           active            199         0           00..00..00..00..00
    hdisk15           active            199         0           00..00..00..00..00
    hdisk16           active            199         0           00..00..00..00..00
    hdisk17           active            199         193         40..34..39..40..40



    ------------------------------
    MD. MORSHEDUR RAHMAN
    ------------------------------


  • 2.  RE: Unable to Migrate PV from hdisk12 to other disks in same vg

    Posted 3 days ago

    Shrink the JFS2 filesystem by the PP size in a loop. 
    lslv backuplv will show the PP size. My math says 512M which is very large
    Change during low usage per the docs because the PP size is very large.

    COUNT=0; while true ; do
    ((COUNT=COUNT+1))
    echo $COUNT
    chfs -a size -512M /backup
    if [[ $COUNT -gt 50 ]] ; then break ; fi
    done

    Now the migrate should work.
    You might want to check what your log LV uses too.



    ------------------------------
    Alexander Pettitt
    ------------------------------



  • 3.  RE: Unable to Migrate PV from hdisk12 to other disks in same vg

    Posted 2 days ago

    You are utilising 1001 PPs in the volume group backupvg (backuplv 1000, backuplv_log 1).  You have a total of 1194 PPs in backupvg.  There 199 PP used on hdisk12, there are only 193 free/available in backupvg (on hdisk17).  To move all data off hdisk12 requires 199 PPs to be available, there isn't enough space.

    As you have 447GB of free space in /backup, you can reduce the size of this filesystem using chfs - there shouldn't be an issue to reduce the size of the FS by 100G.  This will reduce the usage in backupvg and allow for the migration of data off hdisk12.  To reduce the time it takes to reduce the size of /backup, you can use defragfs first as when reducing the size of a filesystem a defrag is performed as part of the reduce process.

    Phill.



    ------------------------------
    Phill Rowbottom
    Unix Consultant
    Service Express
    Bedford
    ------------------------------



  • 4.  RE: Unable to Migrate PV from hdisk12 to other disks in same vg

    Posted 2 days ago

    Hi

    for striped logical volumes, the partitions must be distributed equally across all physical volumes. If the destination disks are not the same size, the migration may fail because the available space on the smallest disk limits the amount of data that can be moved.

    so , try to migrate to disks that are the same size as the other disks in the stripe.

    Thanks



    ------------------------------
    Anas AlSaleh
    IBM Power Systems Software Specialist
    Saudi Business Machines ( SBM )
    Riyadh
    ------------------------------



  • 5.  RE: Unable to Migrate PV from hdisk12 to other disks in same vg

    Posted yesterday

    Hi Dear,

    you don't have enough free PPs on backup vg .

    you can shrink backuplv Filesystem by 50Gb for example which will free up more PPs in backup vg then try to migrate again. 

    BR



    ------------------------------
    Hashem Al-Qaisi
    Senior Systems Engineer
    Jordan Business Systems
    ------------------------------