[CentOS] How to remove LVM Physical Volume from Volume Group?

Tue Jun 24 20:08:17 UTC 2014
Zhang, Jonathan <zhangj at evergreen.edu>

If you need to move data out from sdd7 to new location. You need to pvmove /dev/new_disc  first
Then vgreduce and pvremove

However, before do pvmove you need 
pvcreate /dev/new_disc
vgextend vg_data/new_disc
pvmove /dev/new_disc



-----Original Message-----
From: centos-bounces at centos.org [mailto:centos-bounces at centos.org] On Behalf Of Mauricio Tavares
Sent: Tuesday, June 24, 2014 1:00 PM
To: CentOS mailing list
Subject: Re: [CentOS] How to remove LVM Physical Volume from Volume Group?

On Tue, Jun 24, 2014 at 3:56 PM, Zhang, Jonathan <zhangj at evergreen.edu> wrote:
> The doc is recommend you do pvremove first and then run vgreduce.
> But you will get error something like "...you need to remove from 
> volume group first before delete the physical volume" (the message 
> makes sense for me. Need to removing from volume group first then 
> removing the physical one)
>
> While ago I run "vgrreduce" first and then do "pvremove". It worked fine for me.
>
      I myself always thought you would pvmove, then vgreduce, and then pvremove. Unless you also had to resize the lv first


> -----Original Message-----
> From: centos-bounces at centos.org [mailto:centos-bounces at centos.org] On 
> Behalf Of Eero Volotinen
> Sent: Tuesday, June 24, 2014 12:45 PM
> To: CentOS mailing list
> Subject: Re: [CentOS] How to remove LVM Physical Volume from Volume Group?
>
> 2014-06-24 22:31 GMT+03:00 Zhang, Jonathan <zhangj at evergreen.edu>:
>
>> Fidsk -l (you will see sdd5, sdd6 and sdd7) Pvdisplay (to make sure 
>> the Allocated PE on /dev/sdd7 Vgreduce vg_data /dev/sdd7 Pvremove
>> /dev/sdd7
>>
>> (before you run vgreduce you need to move all data from sdd7 to new 
>> dic
>>
>>
> this is wrong way to do this. see the real docs at:
> https://access.redhat.com/site/documentation/en-US/Red_Hat_Enterprise_
> Linux/6/html/Logical_Volume_Manager_Administration/disk_remove_ex.html
>
> --
> Eero
> _______________________________________________
> CentOS mailing list
> CentOS at centos.org
> http://lists.centos.org/mailman/listinfo/centos
> _______________________________________________
> CentOS mailing list
> CentOS at centos.org
> http://lists.centos.org/mailman/listinfo/centos
_______________________________________________
CentOS mailing list
CentOS at centos.org
http://lists.centos.org/mailman/listinfo/centos