[CentOS] is it safe to resize root, on an LVM system, online?
Digimer
linux at alteeve.com
Sun Jul 11 18:39:50 UTC 2010
On 10-07-11 02:27 PM, Rudi Ahlers wrote:
> Hi,
>
> One of our servers has a too small root partition on LVM and needs to
> be resized. Can / be safely increased online, without a reboot?
>
> [root at zaxen02 ~]# lvscan
> ACTIVE '/dev/LVM01/root' [4.00 GB] inherit
> ACTIVE '/dev/LVM01/home' [20.00 GB] inherit
> ACTIVE '/dev/LVM01/var' [4.00 GB] inherit
> ACTIVE '/dev/LVM01/swap' [4.00 GB] inherit
> ACTIVE '/dev/LVM01/log' [1.00 GB] inherit
> ACTIVE '/dev/LVM01/webmin' [2.00 GB] inherit
> ACTIVE '/dev/LVM01/xenstored' [2.00 GB] inherit
> ACTIVE '/dev/LVM01/xensave' [2.00 GB] inherit
> ACTIVE '/dev/LVM01/opennation-net_img' [10.00 GB] inherit
> ACTIVE '/dev/LVM01/opennation-net_swap' [1.00 GB] inherit
> ACTIVE '/dev/LVM01/pluto_img' [100.00 GB] inherit
> ACTIVE '/dev/LVM01/pluto_swap' [1.00 GB] inherit
> ACTIVE '/dev/LVM01/tmp' [5.00 GB] inherit
> [root at zaxen02 ~]# pvscan
> PV /dev/md1 VG LVM01 lvm2 [232.69 GB / 76.69 GB free]
> Total: 1 [232.69 GB] / in use: 1 [232.69 GB] / in no VG: 0 [0 ]
> [root at zaxen02 ~]#
It depends mainly on the filesystem you are using. The ext[3|4]
filesystems are fine. You'll have to extend the LV, and then separately
extend the filesystem itself.
Please test this on a non-production server before trying it on your
live server, just to be safe and to be sure that you've got your syntax
right.
--
Digimer
E-Mail: linux at alteeve.com
AN!Whitepapers: http://alteeve.com
Node Assassin: http://nodeassassin.org
More information about the CentOS
mailing list