The gfs_grow command is used to expand a GFS file system after the device where the file system resides has been expanded. Running a gfs_grow command on an existing GFS file system fills all spare space between the current end of the file system and the end of the device with a newly initialized GFS file system extension. When the fill operation is completed, the resource index for the file system is updated. All nodes in the cluster can then use the extra storage space that has been added.
The gfs_grow command can only be run on a mounted file system, but only needs to be run on one node in the cluster. All the other nodes sense that the expansion has occurred and automatically start using the new space.
To verify that the changes were successful, you can use the gfs_grow command with the -T (test) and -v (verbose) flags. Running the command with those flags displays the current state of the mounted GFS file system.
Before running the gfs_grow command:
Back up important data on the file system.
Display the pool volume that is used by the file system to be expanded by running a gfs_tool df MountPoint command.
Expand the underlying pool volume with a pool_tool -g command. Refer to Section 5.8 Growing a Pool Volume for additional information.
After running the gfs_grow command, run a df command to check that the new space is now available in the file system.
In this example, the file system on the /gfs1/ directory is expanded.
gfs_grow /gfs1 |
In this example, the state of the mounted file system is checked.
gfs_grow -Tv /gfs1 |
gfs_grow [Options] {MountPoint | Device} [MountPoint | Device] |
Specifies the directory where the GFS file system is mounted.
Specifies the device node of the file system.
Table 9-3 describes the GFS-specific options that can be used while expanding a GFS file system.
Option | Description |
---|---|
-h | Help. Display a short usage message, then exist. |
-q | Quiet. Turn down the verbosity level. |
-T | Test. Do all calculations, but do not write any data to the disk and do not expand the file system. |
-V | Display command version information, then exit. |
-v | Turn up the verbosity of messages. |
Table 9-3. GFS-specific Options Available While Expanding A File System