After clonning HPUX disk

 
SOLVED
Go to solution
Mahesh S
Advisor

After clonning HPUX disk

Hello,

I need help in after cloning the disk. I was
able to clone the disk using the 'dd' command.
I also able to boot with cloned disk, But when I see the 'lvlnboot -v' I could able see my previous disk info rather than expected new disk. Could you please help me out. Following are some of the info

----------------------------------
ioscan -funC disk
=======================================================================
disk 1 10/0/15/1.4.0 sdisk CLAIMED DEVICE SEAGATE ST118202LC
/dev/dsk/c3t4d0 /dev/rdsk/c3t4d0

disk 2 10/0/15/1.5.0 sdisk CLAIMED DEVICE SEAGATE ST39204LC
/dev/dsk/c3t5d0 /dev/rdsk/c3t5d0

disk 3 10/0/15/1.6.0 sdisk CLAIMED DEVICE SEAGATE ST39102LC
/dev/dsk/c3t6d0 /dev/rdsk/c3t6d0

-------------------------------------
Cloned from /dev/dsk/c3t4d0 to /dev/dsk/c3t5d0
-------------------------------------
After boot with new disk /dev/dsk/c3t5d0

lvlnboot :
Boot Definitions for Volume Group /dev/vg00:
Physical Volumes belonging in Root Volume Group: /dev/dsk/c3t4d0 (10/0/15/1.4.0) -- Boot Disk
Boot: lvol1 on: /dev/dsk/c3t4d0
Root: lvol3 on: /dev/dsk/c3t4d0
Swap: lvol2 on: /dev/dsk/c3t4d0
Dump: lvol2 on: /dev/dsk/c3t4d0, 0
-------------------------------------------

Please help me how do I change it.

Thank you in advance,
Mahesh S Rao
Little progress everyday... ...Adds upto big results
16 REPLIES 16
Steven E. Protter
Exalted Contributor
Solution

Re: After clonning HPUX disk

Shalom,

You need to re-run the non-destructive disk preparation steps to make your disk bootable.

lvlnboot -r /dev/vg00/lvol3 # root fs /
lvlnboot -s /dev/vg00/lvol2 #swap
lvlnboot -d /dev/vg00/lvol2 #swap/dump
lvlnboot -b /dev/vg00/lvol1
lvlnboot -R
lvlnboot -v
setboot
setboot -a 52.1.0 # second disk if present.

SEP

Steven E Protter
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
Mustafa Gulercan
Respected Contributor

Re: After clonning HPUX disk

hi;
if the second disk is c3t5d0 then follow;

mkboot -l /dev/rdsk/c3t5d0
mkboot -a "hpux -lq ;0)/vmunix" /dev/rdsk/c2t1d0

update the BDRA as following( i think tere is no need to update swap info)

/usr/sbin/lvlnboot -b /dev/vg00/lvol1
/usr/sbin/lvlnboot -s /dev/vg00/lvol2
/usr/sbin/lvlnboot -r /dev/vg00/lvol3

check the BDRA
/usr/sbin/lvlnboot -R /dev/vg00

finally check the book disks
lvlnboot -v /dev/vg00

regards;
mustafa
Mustafa Gulercan
Respected Contributor

Re: After clonning HPUX disk

hi;
if the second disk is c3t5d0 then follow;

mkboot -l /dev/rdsk/c3t5d0
mkboot -a "hpux -lq ;0)/vmunix" /dev/rdsk/c3t5d0

update the BDRA as following( i think tere is no need to update swap info)

/usr/sbin/lvlnboot -b /dev/vg00/lvol1
/usr/sbin/lvlnboot -s /dev/vg00/lvol2
/usr/sbin/lvlnboot -r /dev/vg00/lvol3

check the BDRA
/usr/sbin/lvlnboot -R /dev/vg00

finally check the book disks
lvlnboot -v /dev/vg00

regards;
mustafa
A. Clay Stephenson
Acclaimed Contributor

Re: After clonning HPUX disk

You should realize that boot disk's created by dd are intended to be "lifeboats"; ie, if you want to use them, you remove the current boot disk and replace the original with the clone in the same slot. Remember, this is an exact copy of an original boot disk so it has no knowledge of LVM or setboot. You should also note that "lifeboat" disks are never intended to replace mirrors but rather to augment mirrors. Lifeboats are really intended to protect you from 2 things that mirrors do not: 1) Really bad patches 2) Your own stupidity. Mirrors are intended to cover everything else and those are the disks that should be fully configured as alternate boot devices.
If it ain't broke, I can fix that.
Zinky
Honored Contributor

Re: After clonning HPUX disk

Or if you do not want to use that "DD" disk as a "lifeboat" - you can use it as a quick "alternate boot environment" for use such as quick fallback after a bad patch... etc.

You can set up that DD disk as an alternate BOOT VolumeGroup (in the case of an LVM Managed system). In our environment.. alternate boot volumegroup lifeboat is on a "dd" copied disk... There are of course gyrations to make this disk truly bootable..

Just like:

