How to Increase or expand an XFS File System without LVM
PURPOSE: All documents are provided on this Blog just for educational purposes only. Please make sure that you run it in your test environment before to move on to production environment.
NOTE: make sure, that you test first on our test system!
Following
is the File System we want to increase.
/dev/sdb1 100G
88G 13G 88% /oracle
Step 1.
Increase a hardware disk size in VMWare to 150GB
Using
VMWare vSphere Client, open the properties of the virtual machine and increase
the Provisioned Size.
Step2. Stop
the running Application on Server
Step3. Unmount
the partition
umount
/oracle
or
umount -l
/oracle
df -Th
Step4.
Start to increase the partition.
parted -a optimal
/dev/sdb
GNU Parted
3.1
Using
/dev/sdb
Welcome to
GNU Parted! Type 'help' to view a list of commands.
(parted) unit s
(parted) print
Model:
VMware Virtual disk (scsi)
Disk
/dev/sdb: 314572800s
Sector
size (logical/physical): 512B/512B
Partition
Table: msdos
Disk
Flags:
Number Start
End Size Type
File system Flags
1
2048s 209715199s 209713152s
primary xfs
(parted) rm 1
Error:
Partition(s) 1 on /dev/sdb have been written, but we have been unable to inform
the kernel of the change, probably because it/they are in use. As a result, the old partition(s) will remain
in use. You should reboot now
before
making further changes.
Ignore/Cancel?
Ignore
(parted) mkpart
Partition
type? primary/extended? primary
File
system type? [ext2]? xfs
Start? 2048s
End? 100%
(parted) print
Model:
VMware Virtual disk (scsi)
Disk
/dev/sdb: 314572800s
Sector
size (logical/physical): 512B/512B
Partition
Table: msdos
Disk
Flags:
Number Start
End Size Type
File system Flags
1
2048s 314572799s 314570752s
primary xfs
(parted) unit compact
(parted) quit
Information:
You may need to update /etc/fstab.
Step5.
mount /oracle
xfs_growfs -d /oracle
meta-data=/dev/sdb1 isize=512 agcount=4, agsize=6553536 blks
= sectsz=512 attr=2, projid32bit=1
= crc=1 finobt=0 spinodes=0
data = bsize=4096 blocks=26214144, imaxpct=25
= sunit=0 swidth=0 blks
naming
=version 2
bsize=4096 ascii-ci=0 ftype=1
log
=internal
bsize=4096 blocks=12799,
version=2
= sectsz=512 sunit=0 blks, lazy-count=1
realtime =none extsz=4096 blocks=0, rtextents=0
data blocks changed from 26214144 to 39321344
Step6.
df -Th
/oracle
Filesystem Type
Size Used Avail Use% Mounted on
/dev/sdb1 xfs
150G 88G 63G
59% /oracle
Completed.
No comments:
Post a Comment