- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- mirroring multiple disks quickly
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
08-01-2002 12:22 AM
08-01-2002 12:22 AM
I realise that I can create my LV on three disks then lvextend -m it onto the other three disks but that will take a long time. What is the fastest way to achieve this?
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-01-2002 12:34 AM
08-01-2002 12:34 AM
Re: mirroring multiple disks quickly
Here's a script I use to just mirror the entire root volume group:
#!/bin/sh
DISK=c2t2d0
pvcreate -B /dev/rdsk/$DISK
mkboot /dev/rdsk/$DISK
vgextend /dev/vg00 /dev/dsk/$DISK
ls /dev/vg00/lv* | while read LVOL
do
lvextend -m 1 $LVOL /dev/dsk/$DISK
done
You'll have to modify it to meet your requirements though.
Cheers!
James
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-01-2002 12:45 AM
08-01-2002 12:45 AM
Re: mirroring multiple disks quickly
lvcreate vgxx
Then extend to the three "source" disks
lvextend -L
Create the Filesystem
newfs -F vxfs -o largefiles /dev/vgxx/rlvolyy
mount it (directly or by editing /etc/fstab)
And then make the mirror (with the disks in appropiate order)
lvextend -m 1 /dev/vgxx/lvolyy /dev/dsk/d ../e ../f
The time depends on the type of disk you use... but now you can work normally
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-01-2002 12:48 AM
08-01-2002 12:48 AM
Re: mirroring multiple disks quickly
First of all create de vgxx!!!
pvcreate /dev/rdsk/...a
pvcreate /dev/rdsk/...b
pvcreate /dev/rdsk/...c
pvcreate /dev/rdsk/...d
pvcreate /dev/rdsk/...e
pvcreate /dev/rdsk/...f
mkdir /dev/vgxx
mknod /dev/vgxx/group c 64 0x050000
(the major number must be unique! Check it with ll /dev/*/group)
vgcreate vgxx /dev/dsk/...a
vgextend vgxx /dev/dsk...b /dev/dsk...c /dev/dsk...d /dev/dsk...e /dev/dsk...f
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-01-2002 01:03 AM
08-01-2002 01:03 AM
Re: mirroring multiple disks quickly
If I was doing this on a single disk then I would create a 0 size LV on one disk, lvextend -m it onto the second disk then lvextend -L the LV which automatically extends the Lv and the mirror. My understanding is that this is faster than creating the LV at its full size and then mirroring it.
How do I do this with six disks rather than two?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-01-2002 01:16 AM
08-01-2002 01:16 AM
Re: mirroring multiple disks quickly
lvcreate -L 4 /dev/vg01 a
lvextend -L 8 /dev/vg01/lvol1 b
lvextend -L 12 /dev/vg01/lvol1 c
So now, you have created a 12MB volume which uses 4MB on disks a, b and c. Now, create your mirror with
lvextend -m 1 /dev/vg01/lvol1 d e f
and now you can extend as much as you can and it will extend as a mirrored volume on the 6 disks. If you would like to see how the logical extends are actually mapped to the physical extends (LV PE to PV PE), then do lvdisplay -v /dev/vg00/lvol1 | more
Hope this helps,
George
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-01-2002 01:33 AM
08-01-2002 01:33 AM
Solutionyou must use two PVGs
When you create the VG with the vgextend command create teo PVG
vgextend -g PVG1 /dev/dsk/...a ...b ...c
vgextend -g PVG2 /dev/dsk/...d ...e ...f
create the LV with strict policy
lvcreate -s g vgxx
and then extend the LV in 1 PE
lvextend -l 1 /dev/vgxx/lvyy /dev/dsk/...a
lvextend -m 1 /dev/vgxx/lvyy PVG2
Now assign all the extensions... the mirror will be instant
lvextend -l
Be carefull in the order you first assign PV to the VG and the PVG. This order be used to assign the extends
Hope that this help you!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-01-2002 01:33 AM
08-01-2002 01:33 AM
Re: mirroring multiple disks quickly
Can I lvcreate a zero byte LV on the first disk then do an lvextend -m1 and specify three disks and then lvextend the LV onto the first three disks?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-01-2002 01:38 AM
08-01-2002 01:38 AM
Re: mirroring multiple disks quickly
that is perfect. Thanks to all who replied.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-01-2002 01:45 AM
08-01-2002 01:45 AM
Re: mirroring multiple disks quickly
George