Filesystems
A logical volume provides storage; we can apply this storage in different ways. For example, you may use logical volume to create block-level, object-level, or file-level storage.
Adding filesystems
Filesystems required for NAS and Object storage.
To add filesystems for volumes, use the applications filesystems add
command.
Usage
applications filesystems add --application=<name> --volumes=<name…> [--profile=<name>] [--addReplicationMetadata]
Notice:
- Each volume has only one filesystem.
- If you list n volumes, the
applications filesystems add
command creates n different filesystems, one for each volume.
options
Options and arguments | Description |
---|---|
--application=<name> |
Specify the name of the application instance containing the volumes that you want to create a file system for; replace <name> with the name of the app instance. |
--volumes=<name…> |
Specify the name of the volumes where you want to add the filesystems. Replace <name…> with a list of already existing volumes. |
--profile=<name> |
To specify the profile mode for the file system. Replace <name> with either ordered or journal . |
--addReplicationMetadata |
To add replication metadata to the filesystems. This option prevents disruptions when starting replication. |
Examples
-
To create three new filesystems on volumes
vol1
,vol2
, andvol3
( all mapped to application instancesales
) with profile ordered, run:applications filesystem create --application sales --volumes vol1 vol2 vol3 --profile ordered
-
To create three new filesystem on volumes
vol1
,vol2
, andvol3
( all mapped to application instancesales
) with profile journal and with replication metadata on the filesystems, run:applications filesystem create --application sales --volumes vol1 vol2 vol3 --profile ordered --addReplicationMetadata ```
List filesystems
To list filesystem information of volume(s), use the applications filesystems list
command.
Usage
applications filesystems list [--application=<name> --volume=<name>]
options
Options and arguments | Description |
---|---|
--application=<name> |
To specify the application instance of the volume, replace name with the name of the app instance. |
--volume=<name> |
To specify the volume name, the command will list all the filesystems in the specified volume. Replace <name> with the name of the volume. |
Examples
- To list filesystem information of all application instances and volumes, run:
applications filesystems list
- To list filesystem information of all volumes in application instance
sales
, run:applications filesystems list --application sales
- To list filesystem information of volume
pricing
mapped to application instancesales
, run:applications filesystems list --application sales --volume pricing
Edit a filesystem
To add replication metadata to volumes that contain filesystems, use
the applications filesystems edit
command.
Notice: You can only add replication data to a volume that contains a filesystem. Adding replication data to a volume is immutable. Once you add replication metadata to a volume, you cannot remove it.
Usage
applications filesystems edit --application=<name> --volume=<name> --addReplicationMetadata [--force]
options
Options and arguments | Description |
---|---|
--application=<name> |
Specify the name of application instance; replace <name> with the name of the app instance. |
--volumes=<name> |
Specify the name of the volume; where the filesystem exists. Replace <name> with the name of the volume. |
--addReplicationMetadata |
Add replication metadata to a filesystem. This option prevents disruptions when starting replication. |
--force |
To avoid prompting for approval. |
Examples
-
To add replication metadata to a filesystem on volume
vol1
, wherevol1
is on application instancesales
; run:applications filesystem edit --application sales --volumes vol1 --addReplicationMetadata
Discard unused blocks
To discard (“trim”) blocks (not used by the filesystem), use the
applications filesystems fstrim run
command. This command requires a
volume option; it “trims” all the filesystems on the specified volume.
Usage
applications filesystems fstrim run --application=<name> --volume=<vol_name>
Options
Options and arguments | Description |
---|---|
--application=<name> |
Specify the name of application instance; replace <name> with the name of the app instance. |
--volume=<vol_name> |
Specify the name of the volume. All filesystems on this volume will be “trimmed”; replace <vol_name> with the name of the volume you want to trim. |
Example
-
To trim a volume
vol1
mapped to application instance sales, runapplications filesystems fstrim run --application sales --volume vol1
Check filesystems trimming status
To check filesystem trimming status, use the applications filesystems fstrim status
command.
Usage
applications filesystems fstrim status [--application=<name> --volume=<vol_name>]
Options
Options and arguments | Description |
---|---|
--application=<name> |
To specify the name of application instance, replace <name> with the name of the app instance. |
--volume=<vol_name> |
To check the trimming status of filesystems in the specified volume, replace <vol_name> with the name of the volume that you want to trim. |
Examples
-
To check the trimming status of all filesystems in all the application instances and volumes, run:
applications filesystems fstrim status
-
To check the trimming status of all filesystems on volume
vol1
mapped to application instancesales
; run:applications filesystems fstrim status --application sales --volume vol1