chewey# lvlnboot -v
Boot Definitions for Volume Group /dev/vg00:
Physical Volumes belonging in Root Volume Group:
/dev/dsk/c43t15d5 (0/0/6/1/0/4/0.2.23.0.7.15.5) -- Boot Disk
/dev/dsk/c62t15d5 (1/0/6/1/0/4/0.4.23.0.7.15.5)
Boot: stand on: /dev/dsk/c43t15d5
/dev/dsk/c62t15d5
Root: root on: /dev/dsk/c43t15d5
/dev/dsk/c62t15d5
Swap: swap on: /dev/dsk/c43t15d5
/dev/dsk/c62t15d5
Dump: swap on: /dev/dsk/c43t15d5, 0


Boot Definitions for Volume Group /dev/xxx:
Physical Volumes belonging in Root Volume Group:
/dev/dsk/c51t8d0 (1/0/4/1/0/4/1.8.0) -- Boot Disk
Boot: stand on: /dev/dsk/c51t8d0
Root: root on: /dev/dsk/c51t8d0
Swap: swap on: /dev/dsk/c51t8d0
Dump: swap on: /dev/dsk/c51t8d0, 0


Hakuna Matata

Favourite Toy:
AMD Athlon II X6 1090T 6-core, 16GB RAM, 12TB ZFS RAIDZ-2 Storage. Linux Centos 5.6 running KVM Hypervisor. Virtual Machines: Ubuntu, Mint, Solaris 10, Windows 7 Professional, Windows XP Pro, Windows Server 2008R2, DOS 6.22, OpenFiler
Mahesh S
Advisor

Re: After clonning HPUX disk

Hello All,

Thanks a tom for replying. But I tried
the precedures said (From: mustafa)
Result I could not able to Boot. I reinstalled the machine, Then I tried with Mirror, I installed fileset 'HP mirror Disk/UX' and tried mirroring the disk, I was able to do so. But when tried to split the volumes, I was unable to do 'vgreduce vg00 /dev/dsk/c3t6d0' ;-(. Rest of the volumes removed from mirror.

;-((

Thanks
Mahesh S Rao
Little progress everyday... ...Adds upto big results
NMory
Respected Contributor

Re: After clonning HPUX disk

You need to break the mirrors before vgreducing the disk!!

LN
IT_2007
Honored Contributor

Re: After clonning HPUX disk

what is vgdisplay -v vg00 shows now?

can you post lvlnboot -v vg00 and string /etc/lvmtab

Do you still have problem with reducing disk from vg00?
Mahesh S
Advisor

Re: After clonning HPUX disk

Hi,
here is the info:

>>>what is vgdisplay -v vg00 shows now?

# vgdisplay -v vg00
--- Volume groups ---
VG Name /dev/vg00
VG Write Access read/write
VG Status available
Max LV 255
Cur LV 6
Open LV 6
Max PV 16
Cur PV 2
Act PV 2
Max PE per PV 2500
VGDA 4
PE Size (Mbytes) 4
Total PE 4338
Alloc PE 4338
Free PE 0
Total PVG 0
Total Spare PVs 0
Total Spare PVs in use 0

--- Logical volumes ---
LV Name /dev/vg00/lvol1
LV Status available/syncd
LV Size (Mbytes) 280
Current LE 70
Allocated PE 70
Used PV 1

LV Name /dev/vg00/lvol2
LV Status available/syncd
LV Size (Mbytes) 4096
Current LE 1024
Allocated PE 1024
Used PV 1

LV Name /dev/vg00/lvol3
LV Status available/syncd
LV Size (Mbytes) 4300
Current LE 1075
Allocated PE 1075
Used PV 1

LV Name /dev/vg00/lvol1b
LV Status available/syncd
LV Size (Mbytes) 280
Current LE 70
Allocated PE 70
Used PV 1

LV Name /dev/vg00/lvol3b
LV Status available/syncd
LV Size (Mbytes) 4300
Current LE 1075
Allocated PE 1075
Used PV 1

LV Name /dev/vg00/lvol2b
LV Status available/syncd
LV Size (Mbytes) 4096
Current LE 1024
Allocated PE 1024
Used PV 1


--- Physical volumes ---
PV Name /dev/dsk/c3t5d0
PV Status available
Total PE 2169
Free PE 0
Autoswitch On

PV Name /dev/dsk/c3t6d0
PV Status available
Total PE 2169
Free PE 0
Autoswitch On
#

>>>can you post lvlnboot -v vg00 and string /etc/lvmtab

# lvlnboot -v
Boot Definitions for Volume Group /dev/vg00:
Physical Volumes belonging in Root Volume Group:
/dev/dsk/c3t5d0 (10/0/15/1.5.0) -- Boot Disk
/dev/dsk/c3t6d0 (10/0/15/1.6.0) -- Boot Disk
Boot: lvol1 on: /dev/dsk/c3t5d0
Root: lvol3 on: /dev/dsk/c3t5d0
Swap: lvol2 on: /dev/dsk/c3t5d0
Dump: lvol2 on: /dev/dsk/c3t5d0, 0

# strings /etc/lvmtab
/dev/vg00
/dev/dsk/c3t5d0
/dev/dsk/c3t6d0
#

>>>Do you still have problem with reducing disk from vg00?

Still it shows

vgreduce: Physical volume "/dev/dsk/c3t6d0" could not be removed since some of its
physical extents are still in use.

The intension Behind is to have a script which will clone the disk for vPar installation....which will sane n/w traffic
lot of manual intraction and time.

Thanks a lot help me out,
Mahesh S Rao
Little progress everyday... ...Adds upto big results