Latest Article

Casbay News

Promotions

Casbay Events

Tips Sharing

aaa

Stay tuned with us

Linux VPS server storage

3 Tips To Free Up Spaces For Linux VPS Server

Have you ever encountered issues where the storage of your VPS is full? Or situations where you want to free up some files to get a slight improvement in the performance of the server? Or perhaps you just wanted to tidy up the files in the server. However, it may be unknown to you which file is safe to be removed or where to begin with. This article will guide you on how to remove your unwanted files.

1. Delete Temporary Files

Temporary files are a copy of the original file uploaded to the server. Hence whenever a file is uploaded through the file manager in cPanel, a temporary copy will be created in the temporary folder As time passed, where more and more files were uploaded, the number of temporary files will also pile up which could result in consuming a huge portion of the storage. Use the following command to remove the temporary files.

rm -fv /home/*/tmp/Cpanel_*

2. Remove Spare Backups

Most people do have backup files for their VPS and it is unreasonable to ask users to remove their backup copy for their VPS. However for this case, just removes backup files which are more than a month old, and you may and should still keep your automated backup system on.

for user in '/bin/ls -A /var/cpanel/users' ; do rm -fv /home/$user/backup-*$user.tar.gz ; done

3. Use CleanUp

CleanUp is an open-source PHP script that is commonly used for cleaning up unwanted files for the server under direct FTP access. This is a convenient and effective way of removing old or unused files from the server. The file types that could be removed using CleanUp are:

  • log files
  • HTML files
  • Image files such as jpeg, jpg png, and etc.
  • CSS styleshets

There are also advanced options, such as removing files based on the file size and type, recursively removing subdirectories, and adding wildcards to filenames. This is working as intended to free up space on your VPS Server swiftly and effectively.