Operating System - HP-UX
1820274 Members
3242 Online
109622 Solutions
New Discussion юеВ

Re: Primary boot disk replacement

 
SOLVED
Go to solution
Nikee Reddy
Regular Advisor

Primary boot disk replacement

Hello,

We have replaced the corrupted primary boot disk with a good one and booted the system using the alternative disk.

Please let me know whether the following commands work to resync the data and the configuration back on the PRI boot disk:

$ vgcfgrestore ├в l -n /dev/vg00
$ vgcfgrestore - /dev/vg00 /dev/rdsk/c0t6d0
$ vgchange -a y /dev/vg00
$ vgsync
$ lvsync

Thanks,
Nik
6 REPLIES 6
Pete Randall
Outstanding Contributor

Re: Primary boot disk replacement

Nikee,

Looks good, though I don't think you need to do both the vgsync and the lvsync - just one or the other.


Pete

Pete
Geoff Wild
Honored Contributor

Re: Primary boot disk replacement

See this post:

http://forums1.itrc.hp.com/service/forums/bizsupport/questionanswer.do?threadId=383446


Rgds...Geoff
Proverbs 3:5,6 Trust in the Lord with all your heart and lean not on your own understanding; in all your ways acknowledge him, and he will make all your paths straight.
Mel Burslan
Honored Contributor

Re: Primary boot disk replacement

to update your replaced disk and make it bootable again, you will additionally need these commands as well, replace # signs with the designators of your particular, replaced disk.

mkboot /dev/rdsk/c#t#d#
mkboot -a "hpux -lq (;0) /stand/vmunix" /dev/rdsk/c#t#d#
lvlnboot -r /dev/vg00/lvol1
lvlnboot -s /dev/vg00/lvol2
________________________________
UNIX because I majored in cryptology...
Sundar_7
Honored Contributor
Solution

Re: Primary boot disk replacement

Hi Nik,

Nope, you are missing couple of very important commands, mkboot.

With LVM mirroring, the LIF volumes of the disks are not mirrored.

So you have to include mkboot commands as well

# vgcfgrestore -n /dev/vg00 /dev/rdsk/c0t6d0
# mkboot /dev/rdsk/c0t6d0
# mkboot -a "hpux -lq" /dev/rdsk/c0t6d0
# vgchange -a y /dev/vg00
# vgsync /dev/vg00
# lvlnboot -R

if I have enough time, I would reboot the system with the primary boot disk that just got replaced.

Also note these commands can only be executed by root and not by "$" user :-)
Learn What to do ,How to do and more importantly When to do ?
Victor BERRIDGE
Honored Contributor

Re: Primary boot disk replacement

And Assuming you have onlinediags installed I would also :
#mkboot -b updatediaglif -p ISL -p HPUX -p LABEL -p AUTO /dev/rdsk/c0t6d0

Dont forget to setboot...

All the best
Victor
Pete Randall
Outstanding Contributor

Re: Primary boot disk replacement

Nikee,

I missed the mkboot part - sorry! But I will point out that the lvlnboot steps are un-necessary as shown in this quote from the Software Recovery Cookbook:

"4. Write content of LABEL file, i.e set root, boot, swap and dump device: NOTE:This step can be omitted if you replace a failed mirror disk. Then this information has already been restored by vgcfgrestore. To be sure to have the latest information on the disk just do the following steps."


Pete

Pete