User Tools

Site Tools


linux:centos:extend-xfs-partition

Extend XFS partition

df -h

Filesystem                       Size  Used Avail Use% Mounted on
/dev/mapper/centos_odcent7-root   50G  3.0G   47G   6% /
devtmpfs                         2.6G     0  2.6G   0% /dev
tmpfs                            2.6G     0  2.6G   0% /dev/shm
tmpfs                            2.6G   12M  2.6G   1% /run
tmpfs                            2.6G     0  2.6G   0% /sys/fs/cgroup
/dev/sda1                       1014M  191M  824M  19% /boot
/dev/mapper/centos_odcent7-home  125G   25G  100G  20% /home
tmpfs                            516M     0  516M   0% /run/user/0
/dev/sr0                         4.3G  4.3G     0 100% /media/CentOS

lvextend /dev/mapper/centos_odcent7-home -L +100G

Size of logical volume centos_odcent7/home changed from 124.19 GiB (31793 extents) to 224.19 GiB (57393 extents).
Logical volume centos_odcent7/home successfully resized.

xfs_growfs /dev/mapper/centos_odcent7-home

meta-data=/dev/mapper/centos_odcent7-home isize=512    agcount=21, agsize=1585408 blks
         =                       sectsz=512   attr=2, projid32bit=1
         =                       crc=1        finobt=0 spinodes=0
data     =                       bsize=4096   blocks=32556032, imaxpct=25
         =                       sunit=0      swidth=0 blks
naming   =version 2              bsize=4096   ascii-ci=0 ftype=1
log      =internal               bsize=4096   blocks=3096, version=2
         =                       sectsz=512   sunit=0 blks, lazy-count=1
realtime =none                   extsz=4096   blocks=0, rtextents=0
data blocks changed from 32556032 to 58770432
linux/centos/extend-xfs-partition.txt · Last modified: 2023/07/04 19:36 by 127.0.0.1