Operating System - HP-UX
1753393 Members
7099 Online
108792 Solutions
New Discussion юеВ

removing disk from volume group where associated lvm's are mirrored with stripping...

 
SOLVED
Go to solution
sabinkarvijay
Frequent Advisor

removing disk from volume group where associated lvm's are mirrored with stripping...

Hi All,

We would like to replace one of the hard disk in Hp Ux 11iv1(B.11.11), I am not sure on how to remove the specific Physical Volume from Volume group and make the disk available for the hardware engineer to replace the new disk in place of old one:

I have attached the outputs of different commands which will give an idea.

I am aware of pre-disk replacement tasks for normal lvm mirrored disk, if i am right:

for normal lvm one, we can fallow the below:

1) firstly we will reduce the mirror from each logical volume

2) then will remove the physical volume from the volume group

once it's done, we will ask the hardware engineer to replace the existing one with a new disk.

For this case where the logical volume is mirrored with stripping, how we need to proceed?

Please let me know if you need any further information on this...


Thanks in Advance,

Regards,
Vijay Sabinkari.
18 REPLIES 18
Steven E. Protter
Exalted Contributor
Solution

Re: removing disk from volume group where associated lvm's are mirrored with stripping...

Shalom,

Take your steps until pvdisplay shows the disk is clean of all logical volume information.

Then you can vgreduce the disk out of the volume group.

If the disk is in need of replacement you may run into trouble. A guide.

http://docs.hp.com/en/7161/LVM_OLR_whitepaper.pdf

SEP
Steven E Protter
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
James R. Ferguson
Acclaimed Contributor

Re: removing disk from volume group where associated lvm's are mirrored with stripping...

Hi Vijay:

> For this case where the logical volume is mirrored with stripping, how we need to proceed?

Why do you think it is mirrored and stripped [which at 11.11 isn't an option]?

The logical volume you show is mirrored (Mirror copies=1) but has no stripes (Stripes=0).

Regards!

...JRF...
Tingli
Esteemed Contributor

Re: removing disk from volume group where associated lvm's are mirrored with stripping...

I never did this before. But I think you can split mirror then rebuild the stripe with the new disk.
sabinkarvijay
Frequent Advisor

Re: removing disk from volume group where associated lvm's are mirrored with stripping...

Hi Steven,

can i do the below:

firstly i am reducing the mirror copy of logical volumes associated with PV /dev/dsk/c3t12d0:

--->lvreduce -m 0 /dev/vg01/lvol23 /dev/dsk/c3t12d0

lvreduce -m 0 /dev/vg01/lvol24 /dev/dsk/c3t12d0

lvreduce -m 0 /dev/vg01/lvol25 /dev/dsk/c3t12d0

lvreduce -m 0 /dev/vg01/lvol26 /dev/dsk/c3t12d0

lvreduce -m 0 /dev/vg01/lvol27 /dev/dsk/c3t12d0


---------------------------------------------

then i will go for vgreduce to make the disk c3t12d0 out of the volume group:

vgreduce /dev/vg01 /dev/dsk/c3t12d0

Is there anything else I need to do Steven before going for replacing the disk with the new one?

Thanks in Advance,

Regards,
Vijay Sabinkari.

Patrick Wallek
Honored Contributor

Re: removing disk from volume group where associated lvm's are mirrored with stripping...

If you are reducing mirrors, you need to specify ALL Disks that hold a particular mirror copy, not just c3t12d0.

sabinkarvijay
Frequent Advisor

Re: removing disk from volume group where associated lvm's are mirrored with stripping...

Hi Patrik,

do you mean to say , I need to consider other disks which are showing while lvdisplay:

/dev/dsk/c3t8d0 4499 4499
/dev/dsk/c3t10d0 4499 4499
/dev/dsk/c3t12d0 1751 1751
/dev/dsk/c3t14d0 1751 1751

Thanks in Advance,

Regards,
Vijay Sabinkari
Torsten.
Acclaimed Contributor

Re: removing disk from volume group where associated lvm's are mirrored with stripping...

There is no striping!

Find out what disks are mirrored and remove one copy, e.g.

# lvreduce -m 0 /dev/vg01/lvol23 /dev/dsk/c3t10d0 /dev/dsk/c3t14d0

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!   
sabinkarvijay
Frequent Advisor

Re: removing disk from volume group where associated lvm's are mirrored with stripping...

Hi All,

I had one small query here:

Please find the attachment for lvdisplay output:

here how the mirroring is happened, could anyone please explain me..

As i know c3t8d0 data is syncd with c3t12d0 and c3t14d0 data also is syncd with c3t12d0...

Is it correct?

1) If it is correct, i would like to sync the c3t8d0 data with another disk, for that can i fallow the below:

reducing the mirror copy c3t12d0 which is having the data of the disk c3t8d0:


lvreduce -m 0 /dev/vg01/lvol23 /dev/dsk/c3t12d0 /dev/dsk/c3t8d0

and I would like to make new copy of mirror for data in c3t8d0 in the disk c3t10d0:

lvextend -m 1 /dev/vg01/lvol23 /dev/dsk/c3t10d0 /dev/dsk/c3t8d0

Please suggest me how can i proceed on this...

Thanks in Advance,

Regards,
Vijay Sabinkari.
Ganesan R
Honored Contributor

Re: removing disk from volume group where associated lvm's are mirrored with stripping...

Hi,

Your setup is not complicated. It is very simple.

Primary copy of the lv is residing on c3t8d0 and c3t14t0.(Total PE's 4499+1751=6250). This data is mirrored to single disk c3t12d0.

Now you don't any issue to replace any of the disk. If you want to make this lv in simple way, move all the PE's from c3t14t0 to c3t8d0 if you have 1751 PE's free. So that you can have primary on c3t8d0 and mirror on c3t12d0.

If you tell us your current requirement, we can guide you further.

Best wishes,

Ganesh.