User Tools

Site Tools


aix:pv_missing

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
aix:pv_missing [2021/01/01 21:22]
127.0.0.1 external edit
aix:pv_missing [2022/11/14 10:06] (current)
manu
Line 1: Line 1:
-====== Howto cleanup a PV MISSING in a VG ======+====== Howto cleanup a PV MISSING in a VG, resync ​VG ======
  
 If a VG has a PV missing (disk not accessible, or removed), then if the VG is mirrored, then you can easily access the datas on the good copy, else the filesystems from wrong disk will be lost: If a VG has a PV missing (disk not accessible, or removed), then if the VG is mirrored, then you can easily access the datas on the good copy, else the filesystems from wrong disk will be lost:
Line 12: Line 12:
 </​cli>​ </​cli>​
  
-try+<cli prompt='#'>​ 
-  # varyonvg ​myvg+[root@labotest]/​root#​ lsvg vgExport 
 +VOLUME GROUP      vgExport ​                VG IDENTIFIER: ​ 00fa343c00004c000000016155668966 
 +VG STATE: ​          ​active ​                  PP SIZE:        64 megabyte(s) 
 +VG PERMISSION: ​     read/​write ​              TOTAL PPs:      1918 (122752 megabytes) 
 +MAX LVs:            256                      FREE PPs:       128 (8192 megabytes) 
 +LVs:                18                       USED PPs:       1790 (114560 megabytes) 
 +OPEN LVs:           ​17 ​                      ​QUORUM: ​        1 (Disabled) 
 +TOTAL PVs:          2                        VG DESCRIPTORS:​ 3 
 +STALE PVs:          0                        STALE PPs:      56 
 +</​cli>​ 
 + 
 +First check your disk availility:​ 
 +<cli prompt='#'>​ 
 +[root@labotest]/​root#​ cfgmgr 
 +[root@labotest]/​root#​ lspath 
 +</​cli>​ 
 + 
 +If all disks and paths are OK then you can continue, else check disk connections. 
 + 
 +===== rootvg ===== 
 + 
 +A rootvg can aonly be synchronized,​ if no dump device are in use 
 + 
 +Check if it configure as **/​dev/​sysdumpnull**,​ else change it 
 +<cli prompt='#'>​ 
 +[root@labotest]/​root#​ sysdumpdev -l 
 +primary ​             /​dev/​lg_dumplv 
 +secondary ​           /​dev/​lg_dumplv2 
 +... 
 +[root@labotest]/​root#​ sysdumpdev -Pp /​dev/​sysdumpnull -s /​dev/​sysdumpnull 
 +</​cli>​ 
 + 
 +Now change disk availability 
 +<cli prompt='#'>​ 
 +[root@labotest]/​root#​ lsvg -p rootvg 
 +rootvg: 
 +PV_NAME ​          PV STATE          TOTAL PPs   FREE PPs    FREE DISTRIBUTION 
 +hdisk0 ​           active ​           511         ​95 ​         00..00..00..00..95 
 +hdisk3 ​           missing ​          ​542 ​        ​29 ​         51..18..51..51..51 
 + 
 +[root@labotest]/​root#​ chpv -v a hdisk3 
 +[root@labotest]/​root#​ varyonvg rootvg 
 + 
 +[root@labotest]/​root#​ lsvg -p rootvg 
 +rootvg: 
 +PV_NAME ​          PV STATE          TOTAL PPs   FREE PPs    FREE DISTRIBUTION 
 +hdisk0 ​           active ​           511         ​95 ​         00..00..00..00..95 
 +hdisk3 ​           active ​           542         ​29 ​         51..18..51..51..51 
 +</​cli>​ 
 + 
 +Replace dump devices 
 +<cli prompt='#'>​ 
 +[root@labotest]/​root#​ sysdumpdev -Pp /​dev/​lg_dumplv -s /​dev/​lg_dumplv2 
 +</​cli>​ 
 + 
 +Now synchronize rootvg 
 +<cli prompt='#'>​ 
 +[root@labotest]/​root#​ syncvg -v rootvg 
 +</​cli>​ 
 + 
 +After a while it should have **STALE PPs:0** 
 +<cli prompt='#'>​ 
 +[root@labotest]/​root#​ lsvg rootvg 
 +VOLUME GROUP: ​      ​rootvg ​                  VG IDENTIFIER: ​ 00fa343c00004c000000016155668966 
 +VG STATE: ​          ​active ​                  PP SIZE:        64 megabyte(s) 
 +VG PERMISSION: ​     read/​write ​              TOTAL PPs:      1918 (122752 megabytes) 
 +MAX LVs:            256                      FREE PPs:       128 (8192 megabytes) 
 +LVs:                18                       USED PPs:       1790 (114560 megabytes) 
 +OPEN LVs:           ​17 ​                      ​QUORUM: ​        1 (Disabled) 
 +TOTAL PVs:          2                        VG DESCRIPTORS:​ 3 
 +STALE PVs:          0                        STALE PPs:      0 
 +</​cli>​ 
 + 
 +===== non rootvg ===== 
 + 
 +Change disk availability 
 +<cli prompt='#'>​ 
 +[root@labotest]/​root#​ lsvg -p vgExport 
 +vgExport: 
 +PV_NAME ​          PV STATE          TOTAL PPs   FREE PPs    FREE DISTRIBUTION 
 +hdisk1 ​           active ​           511         ​95 ​         00..00..00..00..95 
 +hdisk2 ​           missing ​          ​542 ​        ​29 ​         51..18..51..51..51 
 + 
 +[root@labotest]/​root#​ chpv -v a hdisk1 
 +[root@labotest]/​root# varyonvg ​vgExport 
 + 
 +[root@labotest]/​root#​ lsvg -p vgExport 
 +rootvg: 
 +PV_NAME ​          PV STATE          TOTAL PPs   FREE PPs    FREE DISTRIBUTION 
 +hdisk1 ​           active ​           511         ​95 ​         00..00..00..00..95 
 +hdisk2 ​           active ​           542         ​29 ​         51..18..51..51..51 
 +</​cli>​ 
 + 
 +Now synchronize rootvg 
 +<cli prompt='#'>​ 
 +[root@labotest]/​root#​ syncvg -v vgExport 
 +</​cli>​ 
 + 
 +===== non rootvg in concurrent mode (PowerHA) ===== 
 + 
 +Check disks concurrent mode 
 +[root@cl_abotest1]/​root#​ lspv 
 +... 
 +hdisk5 ​         00fa343ca582d6cd ​                   caavg_private ​  ​active 
 +hdisk6 ​         00fa343ca582ed54 ​                   RG1vg           ​concurrent 
 +hdisk7 ​         00fa343ca582ee4b ​                   RG1vg           ​concurrent 
 +</​cli>​ 
 + 
 +Change disk availability,​ varyonvg with option **-c** for concurrent VG 
 +<cli prompt='#'>​ 
 +[root@cl_abotest1]/​root#​ lsvg -p RG1vg 
 +RG1vg: 
 +PV_NAME ​          PV STATE          TOTAL PPs   FREE PPs    FREE DISTRIBUTION 
 +hdisk6 ​           active ​           511         ​95 ​         00..00..00..00..95 
 +hdisk7 ​           missing ​          ​542 ​        ​29 ​         51..18..51..51..51 
 + 
 +[root@cl_abotest1]/​root#​ chpv -v a hdisk7 
 +[root@cl_abotest1]/​root#​ varyonvg -c RG1vg 
 + 
 +[root@cl_abotest1]/​root#​ lsvg -p RG1vg 
 +RG1vg: 
 +PV_NAME ​          PV STATE          TOTAL PPs   FREE PPs    FREE DISTRIBUTION 
 +hdisk6 ​           active ​           511         ​95 ​         00..00..00..00..95 
 +hdisk7 ​           active ​           542         ​29 ​         51..18..51..51..51 
 +</​cli>​ 
 + 
 +Now synchronize RG1vg 
 +<cli prompt='#'>​ 
 +[root@labotest]/​root#​ syncvg -v RG1vg 
 +</​cli>​
  
-If one logical volume is used as dumpdevice in the volume group  +===== other procedure =====
-then +
-  # sysdumdev -l +
-  # sysdumpdev -Pp /​dev/​sysdumpnull -s /​dev/​sysdumpnull +
-   +
-then retry the varyonvg+
  
 Before editing ODM, which can be very dangerous, you can use low level command to correct the problem: ​ Before editing ODM, which can be very dangerous, you can use low level command to correct the problem: ​
aix/pv_missing.1609532521.txt.gz · Last modified: 2021/01/01 21:22 by 127.0.0.1