cancel
Showing results for 
Search instead for 
Did you mean: 
chis0
Mission Specialist
Mission Specialist
  • 64 Views

Hi,

 

In Lab 8.5 - I notice all checks passed but I checked the answers and I did not use the below command in my solution:

xfs_growfs /storage/data1

 

It seems the lab passed regardless of this command.

 

What are the consequences of not using xfs_growfs and only using lvextend?

 

Thanks.

1 Solution

Accepted Solutions
shura
Flight Engineer
Flight Engineer
  • 52 Views

Hi @chis0 

The xfs_growfs command introduces an extra step to extend the file system. An
alternative would be to use the lvextend command -r option: -r|--resizefs
Resize the fs using the fs-specific resize command.  See --fs for
more options (--resizefs is equivalent to --fs resize.)

View solution in original post

2 Replies
shura
Flight Engineer
Flight Engineer
  • 53 Views

Hi @chis0 

The xfs_growfs command introduces an extra step to extend the file system. An
alternative would be to use the lvextend command -r option: -r|--resizefs
Resize the fs using the fs-specific resize command.  See --fs for
more options (--resizefs is equivalent to --fs resize.)

Chetan_Tiwary_
Community Manager
Community Manager
  • 24 Views

@chis0 Please recall that :

When you use lvextend to increase the size of a logical volume (LV), it doesn't automatically update the file system size within that LV. The file system itself, in this case XFS, remains unaware of this increased space. To enable the file system to utilize the newly allocated space within the extended LV, you must run xfs_growfs. This command informs the XFS file system about the available space, allowing you to effectively store more data on the expanded partition / file system.

 

In a nutshell, lvextend only extends the raw storage size of the underlying LVM, inorder to utilise the space and store data / files ( everything is a file in Linux ) - we need to grow / extend / expand the file system as well - in this case xfs filesystem.

Note that - you can do the same in a single command with lvextend and you dont necessarily have to use xfs_growfs ( as @shura mentioned ).

0 Kudos
Join the discussion
You must log in to join this conversation.