The real issue here is that rootvg should always show up as the same disk in maintenance mode as in normal mode. Ideally, hdisk0 is SCSI ID 0, and if it's an SVC LUN, then it should be from the node with the lowest WWN. alt_rootvg should be hdisk1, same placement. It may take a little more shuffling around to get that, but it's important for situations where your boot image becomes corrupted, so you boot into maintenance mode from NIM or ISO, and then you cannot rebuild the boot image from inside of getrootfs because the disk numbers don't match.
Note: Disk drive devices that are members of the root volume group, or that will become members of the root volume group (by means of LVM or install procedures), must not be renamed. Renaming such disk drives may interfere with the ability to recover from certain scenarios, including boot failures.
In using this to move rootvg back to hdisk0, I found a missing step along the way. After step 6 when you unmirror rootvg, lg_dumplv is still on the other disk. You can use migratepv -l to move that logical volume to hdisk0, then you can proceed to remove the other hdisk from rootvg.
Hi Chris Excellent POst!!! as you mentioned.. sometimes there is not enough time to have "Order in the Universe" but with a script behind this detailed step by step, certainly can be restored :D I was wondering if you already have the hdisk0 included into another VG, to avoid an outage in the application , wouldn't help to add an extra disk in the VG , do a migratepv from hdisk0 to hdiskXX , and do reducevg datavg hdisk0? Might save you an outage , avoiding to deal with the application team/database team/ business :D
Thanks for the comment Mihai, Yet another great reason to upgrade/migrate to a recent version of AIX ASAP! What are you waiting for? ;)
Unfortunatly you need at least AIX 6.1 TL6 (or AIX 7.1) .
Yet another excellently timed post Chris! I am using your nimadm post to upgrade some old AIX 5.3 LPARs to 6.1 and the process will have the active rootvg on a disk other than hdisk0. Once the we are sure that the OS upgrade has not caused any application issues I wanted to move rootvg back to hdisk0. I had a good idea of the steps required to move rootvg back to hdisk0, but its really nice to have it all laid out!