How can I increase the number of inodes or files for the volumes on my FSx for ONTAP file system?

4 minute read
0

I want to increase the maximum number of files for the volumes on my Amazon FSx for NetApp ONTAP file system.

Short description

If your volume is out of inodes (index nodes) or files, then you might receive one of the following error messages:

"Error message no space left on the device"

"Error message: file system is out of inodes"

"wafl.vol.outOfInodes: file system on Volume vol_name is out of inodes because it has reached the maximum number of files"

"INODE: System/Cluster Notification from filer (OUT OF INODES) ALERT"

To resolve this issue, increase the maximum number of files that are in your FlexVol volumes and FlexGroup volumes.

Note: If you can't increase the maximum number of files, then you must delete files to free inodes. Or, increase the volume size. If the new specified file count is larger than the volume can accommodate, then it reports the maximum possible value. The command in the following section reports the maximum possible value.

Check the current maximum file value for the volume

FSx for ONTAP advanced mode provides a command to check the current maximum possible files value that's set for each volume. To check the maximum possible files value for a volume, run the following advanced privilege command. Replace vol1 with the name of your volume:

::> set advanced::*> volume show -vserver fsx -volume vol1  -fields files-maximum-possible  
vserver volume files-maximum-possible  
------- ------ ----------------------  
fsx     vol1   255013682

In this example, the number 255013682 is the maximum files value that you can set for volume vol1.

Note: The commands in this resolution use the NetApp ONTAP Command Line Interface (NetApp ONTAP CLI). For information on accessing the NetApp ONTAP CLI, see Using the NetApp ONTAP CLI.

Resolution

Increase the number of files or inodes in your volume

Note: When increasing the number of files in your volume, make sure that inode and aggr space usage doesn't exceed a value that's close to 80%. 

1.    Run the following command to verify the current maximum number of files in the volume. Replace the svm_name and vol_name with the values for your use case:

::> volume show –vserver svm_name -volume vol_name -fields files

2.    Run the following command to modify the maximum number of files. Replace the svm_name, vol_name and number_of_files with the values for your use case:

::> volume modify –vserver svm_name -volume vol_name -files number_of_files

Example

Check the current number of files that are assigned to the volume:

::> volume show -vserver fsx -volume vol1 -fields filesvserver volume files  
------- ------ --------  
svm1 vol1 25501367

Update the number of inodes or files:

::> volume modify -vserver fsx -volume vol1 -files 35501367Volume modify successful on volume vol1 of Vserver svm1

Verify the modification:

::> volume show -vserver fsx -volume vol1 -fields filesvserver volume files  
------- ------ --------  
vol1 vol1 35501358

Set the maximum file value for a volume

You can use the files-set-maximum option to set the maximum file value for a volume. When the files-set-maximum value on a volume is set to true, ONTAP automatically adjusts maxfiles to the largest possible value.

Note: The files-set-maximum option is a one-time variable. After you set it to true, you can't change the setting.

1.    To set the maximum value for the number of inodes or files for this volume, run the following command. Replace the SVM and volume names with the values for your use case:

::> set -privilege advanced::*> vol modify -vserver fsx -volume vol1 -files-set-maximum true

2.    To verify the change, run the following command. Replace the SVM and volume names with the values for your use case:

::*> volume show -vserver svm1 -volume vol1 -fields files

Related information

Troubleshooting - You have insufficient volume capacity

Increasing a volume's storage capacity

AWS OFFICIAL
AWS OFFICIALUpdated 10 months ago
2 Comments

Can I check the following best practice? I think the following part is "up to 80%" instead of "close to 80%". I am not sure the reason to keep the ratio without specific settings in ONTAP itself and why users need to keep it by user side.

Note: When increasing the number of files in your volume, pay attention to the used inodes and the used aggr space. It's a best practice to keep the used inodes and aggr space values close to 80%.

profile picture
replied a year ago

Thank you for your comment. We'll review and update the Knowledge Center article as needed.

profile pictureAWS
MODERATOR
replied a year ago