1 |
On Sun, 27 Nov 2011 09:02:37 +0100 |
2 |
Róbert Čerňanský <hslists2@××××××.sk> wrote: |
3 |
|
4 |
> On Sun, 27 Nov 2011 00:01:07 +0100 |
5 |
> Alex Schuster <wonko@×××××××××.org> wrote: |
6 |
> |
7 |
> > pvcreate /dev/sda5 |
8 |
> > vgcreate myvg /dev/sda5 |
9 |
> > lvcreate -n usr -L 10G myvg |
10 |
> > mke2fs -j /dev/myvg/usr |
11 |
> > |
12 |
> > Of course, just using /dev/sda5 for /usr is simpler. But what if |
13 |
> > this turns out to be too small? With so many partitions I would |
14 |
> > think this is very likely to happen sooner or later. With LVM, all |
15 |
> > you'd have to do is: |
16 |
> > |
17 |
> > lvresize -L +1G /dev/myvg/usr |
18 |
> > resize2fs /dev/myvg/usr |
19 |
> |
20 |
> Here I do not understand from where this +1G is taken? Don't you have |
21 |
> to make something smaller by 1G first? |
22 |
|
23 |
The 1G is taken from the free pool of unused extents. This assumes you |
24 |
have free extents, if not, then you do need to free some up somwehere |
25 |
else first. |
26 |
|
27 |
Using LVM is a lot like using a SAN - don't allocate everything right |
28 |
at the beginning, rather give each lv what it needs today and grow it |
29 |
as space needs change. This way you always have free extents available |
30 |
for use. |
31 |
|
32 |
|
33 |
|
34 |
-- |
35 |
Alan McKinnnon |
36 |
alan.mckinnon@×××××.com |