Operating System - HP-UX
1833181 Members
2831 Online
110051 Solutions
New Discussion

Physical Volume Migration

 
SOLVED
Go to solution
Mihails Nikitins
Super Advisor

Physical Volume Migration

Hello,

I'm looking for the safiest and most elegant way to replace one unmirrored 9 GB disk (let's say A) with two mirrored 18 GB disks (let's say B and C). The system should remain running during the process.

Now | Goal |
Slot 1 A | B |
Slot 2 | C |


This is not a problem for me to create a mirror or two of the existing disk (pvcreate, vgextend, mkboot, lvextend). However, I'm not sure about correct way of removing the existing physical volume and plugging a new disk in the same slot.

Now I see two possible scenarios. The first one is creating one mirror of existing disk (A->B), removing of the old disk and creating one mirror once again (B->C).


Step1 | Step2 | Step3 | Step4
Slot 1 A | A | | C
Slot 2 | B | B | B

The second way could be creating of two mirrors (A->B,C), removing the old disk and moving one of the new disks from Slot3 to Slot 1.

Step1 | Step2 | Step3 | Step4
Slot 1 A | A | | C
Slot 2 | B | B | B
Slot 3 | C | C |

Thank you in advance for any advice!
KISS - Keep It Simple Stupid
10 REPLIES 10
Andreas Voss
Honored Contributor

Re: Physical Volume Migration

Hi,

as long as you don't reboot the system it will not recognize when replacing a 9GB with a 18GB disk at the sam slot. So i think this job can't be done without reboot.

Regards
Sandor Horvath_2
Valued Contributor

Re: Physical Volume Migration

Hi !

Do the first version, it will work, but the second one is dangerous.

regards, Saa
If no problem, don't fixed it.
Ajitkumar Rane
Trusted Contributor

Re: Physical Volume Migration

Actually I dont think there is a problem in using either of the two methods.With the second method you will save time on running the same commands again.Also pvmove is one of the other options you can think of.extend the vg to one of the 18gb disk and pvmove the 9gb disk to the 18gb disk and then mirror it.

Goodluck
Amidsts difficulties lie opportunities
Ajitkumar Rane
Trusted Contributor

Re: Physical Volume Migration

I apolgise for my previous reply. I did not read you Q correctly.
I agree on the reply ofboth the forum members.Without a reboot the task is a bit complicated.Even thou the disk may be hot plug disks, I dont think the system would recognise the disk.You will have to create the device files for the disks manually.Chances are that you might run into trouble.
If you have accomplished this task then the first method is the only method you can go for.If you think of mirroring both the 18gb disk at the same time and then pulling out one of them and pushing it in 9gb slot does not work.The system is going to think one of the mirror copies is lost.It will not identify the disk in 9gb slot as its id is going to change. I dont know if you r thinking of pulling the unmirrored 9gb then pull out the mirror copy of 18 gb, the system will flash errors,change the id on the the 9gb slot to to the id of mirrored 18gb slot, plug the 18 gb in the 9gb slot and do a lvmerge - Dangerous. Also I dont understand if you have tow slots free to plug both the disk in, whats the need to swap one of the disks in the 9gb slot?

Good luck
Amidsts difficulties lie opportunities
Patrick Wallek
Honored Contributor
Solution

Re: Physical Volume Migration

I did not see this mentioned in the other replies, but depending on your volume group configuration, you may have to remove and reconfigure your VG as well. By default, when a volume group is created, it sets the max number of PE's to the size of the largest disk. So if you replace your 9 with an 18, then you will most likely only see half of that disk. This VG parameter can not be changed on the fly.

If you the disk you are wanting to replace is your root disk and has vg00 on it, then I would get the Ignite-UX product, make a make_recovery (or maybe soon make_tape_recovery) tape, shutdown the machine, replace your disk drives, boot the machine from the tape, reset your VG parameters and restore. This method works quite well. I recently migrated my vg00 from 8 mirrored 2GB drives to 2 mirrored 18GB drives.

The easiest way to accomplish the mirroring is to get the OS recovered on one drive and then manually mirror to the other drive. I find that a whole lot easier than messing with an Ignite post recovery script to do the work.

I hope this helps you.
Darrel Louis
Honored Contributor

Re: Physical Volume Migration

Hi,

It's not a problem when replacing a disk with another disk, when they have the same size.
But when replacing a disk with a bigger size, you can reach the max pe limit,
Take that in consideration.

You're first step shouldn't be a problem but check the above first.

Make a good backup + Ignite Recovery tape.

Good Luck
Mihails Nikitins
Super Advisor

Re: Physical Volume Migration

Hi,

Thanks a lot to all of you! In my environment the best solution will be mirroring of old 9 GB disk to 18 GB disk without stopping the system..
Complete migration to 18 GB disks can be done later with ignite when it is possible to stop the system.
KISS - Keep It Simple Stupid
Mihails Nikitins
Super Advisor

Re: Physical Volume Migration

Once more note. As I already found in this Forum,
there is a problem if appending 18 GB to a group consisting of smaller disks.

# vgextend /dev/vg00 /dev/dsk/c0t8d0
vgextend: Not enough physical extents per physical volume.
Need: 4341, Have: 2500.
Volume group "/dev/vg00" has been successfully extended.
Volume Group configuration for /dev/vg00 has been saved in /etc/lvmconf/vg00.conf

I understand this problem of Physical Extents.
Q. Will 18 GB disk work normally in this case (with 9 GB of space available)?
KISS - Keep It Simple Stupid
Henry Weldon
Advisor

Re: Physical Volume Migration

You can go ahead and use the 18Gb disk in your root VG. But you will not be able to access any extents beyond the VG limit. Once you have an outage window you can use Ignite-UX to back it up and restore it to the same disk and change the VG configurations at that time.
Be Prepared
Mihails Nikitins
Super Advisor

Re: Physical Volume Migration

Thank you,

I have already made migration using Ignite.

BR,
Mihails
KISS - Keep It Simple Stupid