Operating System - HP-UX
1834370 Members
2020 Online
110066 Solutions
New Discussion

using lvm to extend mirror drive

 
SOLVED
Go to solution
Jerry_109
Super Advisor

using lvm to extend mirror drive

HP-UX B.11.11 U 9000/800
9000/800/A500-7X

Hello All,

What is the correct command to extend the LV on the mirror drive after increasing the primary LV. I increased the primary LV (/dev/vg00/auditlog ).

# bdf /auditlog
Filesystem kbytes used avail %used Mounted on
/dev/vg00/auditlog 2097152 8099 1958541 0% /auditlog
root[/]

**********************************************
--- Logical volumes ---
LV Name /dev/vg00/auditlog
VG Name /dev/vg00
LV Permission read/write
LV Status available/syncd
Mirror copies 1
Consistency Recovery MWC
Schedule parallel
LV Size (Mbytes) 4096
Current LE 512
Allocated PE 1024
Stripes 0
Stripe Size (Kbytes) 0
Bad block on
Allocation strict
IO Timeout (Seconds) default

--- Distribution of logical volume ---
PV Name LE on PV PE on PV
/dev/dsk/c1t15d0 512 512
/dev/dsk/c3t15d0 512 512

--- Logical extents ---
LE PV1 PE1 Status 1 PV2 PE2 Status 2
00000 /dev/dsk/c1t15d0 02768 current /dev/dsk/c3t15d0 02768 current

**********************************************

# lvextend -L 4096 /dev/vg00/auditlog
Logical volume "/dev/vg00/auditlog" has been successfully extended.
Volume Group configuration for /dev/vg00 has been saved in /etc/lvmconf/vg00.conf
roor[/]
# fsadm -F vxfs -b 4194304 /auditlog
vxfs fsadm: /dev/vg00/rauditlog is currently 2097152 sectors - size will be increased
root[/]
# bdf /auditlog
Filesystem kbytes used avail %used Mounted on
/dev/vg00/auditlog 4194304 8613 3924139 0% /auditlog
root@[/]
# vgdisplay -v /dev/vg00 | egrep "PE Size|Free"
PE Size (Mbytes) 8
Free PE 1289
Free PE 613
Free PE 676
root[/]
***********************************************

6 REPLIES 6
RAC_1
Honored Contributor
Solution

Re: using lvm to extend mirror drive

No need to extend mirror. It is done automatically. If you want to check it, split the mirror and do lvdisplay on it.

Anil
There is no substitute to HARDWORK
Uday_S_Ankolekar
Honored Contributor

Re: using lvm to extend mirror drive

It is already have a mirror copy extended..check with lvdisplay comamnd you will see both the disks are part of /dev/vg00/auditlog.

lvdisplay -v /dev/vg00/auditlog


-USA..
Good Luck..
Robert-Jan Goossens
Honored Contributor

Re: using lvm to extend mirror drive

Hi,

No need, check with below command
# lvdisplay -v /dev/vg00/auditlog
You will see that the volume has automaticly been extended on both disks.

Hope this helps,
Robert-Jan
Pete Randall
Outstanding Contributor

Re: using lvm to extend mirror drive

Your original lvextend command would have failed if there had not been enough room to extend both the primary extent and the mirror.


Pete

Pete
kamal_9
Super Advisor

Re: using lvm to extend mirror drive

Hi jerry
No need to extend the LV on the mirror disk after extending the Lv.It will do automatically
Devender Khatana
Honored Contributor

Re: using lvm to extend mirror drive

Hi Jerry,

Extending a lvol when it is mirrored increase the size on both copies so no need to do it seperately. Check it with "lvdisplay -v /dev/vg00/auditlog" and see the state of all physical extents.

00000 /dev/dsk/c1t15d0 02768 current /dev/dsk/c3t15d0 02768 current
00001 /dev/dsk/c1t15d0 02769 current /dev/dsk/c3t15d0 02769 current
.
.
.

All physical extents should be availabe on both disks

HTH,
Devender
Impossible itself mentions "I m possible"