1822381 Members
3093 Online
109642 Solutions
New Discussion юеВ

Boot mirror

 
Prashant Zanwar_4
Respected Contributor

Boot mirror

Hi,
I am planning to split root mirror. Remove all lvolxb and recreate mirror.
In this i doubt what shall do about /stand as it is a HFS FS. And what else is recommended when I do so.
Thanks and regards
Prashant
"Intellect distinguishes between the possible and the impossible; reason distinguishes between the sensible and the senseless. Even the possible can be senseless."
18 REPLIES 18
Gary L. Paveza, Jr.
Trusted Contributor

Re: Boot mirror

Shouldn't make any difference what filesystem type it is. Mirroring is done the same regardless of whether it is vxfs, hfs, swap, or raw. You mirror at the logical volume level, not the filesystem.
Pete Randall
Outstanding Contributor

Re: Boot mirror

You mirror /stand just like the other lvols. It makes no difference what the type of file system is.


Pete

Pete
Patrick Wallek
Honored Contributor

Re: Boot mirror

If you want to remirror your VG00, why are you splitting the mirrors? In my opinion you should just reduce them so that the mirror count is 0 (lvreduce -m 0 /dev/vg00/lvol?) and then remirror (lvextend -m 1 /dev/vg00/lvol?).

Craig Rants
Honored Contributor

Re: Boot mirror

Don't forget mkboot and lvlnboot to get the AUTO lif info onto your new mirror disk.



GL,
C
"In theory, there is no difference between theory and practice. But, in practice, there is. " Jan L.A. van de Snepscheut
Sundar_7
Honored Contributor

Re: Boot mirror

I do remember, it is extremely important that LVs are mirrored in the order they are created on VG00.

As noted above, MirrorDx/UX deals with Lvols and not with filesystem. So it should not make any difference.

You dont have to remove any lvols, just lvreduce them and lvextend.

If you need to change the allocation policy on the LV change it to strict or PVG-strict using lvchange command before doing so.

If PVG-Strict, you need to create /etc/lvmpvg

Learn What to do ,How to do and more importantly When to do ?
Prashant Zanwar_4
Respected Contributor

Re: Boot mirror

Hi,
I have set it PVG-strict. And also I am able to mirror all across. I want to know what makes it possible to mirror across same physical extent of the other disk. Isn't the strict policy sufficient as I am seeing it is mirrored across different physical mapping of the LV. Please reply
Thanks anf rgdz
Prashant
"Intellect distinguishes between the possible and the impossible; reason distinguishes between the sensible and the senseless. Even the possible can be senseless."
Sundar_7
Honored Contributor

Re: Boot mirror

Yes strict allocation is good enough in most of the cases.

In PVG-strict, you inturn need to create PVG groups, ideally each PVG listing the disks connected to a different controller.

When a LV with PVG-strict allocation policy is mirroed, it will be mirrored to one of the disks in a PVG other than the one the disk that holds the LV is currently member of.

PVG-strict allows you to elimiate the controller as a single point of failure.
Learn What to do ,How to do and more importantly When to do ?
Prashant Zanwar_4
Respected Contributor

Re: Boot mirror

As I have mirrored I am seeing that it has caused different physical extent numbers from two disks to sync. Can it be problem, what is required to make it 1-1 sync.
Thanks I really appreciate all replies.
Rgdz
Prashant
"Intellect distinguishes between the possible and the impossible; reason distinguishes between the sensible and the senseless. Even the possible can be senseless."
Sundar_7
Honored Contributor

Re: Boot mirror

I think it matters only for root,boot and swap volumes.

Do you mean the PE1 and PE2 number do not match for a LV ? which LV is that ?

If you have mirrored them in order then there is no way this could happen

# for LV in 1 2 3 4 5 6 7 8
do
lvreduce -m 0 /dev/vg00/lvol${LV}
lvchange -s g /dev/vg00/lvol${LV}
lvextend -m 1 /dev/vg00/lvol${LV}
done

-- Sundar.
Learn What to do ,How to do and more importantly When to do ?
Geoff Wild
Honored Contributor

Re: Boot mirror

When recreating, I follow these steps:

Say /dev/dsk/c0t6d0 is the root disk and /dev/dsk/c3t6d0 is the disk you want to make a mirror of.

