1 |
Am 06.03.2012 18:25, schrieb Neil Bothwick: |
2 |
> On Tue, 6 Mar 2012 16:32:56 +0000, Stroller wrote: |
3 |
> |
4 |
>>> … I initially want to replace the 3x1TBs with a single 3TB drive but |
5 |
>>> i've never removed/replaced a drive in an LVM setup before. I think I |
6 |
>>> understand how it is done, using pvmove … |
7 |
>> |
8 |
>> Or you could just format and mount the new drive and use `cp`. |
9 |
> |
10 |
> Thereby instantly removing the benefits of LVM and making it almost |
11 |
> impossible to extend the space by adding another drive when needed. |
12 |
> |
13 |
|
14 |
I don't think so. vgextend the volume group with the new disk, lvcreate |
15 |
a new volume using only extents from the new disk, copy data over to it, |
16 |
swap mount points, done. |
17 |
|
18 |
Plus points: Removes fragmentation of the old file system. Also probably |
19 |
faster. |
20 |
|
21 |
> To the OP, pvmove is perfectly safe as it does a copy;verify;delete on |
22 |
> one small block of extents at a time. It also ensures that any new writes |
23 |
> while pvmove is running go to the new drive, so you can still use the |
24 |
> system while moving (try doing that with cp :). |
25 |
> |
26 |
> |
27 |
|
28 |
Wait, are we talking about a system disk (root and stuff)? I was under |
29 |
the impression that it's just a data dump. Of course, with system |
30 |
partitions and other media that cannot be handled read-only for a longer |
31 |
time, pvmove or lvchange are the better options. |
32 |
|
33 |
Regards, |
34 |
Florian Philipp |