Skip to contentSkip to conversation

how to move data from one PV to other PV automaticly?

linux-lvm cwinl 3 participants 5 messages Jun 13, 2005

lore
Share & tools
lore

cwinl

author
#0 lore raw

hi,all:
i have a VG with 3 PV.
here is 'pvdisplay' information:

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

ftp:~# pvdisplay -v
    Scanning for physical volume names
  --- Physical volume ---
  PV Name               /dev/sdb1
  VG Name               nicvg
  PV Size               838.09 GB / not usable 0   
  Allocatable           yes (but full)
  PE Size (KByte)       32768
  Total PE              26819
  Free PE               0
  Allocated PE          26819
  PV UUID               IyahCr-NwPt-dUsC-UuVa-ki1y-5X4X-NRReLA

--- Physical volume ---

  PV Name               /dev/sdc1
  VG Name               nicvg
  PV Size               558.72 GB / not usable 0   
  Allocatable           yes (but full)
  PE Size (KByte)       32768
  Total PE              17879
  Free PE               0
  Allocated PE          17879
  PV UUID               NG6cMz-I12Q-6X8T-58gn-Fvov-gYs9-HCvYyw

--- Physical volume ---

  PV Name               /dev/sdd1
  VG Name               nicvg
  PV Size               558.72 GB / not usable 0   
  Allocatable           yes (but full)
  PE Size (KByte)       32768
  Total PE              17879
  Free PE               0
  Allocated PE          17879
  PV UUID               qqm9Ua-5owd-ZhVM-nU5D-wZeL-klu1-t0Ij68

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

i want to move all data from /dev/sdb1 to another two PV (/dev/sdc1 and /dev/sdd1) automaticly.
so i can remove the unstable PV /dev/sdb1 and repair it. then i will restore a new /dev/sdb1 device.

the disk space is all right.
here is 'df' information:

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

ftp:~# df
Filesystem            Size  Used Avail Use% Mounted on
/dev/sda5             1.9G  545M  1.4G  29% /
tmpfs                1014M  4.0K 1014M   1% /dev/shm
/dev/sda1              95M   39M   56M  42% /boot
/dev/sda6              14G  444M   14G   4% /var
/dev/mapper/nicvg-niclv
                      2.0T  774G  1.2T  40% /ftproot

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

the volumn '/dev/mapper/nicvg-niclv' is on the VG above.

how can finish it?

any suggestion is regarded!

#1 lore raw

On Mon, Jun 13, 2005 at 10:51:58AM +0800, cwinl alleged:

Quoted 22 lines

hi,all:
i have a VG with 3 PV.
here is 'pvdisplay' information:
--- Physical volume ---
PV Name /dev/sdb1
Free PE 0

--- Physical volume ---
PV Name /dev/sdc1
Free PE 0

--- Physical volume ---
PV Name /dev/sdd1
Free PE 0

i want to move all data from /dev/sdb1 to another two PV (/dev/sdc1 and /dev/sdd1) automaticly.
so i can remove the unstable PV /dev/sdb1 and repair it. then i will restore a new /dev/sdb1 device. /dev/mapper/nicvg-niclv

                      2.0T  774G  1.2T  40% /ftproot
Quoted 7 lines

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

the volumn '/dev/mapper/nicvg-niclv' is on the VG above.

how can finish it?

any suggestion is regarded!

The other 2 PVs (sdc1 and sdd1) are both full. You can't move any data on them with the current configuration. You'll need to free up ~840GB on nicvg before you can do it.

