How to check the number of inodes
You can check the number of inodes in cPanel in the following way:
Step 1: Log into cPanel
Step 2: Scroll down to the Statistics section on the right sidebar and look for Inodes
Step 3: To access comprehensive statistics, navigate to the Advanced section, and then click on Terminal.
This interface grants command-line access to your server account. By default, the terminal will log you into your account’s home directory, located above the public_html directory.
Step 4: For a comprehensive list of inode usage within the current directory, run the following command:
echo "Detailed Inodes usage for: $(pwd)" ; for d in `find -maxdepth 1 -type d |cut -d\/ -f2 |grep -xv . |sort`; do c=$(find $d |wc -l) ; printf "$c\t\t- $d\n" ; done ; printf "Total: \t\t$(find $(pwd) | wc -l)\n"
This command will present the inode count on the left column and the respective folder on the right, much like the example provided below
As per the example above, the highest number of inodes comes from the public_html directory. To browse to the public_html directory from your terminal, execute the following command:
cd public_html
Execute the command given in Step 4 again
echo "Detailed Inodes usage for: $(pwd)" ; for d in `find -maxdepth 1 -type d |cut -d\/ -f2 |grep -xv . |sort`; do c=$(find $d |wc -l) ; printf "$c\t\t- $d\n" ; done ; printf "Total: \t\t$(find $(pwd) | wc -l)\n"
Results similar to this should be obtained
How to reduce inode usage
Delete Unwanted Files/Folders
Remove unnecessary files or directories. For instance, you can delete old backups or staging files.
Manage Emails
If inodes are used by your email system, delete old emails or use built-in features like cPanel’s Email Disk Usage tool.
Navigate to cPanel and go to Email ➝ Email Disk Usage
Now you can easily delete any old or unwanted emails from here
Clear Caches
CMS like WordPress often generate cache files. Regularly clear or purge cache folders to save inodes.