- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Re: Migrating VG from PV
Categories
Company
Local Language
Forums
Discussions
Knowledge Base
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Knowledge Base
Forums
Discussions
- Cloud Mentoring and Education
- Software - General
- HPE OneView
- HPE Ezmeral Software platform
- HPE OpsRamp
Knowledge Base
Discussions
Forums
Discussions
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
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
07-28-2008 05:35 AM
07-28-2008 05:35 AM
Migrating VG from PV
We are planning to get rid of EMC box and I have to migrate some data. On my HP-UX box only one VG (data use only) is on EMC. If i type powermt display dev=all I'll get the following.
11 0/6/0/0.99.4.19.0.0.0 c11t0d0 SP A1 active alive 0 0
13 0/6/0/0.99.8.19.0.0.0 c13t0d0 SP B0 active alive 0 0
5 0/2/0/0.98.4.19.0.0.0 c5t0d0 SP A0 active alive 0 0
7 0/2/0/0.98.8.19.0.0.0 c7t0d0 SP B1 active alive 0 0
If I do "vgdisplay -v" I got this
--- Physical volumes ---
PV Name /dev/dsk/c5t0d0
PV Name /dev/dsk/c7t0d0 Alternate Link
PV Name /dev/dsk/c11t0d0 Alternate Link
PV Name /dev/dsk/c13t0d0 Alternate Link
I want to put a new internal hard drive and run ioscan to create a new /dev/dsk/ device where I want to migrate the VG.
My question is, what is the easiest method of migrating data off of EMC box.
1) If I use pvmove /dev/dsk/c5t0d0 /dev/dsk/newdisk, do I have to do the same for other /dev/dsks that appear under vgdisplay output? What does "alternate link" means?
2) Do I have to vary off VG first before pvmove? What if something changes on the old disk while moving the VG?
3) How do I get rid of the old EMC disks? Should I just use powermt remove dev=something or there is something else that I have to use?
4) Any help appreciated
5) Thanks a lot!!!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-28-2008 05:50 AM
07-28-2008 05:50 AM
Re: Migrating VG from PV
If you have Mirrordisk/UX, use that to migrate your data.
Regards!
...JRF...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-28-2008 06:05 AM
07-28-2008 06:05 AM
Re: Migrating VG from PV
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-28-2008 06:11 AM
07-28-2008 06:11 AM
Re: Migrating VG from PV
My question is, what is the easiest method of migrating data off of EMC box.
1) If I use pvmove /dev/dsk/c5t0d0 /dev/dsk/newdisk, do I have to do the same for other /dev/dsks that appear under vgdisplay output? What does "alternate link" means? You can ignore the alternate links ( they are alternate paths to the same disk )
2) Do I have to vary off VG first before pvmove? What if something changes on the old disk while moving the VG? ( need to quiesce your system, e.g. shutdown all applications, logoff all users, etc...
3) How do I get rid of the old EMC disks? Should I just use powermt remove dev=something or there is something else that I have to use? unpresent the luns from the emc, then cleanup powerpath, then cleanup NO_HW ioscan items.
Again, if you had Mirror/UX you could do this on the fly/on-line..
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-28-2008 06:14 AM
07-28-2008 06:14 AM
Re: Migrating VG from PV
if you don't have many filesystems in the volume group I suggest copying filesystems contents from a VG to the new one:
1) insert the new disk;
2) insf -e -H
3) create the new VG structure on new disk and create filesystems of the same size of the "old" ones;
4) copy contents, cpio should be good enough:
cd /
find . -xdev -print | cpio -pdmvux /
and so on for all filesystems.
At the end diff between them:
diff
In that way you will migrate contents in a smooth way. Of course that should be a big work if you have many many filesystems on the VG.
HTH.
Best regards,
Fabio
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-28-2008 06:24 AM
07-28-2008 06:24 AM
Re: Migrating VG from PV
BTW, there are only 5-6 filesystems and the total size is about 40Gb. I was also thinking to do a backup and restore. The server went out of production, so downtime is not a big deal. We just have to migrate data from EMC, put that on internal hard drives and use the server only for old invoice queries.
I was thinking that pvmove is the easiest way. At least that what it looks like. No umounts, no vary offs, just one simple command.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-28-2008 06:29 AM
07-28-2008 06:29 AM
Re: Migrating VG from PV
> I was thinking that pvmove is the easiest way.
One caveat with 'pvmove': Don't interrupt the process. A failure can leave the logical volume inaccessible with a stale extent.
Regards!
...JRF...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-29-2008 05:15 AM
07-29-2008 05:15 AM
Re: Migrating VG from PV
The disks with "Alternate Link" are just that. An alternate link to the EMC array LUN.
pvmove is the tool for the job, it is the easiest and best way to move the lvols. I wouldn't use it to move the physical volume but the logical volumes one at a time.
The destination will need to be in the same VG.
pvmove uses mirroring but only one extent at a time. Mirrordisk is better and less risky if there is a power outage during the migration.
1/ Add the new HDD
2/ ioscan to find the new HW path
3/ insf -e -H
4/ pvcreate /dev/rdsk/cXtXd0
5/ vgextend to add the new HDD to the VG (Read Note Below)
6/ pvmove each lvol from /dev/dsk/c5t0d0 to new /dev/dsk/cXtXd0
7/ use vgreduce to remove the old EMC disks.
8/ then use powermt to remove the SAN LUNs.
Some words of caution.
What is the maximum PE in the VG?
The default is to be the size of the first added HDDs if using SAM. From your comments that will probably be 40GB. Any HDD larger than the max PE x PE size will not be accessable.
Can you post the details from vgdisplay ?
What is the size of the new disk to be added?
If you are going to lose disk space using this method, you will need to create a new VG and use tar or cpio or dump/restore to migrate the data. 2nd choice though.
Trevor.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-29-2008 05:23 AM
07-29-2008 05:23 AM
Re: Migrating VG from PV
As pvmove uses mirroring of one PE at a time, EG
When using it to move an lvol it allocates a PE on the destination, mirrors the PE, and then breaks off the old PE.
This way it can be done with live lvols and no data changes will be lost. I have done this many times with no failures. Including Oracle DB files. However, there is a potential for a slight disk delay during the migration. Similar to re-syncing disks after a disk failure.
Using the tar, cpio, dump/restore method will incure data integrity issues and the application should be shutdown and NO access/changes to the data during the migration.
Please post the vg data and the new disk size.
Trevor.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-29-2008 05:26 AM
07-29-2008 05:26 AM
Re: Migrating VG from PV
VG Name /dev/vg_prod
VG Write Access read/write
VG Status available
Max LV 255
Cur LV 6
Open LV 6
Max PV 16
Cur PV 1
Act PV 1
Max PE per PV 20480
VGDA 2
PE Size (Mbytes) 4
Total PE 20476
Alloc PE 19175
Free PE 1301
Total PVG 0
Total Spare PVs 0
Total Spare PVs in use 0
--- Logical volumes ---
LV Name /dev/vg_prod/lvol07
LV Status available/syncd
LV Size (Mbytes) 200
Current LE 50
Allocated PE 50
Used PV 1
LV Name /dev/vg_prod/lvol05
LV Status available/syncd
LV Size (Mbytes) 20000
Current LE 5000
Allocated PE 5000
Used PV 1
LV Name /dev/vg_prod/lvol04
LV Status available/syncd
LV Size (Mbytes) 8500
Current LE 2125
Allocated PE 2125
Used PV 1
LV Name /dev/vg_prod/lvol06
LV Status available/syncd
LV Size (Mbytes) 20000
Current LE 5000
Allocated PE 5000
Used PV 1
LV Name /dev/vg_prod/lvol02
LV Status available/syncd
LV Size (Mbytes) 20000
Current LE 5000
Allocated PE 5000
Used PV 1
LV Name /dev/vg_prod/lvol03
LV Status available/syncd
LV Size (Mbytes) 8000
Current LE 2000
Allocated PE 2000
Used PV 1
--- Physical volumes ---
PV Name /dev/dsk/c5t0d0
PV Name /dev/dsk/c7t0d0 Alternate Link
PV Name /dev/dsk/c11t0d0 Alternate Link
PV Name /dev/dsk/c13t0d0 Alternate Link
PV Status available
Total PE 20476
Free PE 1301
Autoswitch On
Proactive Polling On