The first step would be to shrink the filesystem using the correct utility for the filesystem (you didn't mention the filesystem type). Fortunately you have 1.2TB free on the filesystem so this shouldn't be a problem.

Then reduce the size of niclv and you'll be able to move the PEs off of sdb1.

Signature · 2 lines
Garrick Staples, Linux/HPCC Administrator
University of Southern California
author
#2 lore raw
Quoted 42 lines

-----Original Message-----
From: [email protected] [mailto:[email protected]] On Behalf Of Garrick Staples
Sent: Monday, June 13, 2005 1:14 PM
To: LVM general discussion and development
Subject: Re: [linux-lvm] how to move data from one PV to other PV automaticly?

On Mon, Jun 13, 2005 at 10:51:58AM +0800, cwinl alleged:

Quoted 23 lines

hi,all:
i have a VG with 3 PV.
here is 'pvdisplay' information:
--- Physical volume ---
PV Name /dev/sdb1
Free PE 0

--- Physical volume ---
PV Name /dev/sdc1
Free PE 0

--- Physical volume ---
PV Name /dev/sdd1
Free PE 0

i want to move all data from /dev/sdb1 to another two PV (/dev/sdc1 and
/dev/sdd1) automaticly.
so i can remove the unstable PV /dev/sdb1 and repair it. then i will restore a new /dev/sdb1 device. /dev/mapper/nicvg-niclv

                      2.0T  774G  1.2T  40% /ftproot
Quoted 7 lines

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

the volumn '/dev/mapper/nicvg-niclv' is on the VG above.

how can finish it?

any suggestion is regarded!

Quoted 7 lines

The other 2 PVs (sdc1 and sdd1) are both full. You can't move any data on them with the current configuration. You'll need to free up ~840GB on nicvg before you can do it.

The first step would be to shrink the filesystem using the correct utility for the filesystem (you didn't mention the filesystem type). Fortunately you have 1.2TB free on the

my FS is reiserfs.
please tell me in detail.

Quoted 10 lines

filesystem so this shouldn't be a problem.

Then reduce the size of niclv and you'll be able to move the PEs off of sdb1.

--
Garrick Staples, Linux/HPCC Administrator University of Southern California

author
#4 lore raw
In reply to Garrick Staples
Quoted 42 lines

-----Original Message-----
From: [email protected] [mailto:[email protected]] On Behalf Of Garrick Staples
Sent: Monday, June 13, 2005 1:14 PM
To: LVM general discussion and development
Subject: Re: [linux-lvm] how to move data from one PV to other PV automaticly?

On Mon, Jun 13, 2005 at 10:51:58AM +0800, cwinl alleged:

Quoted 23 lines

hi,all:
i have a VG with 3 PV.
here is 'pvdisplay' information:
--- Physical volume ---
PV Name /dev/sdb1
Free PE 0

--- Physical volume ---
PV Name /dev/sdc1
Free PE 0

--- Physical volume ---
PV Name /dev/sdd1
Free PE 0

i want to move all data from /dev/sdb1 to another two PV (/dev/sdc1 and
/dev/sdd1) automaticly.
so i can remove the unstable PV /dev/sdb1 and repair it. then i will restore a new /dev/sdb1 device. /dev/mapper/nicvg-niclv

                      2.0T  774G  1.2T  40% /ftproot
Quoted 7 lines

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

the volumn '/dev/mapper/nicvg-niclv' is on the VG above.

how can finish it?

any suggestion is regarded!

Quoted 8 lines

The other 2 PVs (sdc1 and sdd1) are both full. You can't move any data on them with the current configuration. You'll need to free up ~840GB on nicvg before you can do it.

The first step would be to shrink the filesystem using the correct utility for the filesystem (you didn't mention the filesystem type). Fortunately you have 1.2TB free on the filesystem so this shouldn't be a problem.

my kernel is 2.6.10

Quoted 5 lines

Then reduce the size of niclv and you'll be able to move the PEs off of sdb1.

i have add 10 disks on that server and there is no space to add in even one new disk.
data is too huge , no space on any other server to backup them. so what i want to do is to move data from PV to PV automaticly. i have got enough space on the VG(disk usage is 40%).

Quoted 4 lines

--
Garrick Staples, Linux/HPCC Administrator University of Southern California

#3 lore raw
In reply to Steven Law
Quoted 44 lines · Steven Law
Quoted 44 lines

-----Original Message-----
From: [email protected] [mailto:[email protected]] On Behalf Of Garrick Staples
Sent: Monday, June 13, 2005 1:14 PM
To: LVM general discussion and development
Subject: Re: [linux-lvm] how to move data from one PV to other PV automaticly?

On Mon, Jun 13, 2005 at 10:51:58AM +0800, cwinl alleged:

Quoted 23 lines

hi,all:
i have a VG with 3 PV.
here is 'pvdisplay' information:
--- Physical volume ---
PV Name /dev/sdb1
Free PE 0

--- Physical volume ---
PV Name /dev/sdc1
Free PE 0

--- Physical volume ---
PV Name /dev/sdd1
Free PE 0

i want to move all data from /dev/sdb1 to another two PV (/dev/sdc1 and
/dev/sdd1) automaticly.
so i can remove the unstable PV /dev/sdb1 and repair it. then i will restore a new /dev/sdb1 device. /dev/mapper/nicvg-niclv

                      2.0T  774G  1.2T  40% /ftproot
Quoted 7 lines

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

the volumn '/dev/mapper/nicvg-niclv' is on the VG above.

how can finish it?

any suggestion is regarded!

The other 2 PVs (sdc1 and sdd1) are both full. You can't move any data on them with the current configuration. You'll need to free up ~840GB on nicvg before you can do it.

Quoted 6 lines
Quoted 3 lines

The first step would be to shrink the filesystem using the correct utility for the filesystem (you didn't mention the filesystem type). Fortunately you have 1.2TB free on the

my FS is reiserfs.
please tell me in detail.

man resize_reiserfs, then use (c)fdisk to reduce the partition.

~David