Resize XFS partition.

Unmount device

umount /mnt/nfs

load block device into parted

parted /dev/xvdc

change units to ‘s’

unit s

remove partition

rm 1

Recreate new partition

(parted) mkpart
Partition type? primary/extended? primary
File system type? [ext2]? xfs
Start? 2048s
End? -1
(parted) p
Model: Xen Virtual Block Device (xvd)
Disk /dev/xvdc: 251658240s
Sector size (logical/physical): 512B/512B
Partition Table: msdos

remount device

mount /dev/xvdc1 /mnt/nfs

grow filesystem


xfs_growfs /mnt/nfs

meta-data=/dev/xvdc1 isize=256 agcount=4, agsize=6553452 blks
= sectsz=512 attr=2, projid32bit=0
data = bsize=4096 blocks=26213807, imaxpct=25
= sunit=0 swidth=0 blks
naming =version 2 bsize=4096 ascii-ci=0
log =internal bsize=4096 blocks=12799, version=2
= sectsz=512 sunit=0 blks, lazy-count=1
realtime =none extsz=4096 blocks=0, rtextents=0

great success.

Comments are closed.