AIX

 View Only
  • 1.  delete missing snapshotpv without stop production vg

    Posted Fri June 05, 2020 10:45 PM
    Hi,

    I'm using iscsi disk to backup production vg via mirrorvg/splitvg. After split, lsvg -p shows follwing and I can joinvg and splitvg for incremental backup.

    # lsvg -p dbvg
    dbvg:
    PV_NAME PV STATE TOTAL PPs FREE PPs FREE DISTRIBUTION
    hdisk1 active 1117 316 24..00..00..68..224
    hdisk8 snapshotpv 1199 398 40..00..00..118..240

    hidks8 is the iscsi disk. Then iscsi disk is destroyed at the iscsi server side. I can delete the snapshotpv via umount all LVs on production vg, then "reducevg -d dbvg hdisk8". But if the lv is in open status, the reducevg -d will fail:

    # reducevg -df dbvg hdisk8
    0516-1008 rmlv: Logical volume fslv00 must be closed. If the logical
    volume contains a filesystem, the umount command will close
    the LV device.
    0516-884 reducevg: Unable to remove physical volume hdisk8.

    Is there a way to delete the snapshotpv and clear the snapshot status for production vg without close production lv? Thanks!

    ------------------------------
    ligong qiu
    ------------------------------


  • 2.  RE: delete missing snapshotpv without stop production vg

    Posted Mon June 08, 2020 12:02 PM

    Remove the copy of all LV's in the VG from snapshot physical volume and then call reducevg
    ex:
    rmlvcopy fslv00 1 hdisk8
    reducevg -df hdisk8 dbvg




    ------------------------------
    Lakshmi Yadlapati
    ------------------------------



  • 3.  RE: delete missing snapshotpv without stop production vg

    Posted Mon June 08, 2020 09:33 PM
    rmlvcopy works! Don't need to stop mounted lv.
    Thanks Lakshmi.


    ------------------------------
    ligong qiu
    ------------------------------



  • 4.  RE: delete missing snapshotpv without stop production vg

    Posted Mon June 08, 2020 12:02 PM
    Remove the logical volume copy from snapshot copy and then try reducevg
    rmlvcopy fslv00 1 hdisk8
    educevg -df dbvg hdisk8

    ------------------------------
    Lakshmi Yadlapati
    ------------------------------