If you are new to TikTikTalk ? Your first verification mail might be in your spam folder.Check there and move it to your inbox to complete registration or account verification process..
Patrocinado
sociofans

How to delete Backups in WHM/Cpanel with terminal

0
3K

Deleting old backups from the /backup directory in WHM or Cpanel is a complex process if you are managing a VPS server. However, if you are using shared web hosting companies like Namecheap and SiteGround, things are much simpler as you can delete backups with a single click using their customized backup systems or Softaculous.

Backup Problems

When I Installed WHM for the first time, I enabled monthly, weekly, and daily auto backups. My website disk usage of 10 GB suddenly rose to 99 GB within a few weeks. Buying more disk space was not an option because using more than 100 GB was not making financial sense. Therefore, I resorted to finding out ways of decreasing disk usage by removing old backups.

Below is how I managed to delete the backups after several hours of my website being down, reading tutorials, and failed command attempts.

How to delete Backups in WHM using Terminal

We are going to use the WHM terminal to delete the backups. You can also use an SSH client like PuTTY. This procedure assumes that you have used Terminal before and understand what you are doing.

Open Terminal in WHM or using PuTTY and log in using your root credentials then start running the commands below (do not include # before the commands).

  • Check disk space: # df -h
  • Go to the backup folder: # cd /backup
  • Check backup dates to delete (daily, weekly, or monthly): # dir
  • Backup dates will be listed in this format; 2019-11-26 monthly transports.db 2023-02-17 weekly
  • Run this command to delete backups by date: # rm -rf  2019-11-26

Replace the date above with your backup date.

IMPORTANT! Kindly note that if you run the command “rm -rf” without dates or a specified folder you will delete everything. Therefore proceed with caution. If you do not know what you are doing then DO NOT use the “rm -rf” command.

To go back and check if the disk usage has reduced after the deletion, run the command: # cd ..

cd..” means go back by one folder.

Conclusion  – Backup tip

If you want to avoid running out of disk space, do not keep more than one backup per day.  Also, ensure that you have carefully read the backup configuration options in WHM, then enable or disable scheduling and retention options that are necessary and unnecessary respectively.

Patrocinado
Patrocinado
Pesquisar
Patrocinado
Categorias
Leia Mais
Outro
Mobile Value-Added Services Vas Market Insight, Size, Share, Growth, Up-To-Date Key Trends, Regional Outlook, and Forecast – 2033
According to the Regional Research Reports, the global mobile value-added services vas...
Por Harshsingh 2023-10-12 09:56:01 0 3K
Drinks
Nike Air Max 95:經典重塑,奪目配色引領潮
在這個追求個性與舒適並重的時代,Nike Air Max 95 無疑是一款不可多得的經典鞋款。作為nike air max家族中的佼佼者,Air Max 95...
Por chm123 2024-10-12 02:45:59 0 3K
Outro
Arc Welding Equipment Market Business Outlook, current and Future Growth
Arc Welding Equipment Market Overview: The arc welding equipment market industry is projected to...
Por ellamrfr 2023-11-13 05:22:49 0 3K
Outro
Sea Bass Market size is expected to grow USD 6821.2 mn by 2030
  The global sea bass market size is expected to grow from USD 4,029.9...
Por marketstatsvillegroup 2023-09-14 12:26:30 0 4K
Outro
Latest News: Electronic Logging Device (ELD) Market Navigating Share and Scope Trends for 2024-2030
  The Electronic Logging Device (ELD) Market is witnessing significant growth, driven by...
Por siya09 2024-11-06 09:55:37 0 1K
Patrocinado