Sunteți pe pagina 1din 3

[root@honginx ~]# ssm list

------------------------------------------------------------------
Device Free Used Total Pool Mount point
------------------------------------------------------------------
/dev/xvdb 232.00 GB
/dev/xvdb1 1.00 GB /boot
/dev/xvdb2 0.00 KB 231.00 GB 231.00 GB ol_honginx
------------------------------------------------------------------
--------------------------------------------------------
Pool Type Devices Free Used Total
--------------------------------------------------------
ol_honginx lvm 1 0.00 KB 231.00 GB 231.00 GB
--------------------------------------------------------
-----------------------------------------------------------------------------------
-----------
Volume Pool Volume size FS FS size Free Type
Mount point
-----------------------------------------------------------------------------------
-----------
/dev/ol_honginx/root ol_honginx 214.00 GB ext4 214.00 GB 196.09 GB
linear /
/dev/ol_honginx/swap ol_honginx 17.00 GB linear
/dev/xvdb1 1.00 GB ext4 1.00 GB 743.05
MB /boot
-----------------------------------------------------------------------------------
-----------

[root@honginx ~]# ssm resize -s 10G /dev/ol_honginx/swap


WARNING: Reducing active and open logical volume to 10.00 GiB.
THIS MAY DESTROY YOUR DATA (filesystem etc.)
Do you really want to reduce ol_honginx/swap? [y/n]: y
Size of logical volume ol_honginx/swap changed from <17.00 GiB (4351 extents) to
10.00 GiB (2560 extents).
Logical volume ol_honginx/swap successfully resized.

[root@honginx ~]# ssm list


------------------------------------------------------------------
Device Free Used Total Pool Mount point
------------------------------------------------------------------
/dev/xvdb 232.00 GB
/dev/xvdb1 1.00 GB /boot
/dev/xvdb2 7.00 GB 224.00 GB 231.00 GB ol_honginx
------------------------------------------------------------------
--------------------------------------------------------
Pool Type Devices Free Used Total
--------------------------------------------------------
ol_honginx lvm 1 7.00 GB 224.00 GB 231.00 GB
--------------------------------------------------------
-----------------------------------------------------------------------------------
-----------
Volume Pool Volume size FS FS size Free Type
Mount point
-----------------------------------------------------------------------------------
-----------
/dev/ol_honginx/root ol_honginx 214.00 GB ext4 214.00 GB 196.09 GB
linear /
/dev/ol_honginx/swap ol_honginx 10.00 GB linear
/dev/xvdb1 1.00 GB ext4 1.00 GB 743.05
MB /boot
-----------------------------------------------------------------------------------
-----------

+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
+++++++++++++++++++++++++++++++

[root@honginx ~]# lvextend -l +100%FREE /dev/ol_honginx/root


Size of logical volume ol_honginx/root changed from 214.00 GiB (54784 extents) to
<221.00 GiB (56575 extents).
Logical volume ol_honginx/root successfully resized.

+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
+++++++++++++++++++++++++++++++

[root@honginx ~]# ssm list


------------------------------------------------------------------
Device Free Used Total Pool Mount point
------------------------------------------------------------------
/dev/xvdb 232.00 GB
/dev/xvdb1 1.00 GB /boot
/dev/xvdb2 0.00 KB 231.00 GB 231.00 GB ol_honginx
------------------------------------------------------------------
--------------------------------------------------------
Pool Type Devices Free Used Total
--------------------------------------------------------
ol_honginx lvm 1 0.00 KB 231.00 GB 231.00 GB
--------------------------------------------------------
-----------------------------------------------------------------------------------
-----------
Volume Pool Volume size FS FS size Free Type
Mount point
-----------------------------------------------------------------------------------
-----------
/dev/ol_honginx/root ol_honginx 221.00 GB ext4 214.00 GB 196.09 GB
linear /
/dev/ol_honginx/swap ol_honginx 10.00 GB linear
/dev/xvdb1 1.00 GB ext4 1.00 GB 743.05
MB /boot
-----------------------------------------------------------------------------------
-----------

+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
+++++++++++++++++++++++++++++++

[root@honginx ~]# resize2fs /dev/ol_honginx/root


resize2fs 1.42.9 (28-Dec-2013)
Filesystem at /dev/ol_honginx/root is mounted on /; on-line resizing required
old_desc_blocks = 27, new_desc_blocks = 28
The filesystem on /dev/ol_honginx/root is now 57932800 blocks long.

[root@honginx ~]# df -h
Filesystem Size Used Avail Use% Mounted on
devtmpfs 3.9G 0 3.9G 0% /dev
tmpfs 3.9G 0 3.9G 0% /dev/shm
tmpfs 3.9G 9.4M 3.9G 1% /run
tmpfs 3.9G 0 3.9G 0% /sys/fs/cgroup
/dev/mapper/ol_honginx-root 218G 8.2G 199G 4% /
/dev/xvdb1 976M 182M 728M 20% /boot
tmpfs 797M 56K 797M 1% /run/user/0
/dev/sr0 4.3G 4.3G 0 100% /run/media/root/OL-7.6
Server.x86_64

S-ar putea să vă placă și