- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Re: How to migrate Data from one PV to another PV....
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
06-15-2006 09:50 AM
06-15-2006 09:50 AM
How to migrate Data from one PV to another PV.?
Thanks in advance.
I want to migrate Data from One disk to another disk.By using pvmove command how can i achieve this task.
Problem:
One of the LV in that disk is occupied more than one disk and need to that data to be migrated on more than one disk.Please help us to achieve this task
Details:
root@:/home# vgdisplay -v /dev/vg01_data
--- Volume groups ---
VG Name /dev/vg01_data
VG Write Access read/write
VG Status available
Max LV 255
Cur LV 3
Open LV 3
Max PV 16
Cur PV 6
Act PV 6
Max PE per PV 17263
VGDA 12
PE Size (Mbytes) 8
Total PE 32358
Alloc PE 32356
Free PE 2
Total PVG 0
Total Spare PVs 0
Total Spare PVs in use 0
--- Logical volumes ---
LV Name /dev/vg01_data/lvdata01
LV Status available/syncd
LV Size (Mbytes) 86288
Current LE 10786
Allocated PE 10786
Used PV 1
LV Name /dev/vg01_data/lvdata02
LV Status available/syncd
LV Size (Mbytes) 86288
Current LE 10786
Allocated PE 10786
Used PV 2
LV Name /dev/vg01_data/lvdata03
LV Status available/syncd
LV Size (Mbytes) 86272
Current LE 10784
Allocated PE 10784
Used PV 4
--- Physical volumes ---
PV Name /dev/dsk/c8t2d5
PV Status available
Total PE 17260
Free PE 0
Autoswitch On
PV Name /dev/dsk/c8t2d4
PV Status available
Total PE 4314
Free PE 0
Autoswitch On
PV Name /dev/dsk/c8t3d5
PV Status available
Total PE 4314
Free PE 2
Autoswitch On
PV Name /dev/dsk/c8t3d6
PV Status available
Total PE 4314
Free PE 0
Autoswitch On
PV Name /dev/dsk/c8t3d2
PV Status available
Total PE 1078
Free PE 0
Autoswitch On
PV Name /dev/dsk/c8t3d3
PV Status available
Total PE 1078
Free PE 0
Autoswitch On
================================================
root@ms:/home# lvdisplay -v /dev/vg01_data/lvdata01 |more
--- Logical volumes ---
LV Name /dev/vg01_data/lvdata01
VG Name /dev/vg01_data
LV Permission read/write
LV Status available/syncd
Mirror copies 0
Consistency Recovery MWC
Schedule parallel
LV Size (Mbytes) 86288
Current LE 10786
Allocated PE 10786
Stripes 0
Stripe Size (Kbytes) 0
Bad block NONE
Allocation strict
IO Timeout (Seconds) default
--- Distribution of logical volume ---
PV Name LE on PV PE on PV
/dev/dsk/c8t2d5 10786 10786
--- Logical extents ---
LE PV1 PE1 Status 1
00000 /dev/dsk/c8t2d5 00000 current
===================================================
root@:/home# lvdisplay -v /dev/vg01_data/lvdata02 |more
--- Logical volumes ---
LV Name /dev/vg01_data/lvdata02
VG Name /dev/vg01_data
LV Permission read/write
LV Status available/syncd
Mirror copies 0
Consistency Recovery MWC
Schedule parallel
LV Size (Mbytes) 86288
Current LE 10786
Allocated PE 10786
Stripes 0
Stripe Size (Kbytes) 0
Bad block NONE
Allocation strict
IO Timeout (Seconds) default
--- Distribution of logical volume ---
PV Name LE on PV PE on PV
/dev/dsk/c8t2d5 6474 6474
/dev/dsk/c8t3d5 4312 4312
--- Logical extents ---
LE PV1 PE1 Status 1
00000 /dev/dsk/c8t2d5 10786 current
00001 /dev/dsk/c8t2d5 10787 current
==============================================
root@ms:/home# lvdisplay -v /dev/vg01_data/lvdata03 |more
--- Logical volumes ---
LV Name /dev/vg01_data/lvdata03
VG Name /dev/vg01_data
LV Permission read/write
LV Status available/syncd
Mirror copies 0
Consistency Recovery MWC
Schedule parallel
LV Size (Mbytes) 86272
Current LE 10784
Allocated PE 10784
Stripes 0
Stripe Size (Kbytes) 0
Bad block NONE
Allocation strict
IO Timeout (Seconds) default
--- Distribution of logical volume ---
PV Name LE on PV PE on PV
/dev/dsk/c8t2d4 4314 4314
/dev/dsk/c8t3d6 4314 4314
/dev/dsk/c8t3d2 1078 1078
/dev/dsk/c8t3d3 1078 1078
--- Logical extents ---
LE PV1 PE1 Status 1
00000 /dev/dsk/c8t2d4 00000 current
00001 /dev/dsk/c8t2d4 00001 current
==============================================
Assigned disk to be migrated :
For logical volume lvdata01:
---------------------------------------------
root@ms:/home# diskinfo /dev/rdsk/c13t0d3
SCSI describe of /dev/rdsk/c13t0d3:
vendor: DGC
product id: CX700WDR5
type: direct access
size: 26214400 Kbytes
bytes per sector: 512
root@ms:/home# diskinfo /dev/rdsk/c12t0d2
SCSI describe of /dev/rdsk/c12t0d2:
vendor: DGC
product id: CX700WDR5
type: direct access
size: 31457280 Kbytes
bytes per sector: 512
root@ms:/home#
root@ms:/home# diskinfo /dev/rdsk/c13t0d1
SCSI describe of /dev/rdsk/c13t0d1:
vendor: DGC
product id: CX700WDR5
type: direct access
size: 31457280 Kbytes
bytes per sector: 512
root@ms:/home#
---------------------------------------------
For logical volume lvdata02:
---------------------------------------
root@ms:/home# diskinfo /dev/rdsk/c12t0d4
SCSI describe of /dev/rdsk/c12t0d4:
vendor: DGC
product id: CX700WDR5
type: direct access
size: 31457280 Kbytes
bytes per sector: 512
root@ms:/home#
root@ms:/home# diskinfo /dev/rdsk/c13t0d5
SCSI describe of /dev/rdsk/c13t0d5:
vendor: DGC
product id: CX700WDR5
type: direct access
size: 31457280 Kbytes
bytes per sector: 512
root@ms:/home#
root@ms:/home# diskinfo /dev/rdsk/c12t0d6
SCSI describe of /dev/rdsk/c12t0d6:
vendor: DGC
product id: CX700WDR5
type: direct access
size: 26214400 Kbytes
bytes per sector: 512
===================================
For logical volume lvdata03:
--------------------------------------------
root@ms:/home# diskinfo /dev/rdsk/c13t0d7
SCSI describe of /dev/rdsk/c13t0d7:
vendor: DGC
product id: CX700WDR5
type: direct access
size: 31457280 Kbytes
bytes per sector: 512
root@ms:/home# diskinfo /dev/rdsk/c12t1d0
SCSI describe of /dev/rdsk/c12t1d0:
vendor: DGC
product id: CX700WDR5
type: direct access
size: 31457280 Kbytes
bytes per sector: 512
root@ms:/home# diskinfo /dev/rdsk/c13t1d1
SCSI describe of /dev/rdsk/c13t1d1:
vendor: DGC
product id: CX700WDR5
type: direct access
size: 26214400 Kbytes
bytes per sector: 512
root@ms:/home#
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-15-2006 10:04 AM
06-15-2006 10:04 AM
Re: How to migrate Data from one PV to another PV.?
The manpages for 'pvmove' offer some very good examples of migrating logical extents including limiting the movement by logical volume.
http://www.docs.hp.com/en/B2355-60127/pvmove.1M.html
One caution. Do *not* interrupt the 'pvmove' once started. If you do, you may not be able to access all of your extents. You can do the operation during normal operations, although the process is I/O intensive.
Regards!
...JRF...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-15-2006 10:22 AM
06-15-2006 10:22 AM
Re: How to migrate Data from one PV to another PV.?
Thanks for the response.
In that example only they are given only for single disk.
If the LV has occupied 2 disks or more than that ,how can proceed.
As i has given details above:
lvdata02 spreaded for 2 disks and for that i have 3 disks to migrate.
how can i perform this tasks.
is it possible to migrate in this scnario,
please help me.
root@:/home# lvdisplay -v /dev/vg01_data/lvdata02 |more
--- Logical volumes ---
LV Name /dev/vg01_data/lvdata02
VG Name /dev/vg01_data
LV Permission read/write
LV Status available/syncd
Mirror copies 0
Consistency Recovery MWC
Schedule parallel
LV Size (Mbytes) 86288
Current LE 10786
Allocated PE 10786
Stripes 0
Stripe Size (Kbytes) 0
Bad block NONE
Allocation strict
IO Timeout (Seconds) default
--- Distribution of logical volume ---
PV Name LE on PV PE on PV
/dev/dsk/c8t2d5 6474 6474
/dev/dsk/c8t3d5 4312 4312
-----------------------
To migrate on below disks:
-------------
For logical volume lvdata02:
---------------------------------------
root@ms:/home# diskinfo /dev/rdsk/c12t0d4
SCSI describe of /dev/rdsk/c12t0d4:
vendor: DGC
product id: CX700WDR5
type: direct access
size: 31457280 Kbytes
bytes per sector: 512
root@ms:/home#
root@ms:/home# diskinfo /dev/rdsk/c13t0d5
SCSI describe of /dev/rdsk/c13t0d5:
vendor: DGC
product id: CX700WDR5
type: direct access
size: 31457280 Kbytes
bytes per sector: 512
root@ms:/home#
root@ms:/home# diskinfo /dev/rdsk/c12t0d6
SCSI describe of /dev/rdsk/c12t0d6:
vendor: DGC
product id: CX700WDR5
type: direct access
size: 26214400 Kbytes
bytes per sector: 512
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-15-2006 10:30 AM
06-15-2006 10:30 AM
Re: How to migrate Data from one PV to another PV.?
First, you are going to have to 'pvcreate' and 'vgextend' your new, destination disks into the volume group.
Then, having done this, you can move as appropriate. When done, you would simple 'vgreduce' the old, unused physical volumes.
Regards!
...JRF...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-15-2006 10:48 AM
06-15-2006 10:48 AM
Re: How to migrate Data from one PV to another PV.?
Thanks for the prompt reply.
Yes first i will do pvcreate and vgextend...
after that in my scnario..
Can you please provide the details for any one of the lv(data02 or 03),as this lv's are occupied 2 disks.
Thanks
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-15-2006 10:49 AM
06-15-2006 10:49 AM
Re: How to migrate Data from one PV to another PV.?
Thanks for the prompt reply.
Yes first i will do pvcreate and vgextend...
after that in my scnario..
Can you please provide the details to excecute pvmove command for any one of the lv(data02 or 03),as this lv's are occupied 2 disks.
thanks
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-15-2006 11:05 AM
06-15-2006 11:05 AM
Re: How to migrate Data from one PV to another PV.?
dd if=/dev/vg01_data/lvdata02 of=/dev/vg01_data/new_lvdata02 bs=8k
~cheers
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-15-2006 11:53 AM
06-15-2006 11:53 AM
Re: How to migrate Data from one PV to another PV.?
Given the manpage syntax:
/usr/sbin/pvmove [-A autobackup] [-n lv_path] source_pv_path [dest_pv_path ... | dest_pvg_name ...]
...you can see that only one 'source_pv_path' is allowed at a time, whereas one or more 'dest_pv_path'(s) may be given.
Thus, you can either move all of one physical disk to another, or you can specify a parts of a logical volume at a time. That is, you can perform migration for "lvdata02" first from "/dev/dsk/c8t2d5" to a destination volume in one operation; and then the remainder of "lvdata02" residing on "/dev/dsk/c8t3d5" to a destination volume or volumes in a second operation.
The LVM command, 'pvmove' is a poor-man's mirror operation. It actually uses some of the same code that MirrorDisk/UX uses although, unlike MirrorDIsk/UX, 'pvmove' is free. I point this out only to reinforce the concept that 'pvmove' operates at the logical volume's logical extent level.
Regards!
...JRF...