how to make a mirror

 
Ignacio Rodríguez Arrós
Frequent Advisor

how to make a mirror

I have to disk on my sistem, c0t0d0 and c1t0d0 of 16 Gb each, that i want to mirror.They are configured in this way:
/dev/vg02/lvol1 with 8 Gb. This 8 Gb are mirrored (8 in c0t0d0 and 8 in c1t0d0).
/dev/vg02/lvol2 with 8 Gb only in c0t0d0, not mirrored.
this is (lvol2) the one i want to mirror using the 8 Gb free on c1t0d0.
The answer is:
Is this sentence correct:
lvextend -m 1 /dev/vg02/lvol2 /dev/dsk/c1t0d0
if so, is this all that i have to do?, and can i do it while people is working on the system?
6 REPLIES 6
Helen French
Honored Contributor

Re: how to make a mirror

1) Yes, that's the only thing you need to do. For safe side, I would create recovery tape updates and backups before doing this.
2) You can do this online when peoples are working.
Life is a promise, fulfill it!
Dario_1
Trusted Contributor

Re: how to make a mirror

twang
Honored Contributor

Re: how to make a mirror

The general steps for creating mirror boot disk:

/dev/dsk/c2t2d0 will be the disk we want to
create a mirror copy for the existing root disk
(/dev/dsk/c1t2d0) inside the same vg, vg00
if c2t2d0 already belongs to vg00, pls do a
vgreduce to free this disk first

1) vgreduce /dev/vg00 /dev/dsk/c2t2d0

2) pvcreate -B /dev/rdsk/c2t2d0
3) mkboot -l /dev/rdsk/c2t2d0
4) mkboot -a "hpux -lq (;0)/stand/vmunix" /dev/rdsk/c2t2d0
5) vgextend /dev/vg00 /dev/dsk/c2t2d0
6) 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/lvol4 /dev/dsk/c2t2d0
lvextend -m 1 /dev/vg00/lvol5 /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
7) pls check for if:
lvol1 on /stand (this is boot lv)
lvol3 on / (this is root lv)
lvol2 is swap lv

8) lvlnboot -r /dev/vg00/lvol3 (root on /)
9) lvlnboot -s /dev/vg00/lvol2 (swap)
lvlnboot -d /dev/vg00/lvol2 (dump) (optional)
10) lvlnboot -R /dev/vg00
11) lvlnboot -v (to confirm all correct)
12) vgcfgbackup /dev/vg00
Ignacio Rodríguez Arrós
Frequent Advisor

Re: how to make a mirror

Thanks all of you for your fast reply, i want to give 10 points to Shiju wilson who give the exact answer to my question, but as always happens to me, i put the points and they disappear, i can??t assign points and nobody could tell me why, i??m sorry.
Patrick Wallek
Honored Contributor

Re: how to make a mirror

If the points don't get assigned the first time you try, try it again. I normally have to assign points twice before they actually stick.

Note that twang's response is only if you are creating a mirrored BOOT DISK, which you are not. As Shiju said, your statement will work fine. Yes you can do this while people are working on the system. It may slow them down a bit while the mirror is syncing, but hopefully not too bad.
Dario_1
Trusted Contributor

Re: how to make a mirror

Ignasio:

Just go to the post again, assign the points and press submit. Sometimes you have to do it a few times.

Regards,

DR