User Tools

Site Tools


aix:alt_disk

AIX OS alternate disk operations

Clone rootvg

To clone the running rootvg to hdisk3 and hdisk4 (in case of mirrored rootvg), and execute update_all on all updates from /updates. Disks hdisk3 and 4 must be empty

root@nimmig /root> alt_disk_copy -d "hdisk3 hdisk4" -b update_all -l /updates

Use flags:

  • -B: do not update the bootlist
  • -g: Skips disk bootability checks
alt_disk_copy -d <hdisk to clone rootvg>             this will clone the rootvg to the specified disk
alt_disk_copy -e /etc/exclude.rootvg -d <hdisk>      this will use the exclude list during the cloning
alt_disk_copy -T -d <hdisk>                          it will convert jfs to jfs2 on the new target disk 
alt_rootvg_op -X <cloned rootvg to destroy>          this will destroy the cloned rootvg (alt_rootvg_op -X altinst_rootvg)
alt_rootvg_op -W -d <hdisk>                          this will wake up a disk (cloned filesystems will be mounted with prefix /alt_)
alt_rootvg_op -S -t <hdisk>                          this will put cloned rootvg to sleep (before that it will do a bosboot)

Use a custom image.data

# alt_disk_copy -d hdiskX -i /image.data -B

Upgrade an OS disk

AIX running is 7.1, with a second disk on AIX 6.1, disk in AIX 6.1 will be upgrade to latest TL of 6.1

  • import the rootvg using WakeUp option
root@nimmig /root> lspv
hdisk1          00c28e905221d464                    rootvg          active   # AIX 7.1
hdisk4          00f6d51b9a5ef20f                    None                     # AIX 6.1

root@nimmig /root> lsvg
rootvg
nimvg

root@nimmig /root> alt_rootvg_op -W -d hdisk4
Waking up None volume group ...
root@nimmig /root> lspv
hdisk1          00c28e905221d464                    rootvg          active
hdisk4          00f6d51b9a5ef20f                    altinst_rootvg  active
  • Mount the AIX 6.1TL9 pakages into the clone
  • Upgrade AIX 6.1
root@nimmig /export/lpp/aix6100/aix6100-09-00-lpp> mount /export/lpp/aix6100/aix6100-09-00-lpp /alt_inst/mnt

root@nimmig /export/lpp/aix6100/aix6100-09-00-lpp> INUCLIENTS=1 chroot /alt_inst /usr/sbin/install_all_updates -d /mnt -rc -Y
install_all_updates: Initializing system parameters.
install_all_updates: Log file is /var/adm/ras/install_all_updates.log
install_all_updates: Checking for updated install utilities on media.
....
Filesets processed:  529 of 617  (Total time:  17 mins 41 secs).

installp: APPLYING software for:
        perl.rte 5.8.8.488
  • Check for bootable disks
  • Put old volume into sleep
root@nimmig /export/lpp/aix6100/aix6100-09-00-lpp> ipl_varyon -i
[S 12124364 7667902 03/20/19-13:57:48:727 ipl_varyon.c 1313] ipl_varyon -i


PVNAME          BOOT DEVICE     PVID                    VOLUME GROUP ID
hdisk1          YES             00c28e905221d4640000000000000000        00c28e9000004b00
hdisk4          YES             00f6d51b9a5ef20f0000000000000000        00f6d51b00004c00
[E 12124364 0:060 ipl_varyon.c 1454] ipl_varyon: exited with rc=0
root@nimmig /root> alt_rootvg_op -S -t

-t option recreate boot device

Now you disk AIX 6.1 is bootable and ready for mapping on another LPAR to start

aix/alt_disk.txt · Last modified: 2022/09/26 09:08 by manu