Resize root partition in CentOS 7.3

General support questions
lambofan
Posts: 1
Joined: 2018/01/15 06:33:29

Resize root partition in CentOS 7.3

Postby lambofan » 2018/01/15 07:50:02

Hi,

I have 30 GB of space mounted as / - The file system is XFS. I want to alter this as - 20 GB for / and 10 GB for /opt. Can you please help.

The machine is a VM running in Azure.

Many Thanks !

User avatar
TrevorH
Forum Moderator
Posts: 22590
Joined: 2009/09/24 10:40:56
Location: Brighton, UK

Re: Resize root partition in CentOS 7.3

Postby TrevorH » 2018/01/15 09:20:56

No, sorry, it cannot be done. XFS is not shrinkable and as it's your root filesystem it's not easy to back that up and restore it onto a smaller filesystem.
CentOS 5 died in March 2017 - migrate NOW!
Full time Geek, part time moderator. Use the FAQ Luke

desertcat
Posts: 337
Joined: 2014/08/07 02:17:29

Re: Resize root partition in CentOS 7.3

Postby desertcat » 2018/01/16 06:43:05

TrevorH wrote:No, sorry, it cannot be done. XFS is not shrinkable and as it's your root filesystem it's not easy to back that up and restore it onto a smaller filesystem.


TrevorH This a a question that falls under "Curiosity". My buddy and I were talking tonight and he informed me that ext4 may not the best file system for SSD's. Of course he and I have been using ext since ext2. XFS seems to be the preferred file format. ext4 may be OLD and showing its age but has always been reliable. IF xfs is a better file system is it possible to convert ext4 --> xfs??

Just curious.