• Our team is looking to connect with folks who use email services provided by Plesk, or a premium service. If you'd like to be part of the discovery process and share your experiences, we invite you to complete this short screening survey. If your responses match the persona we are looking for, you'll receive a link to schedule a call at your convenience. We look forward to hearing from you!
  • We are looking for U.S.-based freelancer or agency working with SEO or WordPress for a quick 30-min interviews to gather feedback on XOVI, a successful German SEO tool we’re looking to launch in the U.S.
    If you qualify and participate, you’ll receive a $30 Amazon gift card as a thank-you. Please apply here. Thanks for helping shape a better SEO product for agencies!
  • The BIND DNS server has already been deprecated and removed from Plesk for Windows.
    If a Plesk for Windows server is still using BIND, the upgrade to Plesk Obsidian 18.0.70 will be unavailable until the administrator switches the DNS server to Microsoft DNS. We strongly recommend transitioning to Microsoft DNS within the next 6 weeks, before the Plesk 18.0.70 release.
  • The Horde component is removed from Plesk Installer. We recommend switching to another webmail software supported in Plesk.

Resolved Need to remove backups on CentOS 7 server via SSH

seanfod

New Pleskian
Hello. I am new to this forum and to SSH really as i have always accessed my VPS via Plesk. I have a CentOS 7 VPS and it appears i have run out of disk space as i cannot access the Plesk control panel and WordPress websites are coming up with database connection errors now after attempting to backup a farly large WordPress site.

I knew that i was close to maxing out the disk space and feel pretty stupid now for not doing something sooner.

My question is, how can i free up disk space via SSH and how do i remove server backups via SSH?

Thank you in advance...
 
Hi @seanfod, thank you for your post. You can

1) Find out the location of your local backups:
# grep DUMP_D /etc/psa/psa.conf
Normally it is /var/lib/psa/dumps, but just in case it was modified it is better to check it in the configuration file first.

2) Then descend into that path, let's say it is /var/lib/psa/dumps
# cd /var/lib/psa/dumps

3) There you can see several daily and historical dump files that should not be removed because you might still need them, and you can see further paths like /clients and /domains. You are looking for the /clients path. Descend into it (# cd clients). From there you see further directories that are named like the user names on your Plesk.
Maybe you are only interested in the five backup directories that occupy the most space. Then simply descend into the "clients" directory and run
# du -hs * | sort -h | tail -n 5
All these directories contain the full backup data of these users. Let's say one of these paths is named "myuseraccount", then you can

4) remove that user path to remove all of the users backup information, e.g.
# rm -R -f myuseraccount
or
# rm -R -f /var/lib/psa/dumps/clients/myuseraccount
 
Hi @seanfod, thank you for your post. You can

1) Find out the location of your local backups:
# grep DUMP_D /etc/psa/psa.conf
Normally it is /var/lib/psa/dumps, but just in case it was modified it is better to check it in the configuration file first.

2) Then descend into that path, let's say it is /var/lib/psa/dumps
# cd /var/lib/psa/dumps

3) There you can see several daily and historical dump files that should not be removed because you might still need them, and you can see further paths like /clients and /domains. You are looking for the /clients path. Descend into it (# cd clients). From there you see further directories that are named like the user names on your Plesk.
Maybe you are only interested in the five backup directories that occupy the most space. Then simply descend into the "clients" directory and run
# du -hs * | sort -h | tail -n 5
All these directories contain the full backup data of these users. Let's say one of these paths is named "myuseraccount", then you can

4) remove that user path to remove all of the users backup information, e.g.
# rm -R -f myuseraccount
or
# rm -R -f /var/lib/psa/dumps/clients/myuseraccount
Many thanks Peter. Much appreciated :)
 
Back
Top