- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Re: commands to replace mirrored copy of root disk
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Discussions
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-27-2001 05:19 AM
09-27-2001 05:19 AM
1) lvreduce - some docs say to do it and some don't. If I do this do I have to run the command for the vg00/lvol2 (swap)?
2) mkboot -a
One shows mkboot -a "hpux (:0)/stand/vmunix" /dev/rdsk/cntndn
Another shows mkboot -a "hpux" /dev/rdsk/cntndn
3) Lvlnboot - one shows it being run 4 times with the r,s,d and v options for each vol on the disk.
Another shows it being run twice, with the -R option then the -v.
I have read the man pages on these commands and would like some opinions.
Thanks.
Richard Darling
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-27-2001 05:30 AM
09-27-2001 05:30 AM
Re: commands to replace mirrored copy of root disk
Check out this thread. JRF's answer gives you the exact steps and these work quite well. There's absolutely no need to lvreduce the disk out of the mirror.
http://forums.itrc.hp.com/cm/QuestionAnswer/1,1150,0xf890abe92dabd5118ff10090279cd0f9,00.html
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-27-2001 05:37 AM
09-27-2001 05:37 AM
Re: commands to replace mirrored copy of root disk
I would make one change (or actually a supplement) to James' recipe:
After you are done with the replacement, on the remaining boot disk, do this:
mkboot -a "hpux - /stand/vmunix" (;0)/dev/rdsk/CXtYdZ
This way you can boot the machine off of either disk without having to assert quorum.
If this command is run on both ofd your boot disks then anybody can boot your machine without intervention.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-27-2001 05:38 AM
09-27-2001 05:38 AM
Re: commands to replace mirrored copy of root disk
You have to proceed like this.
don't do any lvreduce.
Shutdown your system, replace the failed disk.
Boot your system using your working disk in single user mode. At the boot prompt interrupt the boot process, bo using your working disk and interact with ipl. At ipl prompt boot into single user mode with quorum disabled.
IPL>hpux -is -lq (;0)/stand/vmunix
It will boot into single user mode. Now do a mkboot for the new disk (say c?t?d?)
mkboot /dev/rdsk/c?t?d?
mkboot -a "hpux -lq (;0)/stand/vmunix" /dev/rdsk/c?t?d?
mount -a
(do this so that it mounts other lv for vg00)
(if they don't get mounted, mount them manually)
vgcfgrestore -n /dev/vg00 /dev/rdsk/c?t?d?
vgsync /dev/vg00
This should rebuild the mirror and your can reboot the system and work as usual.
Hope this helps.
thanks
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-27-2001 05:38 AM
09-27-2001 05:38 AM
Re: commands to replace mirrored copy of root disk
If you are able to shutdown the system, following steps will get you back the mirrors.
# Shutdown your system and replace the disk that is failing.
# Boot system into single user mode without quorum, as:
# ISL> hpux -is -lq /stand/vmunix
Restore volume group information on newly added disk.
# vgcfgrestore -n /dev/vg00 /dev/rdsk/cXtYdZ
# mkboot /dev/rdsk/cXtYdZ
#mkboot -a "hpux -lq /stand/vmunix"
/dev/rdsk/cXtYdZ
# lvlnboot -R
# vgchange -a y /dev/vg00
Synchronise the mirror volumes.
# vgsync /dev/vg00
Reboot the machine.
# shutdown -ry 0
Do confirm the miorror functionality by booting from mirror disk.
Update the diag information on mirror disks.
#mkboot -b /usr/sbin/diag/lif/updatediaglif2 -p ISL -p HPUX -p LABEL -p AUTO /dev/rdsk/cXtYdZ.
Thanks.
Prashant.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-27-2001 05:42 AM
09-27-2001 05:42 AM
Re: commands to replace mirrored copy of root disk
I had read that thread...
what about the conflict with the lvlnboot command - does running it once with the -R option cover the other three, r,s,d?. And I don't need to run it for each lvol?
Thanks...better safe...
Richard Darling
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-27-2001 05:43 AM
09-27-2001 05:43 AM
Re: commands to replace mirrored copy of root disk
1) no need for lvreduce at all. vgsync will take care of getting things in sync again.
2)Various boot commands would work, but I prefer the boot that overrides quorum:
mkboot -a "hpux -lq /stand/vmunix" /dev/rdsk/C?t?d?
3)You really just need one lvlnboot -R to sync the information between the disks again. The lvlnboot -v is just to check to make sure it looks right. The other lvlnboot options would only be used if you wanted to change one of the options.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-27-2001 05:43 AM
09-27-2001 05:43 AM
Re: commands to replace mirrored copy of root disk
Have a look at the thread below for more detailed steps.
http://us-support.external.hp.com/cki/bin/doc.pl/sid=b2fe8f3f0a24cf7a44/screen=ckiDisplayDocument?docId=200000054531628
Hope this helps.
thanks
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-27-2001 07:05 AM
09-27-2001 07:05 AM
Re: commands to replace mirrored copy of root disk
Richard
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-27-2001 07:52 AM
09-27-2001 07:52 AM
Re: commands to replace mirrored copy of root disk
The name of the volumes and devices must surely edited:
#!/bin/sh
# Recreate a mirror of the boot disk.
# Make sure the disk is removed from the group by using
# vgreduce. Alternatively you could edit the vg00
# definition to remove the references to this disk.
vgreduce /dev/vg00 /dev/dsk/c2t2d0
# Make the disk contain a boot area.
pvcreate -f -B /dev/rdsk/c2t2d0
# Add the mirrored disk back to the group.
vgextend /dev/vg00 /dev/dsk/c2t2d0
# Copy the boot area to the disk.
mkboot /dev/rdsk/c2t2d0
mkboot -a 'hpux -lq' /dev/rdsk/c2t2d0
mkboot -a 'hpux -lq' /dev/rdsk/c1t2d0
# Allocate the mirrors. Mirrors must be allocated for all
# logical volumes that were previously mirrored. This
# example illustrates primary swap and root. You should
# add others as needed.
lvextend -m 1 /dev/vg00/lvol1 /dev/dsk/c2t2d0
lvextend -m 1 /dev/vg00/lvol2 /dev/dsk/c2t2d0
lvextend -m 1 /dev/vg00/lvol3 /dev/dsk/c2t2d0
lvextend -m 1 /dev/vg00/lvol5 /dev/dsk/c2t2d0
lvextend -m 1 /dev/vg00/lvol4 /dev/dsk/c2t2d0
lvextend -m 1 /dev/vg00/lvol6 /dev/dsk/c2t2d0
lvextend -m 1 /dev/vg00/lvol7 /dev/dsk/c2t2d0
lvextend -m 1 /dev/vg00/lvol8 /dev/dsk/c2t2d0
lvextend -m 1 /dev/vg00/lvsamba /dev/dsk/c2t2d0
# Update the BDRA and the LABEL file.
lvlnboot -R
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-27-2001 09:02 AM
09-27-2001 09:02 AM
Re: commands to replace mirrored copy of root disk
Richard Darling
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-11-2001 07:09 AM
10-11-2001 07:09 AM
Re: commands to replace mirrored copy of root disk
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-11-2001 07:20 AM
10-11-2001 07:20 AM
Re: commands to replace mirrored copy of root disk
Richard Darling
Replace Mirrored Boot Disk
# Shutdown your system and replace the disk that is failing.
# Boot into single user mode and override the quorum, as:
# ISL> hpux -is -lq /stand/vmunix
# vgcfgrestore -n /dev/vg00 /dev/rdsk/cXtYdZ
# vgchange -a y /dev/vg00
# mount /usr
# mkboot /dev/rdsk/cXtYdZ
# mkboot -a "hpux -lq /stand/vmunix" /dev/rdsk/CXtYdZ
# lvlnboot -R
# lvlnboot -v #...to verify all is as desired...
# vgsync /dev/vg00
# shutdown -ry 0
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-11-2001 08:18 AM
10-11-2001 08:18 AM
SolutionThe recent ITRC maintenance *changed* links. The older links have the string "1.1150". Simply change that to "1,11866" and you will be able to retrace old replies. I have asked *repeatedly* for a conversion of existing threads!!!
Thus, my original post can be found here:
http://forums.itrc.hp.com/cm/QuestionAnswer/1,11866,0xf890abe92dabd5118ff10090279cd0f9,00.html
Regards!
...JRF...