This is a discussion on Help with hard disk replacement in AIX within the AIX Operating System forums, part of the Unix Operating Systems category; --> I'm new to AIX and I'm trying to find a step by step guide to replacing a disk in ...
| |||||||
| Register | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| ||||
| I'm new to AIX and I'm trying to find a step by step guide to replacing a disk in an SSA array. Pdisk9, which translates to hdisk11 failed. This disk is mirrored to another disk, hdisk22. These disk are part of VG3. I really need something that will give me the commands to run in order. Any help is greatly appreciated. |
| |||
| I think I have a general idea of what to do. 1. Note the logical volumes on the volume group - lsvg -l vg3 2. Remove the logical volumes from the disk - rmlvcopy LVNAME 1 hdisk11 3. Ensure no logical volumes are left on the disk. - lspv -p hdisk11 4. Remove the volume group from the disk - reducevg -df vg3 hdisk11 5. Ensure everything was removed - lspv (which should list hdisk11 as none) 6. Delete the disk - rmdev -l hdisk11 -d 7. Replace the disk 8. run cfgmgr 9. Check that the new drive is there. - lspv and/or lsdev -Cs scsi 10. Add the disk to the volume group - extendvg vg3 hdisk# (new hard disk) 11. Recreate the mirror - mirrorvg vg3 hdisk# (new hard disk) 12. Sync the mirror. - syncvg -v vg3 If this is correct can anyone tell me if I need to adjust or add anything? Thanks |
| |||
| coffeyp@gmail.com wrote: > I think I have a general idea of what to do. > > 1. Note the logical volumes on the volume group > - lsvg -l vg3 > > 2. Remove the logical volumes from the disk > - rmlvcopy LVNAME 1 hdisk11 > > 3. Ensure no logical volumes are left on the disk. > - lspv -p hdisk11 > > 4. Remove the volume group from the disk > - reducevg -df vg3 hdisk11 > > 5. Ensure everything was removed > - lspv (which should list hdisk11 as none) > > 6. Delete the disk > - rmdev -l hdisk11 -d > > 7. Replace the disk > > 8. run cfgmgr > > 9. Check that the new drive is there. > - lspv and/or lsdev -Cs scsi > > 10. Add the disk to the volume group > - extendvg vg3 hdisk# (new hard disk) > > 11. Recreate the mirror > - mirrorvg vg3 hdisk# (new hard disk) > > 12. Sync the mirror. > - syncvg -v vg3 > > > If this is correct can anyone tell me if I need to adjust or add > anything? Remove the pdisk as well before running cfgmgr. |
| |||
| Another question regarding this procedure. At step 2, one of the logical volumes spans 3 disks (there are 6 drives in the vg). There is no room to save a copy of this to disk, so is the correct process to take a back up of the logical volume and then restore it after the disk has been replaced? |
| |||
| coffeyp@gmail.com wrote: > Another question regarding this procedure. > > At step 2, one of the logical volumes spans 3 disks (there are 6 drives > in the vg). > There is no room to save a copy of this to disk, so is the correct > process to take a back up of the logical volume and then restore it > after the disk has been replaced? since the lv is mirrored there should be no need to back it up. The very very first step should be to run rmlvcopy to logically get rid of the mirror on the failed disk. You are updating the vgda and odm so it doesn't matter if the disk isn't spinning. Do indeed remove both the hdisk and the pdisk associated with it. Otherwise you'll have a pdisk with no hdisk assiciated to it. Last step will be a mklvcopy use the the -k switch to sync as you build the copy. Rembember RTFM |
| ||||
| coffeyp@gmail.com wrote: > I'm new to AIX and I'm trying to find a step by step guide to replacing > a disk in an SSA array. > > Pdisk9, which translates to hdisk11 failed. This disk is mirrored to > another disk, hdisk22. These disk are part of VG3. > > I really need something that will give me the commands to run in order. > Any help is greatly appreciated. The procedures outlined by the others here will work, but there is also the replacepv command. In which case the procedure is: 1. Plug in the new disk and run cfgmgr. Check it is there. 2. Run: replacepv hdisk11 hdisk99 2a. Have coffee break. 3. Run: rmdev -dl hdisk11 rmdev -dl pdisk9 If I remember correctly, the replacepv removes the original disk from the volume group. 4. Remove broken disk from the system. Done! This will leave you with an ugly hole in your disk configuration (hdisk10..hdisk12) but it's fully automatic. One special note, I once used this to move the data off one disk to a temporary one that was larger. This went fine. However, when I got the new disk in (same size as original), I couldn't replacepv that one back, even though the data did fit. This was on a maxed-out non-big volume group, so getting the data back onto the correct disk was a bit of a puzzle. :-/ Cheers, Menno |