mksysb to create backup of AIX Operating System and Restore

mksysb is a command that creates a backup of AIX Operating System and we can preserve these in case of emergencies like Operating System crash or in need of restore of original Operating System 

mksysb of create a backup

#
# mksysb -i /mksysb/image
Creating information file (/image.data) for rootvg.
Creating list of files to back up
Backing up 96720 files.........................
96720 of 96720 files backed up (100%)
0512-038 mksysb: Backup Completed Successfully.
#
#

Restoring the backup using alt_disk_mksysb

#
# alt_disk_mksysb -m /mksysb/image -d hdisk1
Restoring /image.data from mksysb image.
Checking disk sizes.
Creating cloned rootvg volume group and associated logical volumes.
Creating logical volume alt_hd5.
Creating logical volume alt_hd6.
Creating logical volume alt_hd8.
Creating logical volume alt_hd4.
Creating logical volume alt_hd2.
Creating logical volume alt_hd9var.
Creating logical volume alt_hd3.
Creating logical volume alt_hd1.
Creating logical volume alt_hd10opt.
Creating logical volume alt_hd11admin.
Creating logical volume alt_hd7.
Creating logical volume alt_livedump.
Creating logical volume alt_paging00.
Creating logical volume alt_paging01.
Creating logical volume alt_lg_dumplv.
Creating /alt_inst/ file system.
Creating /alt_inst/admin file system.
Creating /alt_inst/home file system.
Creating /alt_inst/opt file system.
Creating /alt_inst/tmp file system.
Creating /alt_inst/usr file system.
Creating /alt_inst/var file system.
Creating /alt_inst/var/adm/ras/livedump file system.
Restoring mksysb image to alternate disk(s).
Linking to 64bit kernel.
Changing logical volume names in volume group descriptor area.
Fixing LV control blocks...
forced unmount of /alt_inst/var/adm/ras/livedump
forced unmount of /alt_inst/var/adm/ras/livedump
forced unmount of /alt_inst/var
forced unmount of /alt_inst/var
forced unmount of /alt_inst/usr
forced unmount of /alt_inst/usr
forced unmount of /alt_inst/tmp
forced unmount of /alt_inst/tmp
forced unmount of /alt_inst/opt
forced unmount of /alt_inst/opt
forced unmount of /alt_inst/home
forced unmount of /alt_inst/home
forced unmount of /alt_inst/admin
forced unmount of /alt_inst/admin
forced unmount of /alt_inst
forced unmount of /alt_inst
Fixing file system superblocks...
Bootlist is set to the boot disk: hdisk1 blv=hd5
#
# lspv
hdisk0          00c3fee83609719b                    rootvg          active      
hdisk1          00f9a73e210f7f38                    altinst_rootvg              
#
# reboot
#
# lspv
hdisk0          00c3fee83609719b                    old_rootvg                  
hdisk1          00f9a73e210f7f38                    rootvg          active      
#

To restore the mksysb image run alt_disk_mksysb with the image source and the Physical Volume Option hdiskX. Physical Volume should be higher or equal to the backed up disks source (hdisk0) in above mksysb case. Reboot the partition and check the rootvg physical volume has changed from hdisk0 to hdisk1

Post a Comment

0 Comments