- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- lvreduce -m 0 multiple PV's
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
Discussions
Discussions
Forums
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
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
тАО12-12-2007 06:08 AM
тАО12-12-2007 06:08 AM
lvreduce -m 0 multiple PV's
--- Distribution of logical volume ---
PV Name LE on PV PE on PV
/dev/dsk/c6t0d4 4 4
/dev/dsk/c6t0d5 4 4
/dev/dsk/c6t0d6 4 4
/dev/dsk/c6t0d7 4 4
/dev/dsk/c6t1d0 4 4
/dev/dsk/c6t1d1 4 4
/dev/dsk/c6t1d2 4 4
/dev/dsk/c6t1d3 4 4
/dev/dsk/c6t1d4 4 4
/dev/dsk/c6t1d5 4 4
/dev/dsk/c6t1d6 4 4
/dev/dsk/c6t1d7 4 4
/dev/dsk/c12t0d1 2 2
/dev/dsk/c12t0d2 2 2
/dev/dsk/c12t0d3 2 2
/dev/dsk/c12t0d4 2 2
/dev/dsk/c12t0d5 1 1
/dev/dsk/c12t0d6 1 1
/dev/dsk/c12t0d7 1 1
/dev/dsk/c12t1d0 1 1
/dev/dsk/c12t1d1 2 2
/dev/dsk/c12t1d2 2 2
--- Logical extents ---
LE PV1 PE1 Status 1
00000 /dev/dsk/c12t0d1 00000 current
00001 /dev/dsk/c12t0d2 00000 current
00002 /dev/dsk/c12t0d3 00000 current
00003 /dev/dsk/c12t0d4 00000 current
00004 /dev/dsk/c6t0d4 00008 current
00005 /dev/dsk/c6t0d5 00008 current
00006 /dev/dsk/c6t0d6 00008 current
00007 /dev/dsk/c6t0d7 00008 current
00008 /dev/dsk/c6t1d0 00008 current
00009 /dev/dsk/c6t1d1 00008 current
00010 /dev/dsk/c6t1d2 00008 current
00011 /dev/dsk/c6t1d3 00008 current
00012 /dev/dsk/c6t1d4 00008 current
00013 /dev/dsk/c6t1d5 00008 current
00014 /dev/dsk/c6t1d6 00008 current
00015 /dev/dsk/c6t1d7 00008 current
I want to remove all the extents from the c6 disks and keep the c12 disks. Is there any way to accomplish this.
Thanks
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО12-12-2007 06:19 AM
тАО12-12-2007 06:19 AM
Re: lvreduce -m 0 multiple PV's
Are you trying to reduce the mirror or trying to move the extents?
To remove the mirror copy from an lvol, based on the reverse of the mirror sequence, the command
lvreduce -m 0 /dev/
If you wish to move extents, from one device to another (must be in the same volume group, you will need the to use the pvmove command.
e.g. Move the physical extents for logical volume /dev/vg01/lvol1 that are currently on /dev/dsk/c1t0d0 to /dev/dsk/c2t0d0:
pvmove -n /dev/vg01/lvol1 /dev/dsk/c1t0d0 /dev/dsk/c2t0d0
Mike.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО12-12-2007 06:22 AM
тАО12-12-2007 06:22 AM
Re: lvreduce -m 0 multiple PV's
Make a list of the logical volumes you wish to reduce and the disks in a file, lets say colon delimted.
/dev/vg01/lvolname:/dev/dsk/c12t0d4
filename list
read -r fn
do
DL=$fn
LVN=$(echo $fn | awk -F: '{print $1}'
DSN=$(echo $fn | awk -F: '{print $2}'
# may be okay
lvreduce -m 0 $LVN
# more precise
lvreduce -m 0 $LVN $DSN
done < list
SEP
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО12-12-2007 06:25 AM
тАО12-12-2007 06:25 AM
Re: lvreduce -m 0 multiple PV's
Is the LVOL really mirrored?
Hope this helps!
Regards
Torsten.
__________________________________________________
There are only 10 types of people in the world -
those who understand binary, and those who don't.
__________________________________________________
No support by private messages. Please ask the forum!
If you feel this was helpful please click the KUDOS! thumb below!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО12-12-2007 06:28 AM
тАО12-12-2007 06:28 AM
Re: lvreduce -m 0 multiple PV's
00000 /dev/dsk/c6t0d0 00012 current /dev/dsk/c12t0d1 00007 current
00001 /dev/dsk/c6t0d1 00012 current /dev/dsk/c12t0d2 00007 current
00002 /dev/dsk/c6t0d2 00012 current /dev/dsk/c12t0d3 00007 current
00003 /dev/dsk/c6t0d3 00012 current /dev/dsk/c12t0d4 00007 current
00004 /dev/dsk/c6t0d4 00012 current /dev/dsk/c12t0d5 00006 current
00005 /dev/dsk/c6t0d5 00012 current /dev/dsk/c12t0d6 00006 current
00006 /dev/dsk/c6t0d6 00012 current /dev/dsk/c12t0d7 00006 current
00007 /dev/dsk/c6t0d7 00012 current /dev/dsk/c12t1d0 00006 current
00008 /dev/dsk/c6t1d0 00012 current /dev/dsk/c12t1d1 00006 current
00009 /dev/dsk/c6t1d1 00012 current /dev/dsk/c12t1d2 00006 current
00010 /dev/dsk/c6t1d2 00012 current /dev/dsk/c12t0d1 00008 current
00011 /dev/dsk/c6t1d3 00012 current /dev/dsk/c12t0d2 00008 current
00012 /dev/dsk/c6t1d4 00012 current /dev/dsk/c12t0d3 00008 current
00013 /dev/dsk/c6t1d5 00012 current /dev/dsk/c12t0d4 00008 current
00014 /dev/dsk/c6t1d6 00012 current /dev/dsk/c12t0d5 00007 current
00015 /dev/dsk/c6t1d7 00012 current /dev/dsk/c12t0d6 00007 current
I want to remove the c6 PV's and keep the c12 PV's
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО12-12-2007 06:31 AM
тАО12-12-2007 06:31 AM
Re: lvreduce -m 0 multiple PV's
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО12-12-2007 06:38 AM
тАО12-12-2007 06:38 AM
Re: lvreduce -m 0 multiple PV's
Steve's answer looks good to solve your problem, specifically remove the mirrored extents from c6 disks.
eg
lvreduce -m 0 /dev/
Mike.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО12-12-2007 06:44 AM
тАО12-12-2007 06:44 AM
Re: lvreduce -m 0 multiple PV's
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО12-12-2007 07:33 AM
тАО12-12-2007 07:33 AM
Re: lvreduce -m 0 multiple PV's
pvmove -n /dev/vg/lvol
What your take.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО12-12-2007 08:23 AM
тАО12-12-2007 08:23 AM
Re: lvreduce -m 0 multiple PV's
Your take looks correct, but it took several reads to visualise your predicamant.
However, I would suggest that as a precaution that you always have a backup of the data before you start moving data around on disks.
Mike.