1. Create a bootable LVM disk to be used for the mirror.
pvcreate -B /dev/rdsk/c3t6d0
2. Add this disk to the current root volume group.
vgextend /dev/vg00 /dev/dsk/c3t6d0
3. Make the new disk a boot disk.
mkboot -l /dev/rdsk/c3t6d0
4. Copy the correct AUTO file into the new LIF area.
mkboot -a "hpux -lq (;0)/vmunix" /dev/rdsk/c3t6d0
5. Mirror the boot, root and primary swap logical volumes to the new
bootable disk. Ensure that all devices in vg00, such as /usr, /swap,
etc., are mirrored.
The following is an example of mirroring the boot logical volume:
lvextend -m 1 /dev/vg00/lvol1 /dev/dsk/c3t6d0
The following is an example of mirroring the primary swap logical
volume:
lvextend -m 1 /dev/vg00/lvol2 /dev/dsk/c3t6d0
The following is an example of mirroring the root logical volume:
lvextend -m 1 /dev/vg00/lvol3 /dev/dsk/c3t6d0
6. Update the boot information contained in the BDRA for the mirror
copies of boot, primary swap and root.
/usr/sbin/lvlnboot -b /dev/vg00/lvol1
/usr/sbin/lvlnboot -s /dev/vg00/lvol2
/usr/sbin/lvlnboot -r /dev/vg00/lvol3
7. Check if the BDRA is correct.
/usr/sbin/lvlnboot -R /dev/vg00
8. Verify that the mirrors were properly created.
lvlnboot -v /dev/vg00
The output of this command is shown in a display like the following:
Boot Definitions for Volume Group /dev/vg00:
Boot Definitions for Volume Group /dev/vg00:
Physical Volumes belonging in Root Volume Group:
/dev/dsk/c0t6d0 (1/0/0/3/0.6.0) -- Boot Disk
/dev/dsk/c3t6d0 (1/0/1/0/0/1/1.6.0) -- Boot Disk
Boot: lvol1 on: /dev/dsk/c0t6d0
/dev/dsk/c3t6d0
Root: lvol3 on: /dev/dsk/c0t6d0
/dev/dsk/c3t6d0
Swap: lvol2 on: /dev/dsk/c0t6d0
/dev/dsk/c3t6d0
Dump: lvol2 on: /dev/dsk/c0t6d0, 0

vgdisplay -v vg00

Then lvextend for all other lvols:

lvextend -m 1 /dev/vg00/lvol4 /dev/dsk/c3t6d0
lvextend -m 1 /dev/vg00/lvol5 /dev/dsk/c3t6d0
lvextend -m 1 /dev/vg00/lvol6 /dev/dsk/c3t6d0
lvextend -m 1 /dev/vg00/lvol7 /dev/dsk/c3t6d0
lvextend -m 1 /dev/vg00/lvol8 /dev/dsk/c3t6d0
lvextend -m 1 /dev/vg00/lvol9 /dev/dsk/c3t6d0
lvextend -m 1 /dev/vg00/lvol10 /dev/dsk/c3t6d0
lvextend -m 1 /dev/vg00/lvol11 /dev/dsk/c3t6d0

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.
Prashant Zanwar_4
Respected Contributor

Re: Boot mirror

Hi,
I did as recommended like
for lv in lvol1 lvol2 lvol3 ...
do
lvreduce -m 0 $LV
lvchange -s g $LV
lvextend -m 1 $LV
done
Still it is showing PV1 PV2 different starting from lvol2 and thus ahead.
Is it a serious problem. Can I overcome it?
Thanks
best regards
Prashant
"Intellect distinguishes between the possible and the impossible; reason distinguishes between the sensible and the senseless. Even the possible can be senseless."
Sundar_7
Honored Contributor

Re: Boot mirror

can you post the output here ?
Learn What to do ,How to do and more importantly When to do ?
Prashant Zanwar_4
Respected Contributor

Re: Boot mirror

I am just trying it again as it hasnt mirrored lvol4 in between saying not enough physical extents availeble. Rest all it is doing alright, but again PE1 - PE2 are not matching. I will post results once I am done successfully mirroring.
Thanks and rgdz
Prashant
"Intellect distinguishes between the possible and the impossible; reason distinguishes between the sensible and the senseless. Even the possible can be senseless."
Prashant Zanwar_4
Respected Contributor

Re: Boot mirror

Now it differs for lvol5 onwards which shall not be problem, right?
Thanks a lot for all responses. It's just great help from all of you. I appreciate it very much.
Cheers
Thanks with best rgdz
Prashant
"Intellect distinguishes between the possible and the impossible; reason distinguishes between the sensible and the senseless. Even the possible can be senseless."
Sundar_7
Honored Contributor

Re: Boot mirror

There is no reason why it should differ at all.

There is something you are missing here :-).
Learn What to do ,How to do and more importantly When to do ?
Prashant Zanwar_4
Respected Contributor

Re: Boot mirror

It really differs. Do you still want to see the output.
Thanks for all help. Do I still need to be concerned for this. As it is differing in PE allocation of PV's of 1-1 policy.
Thanks and rgdz
Prashant
"Intellect distinguishes between the possible and the impossible; reason distinguishes between the sensible and the senseless. Even the possible can be senseless."
Sundar_7
Honored Contributor

Re: Boot mirror

Prashant,

vgdisplay -v /dev/vg00 | grep "LV Name" | awk '{print $3}' | xargs -n1 | while read LV
do
lvdisplay -v $LV
done >>/tmp/lvout 2>&1

ftp /tmp/lvout and attach it here. I am unable to view your attachment.

-- Sundar
Learn What to do ,How to do and more importantly When to do ?
Prashant Zanwar_4
Respected Contributor

Re: Boot mirror

Hi,
It very well opens in wordpad. Please try it.
Thanks and regards
Prashant
"Intellect distinguishes between the possible and the impossible; reason distinguishes between the sensible and the senseless. Even the possible can be senseless."