How to Empty / Delete files .trash folder cPanel users

The .trash folder in /home/$username/.trash contains any files that a user has deleted via their cpanel’s file manager.  If your users are not clearing this out, it can start to eat up a lot of disk space on your server.

If you want to empty every users .trash folder, simply run this command.

 

find /home/*/.trash/* -exec rm -rf {} \;

 

If you also have a home2, home3, etc etc, you can use this command.

 

find /home*/*/.trash/* -exec rm -rf {} \;

 

  • 4 Users Found This Useful
Was this answer helpful?

Related Articles

How to fix cPanel 500 internal server error

How to fix cPanel 500 internal server errorYou need to run the following command in SSH to fix...

How to fix YumRepo Error and Cannot find valid baseurl

When you try to update or install any software inside your centos 6/7 you might will see the...

How to install WordPress Toolkit inside cPanel/WHM

The WordPress Toolkit interface allows you to easily install, configure, and manage WordPress®....

How to install let's encrypt cpanel/WHM

We are here to guide to let you know how to install the let's encrypt plugin inside cpanel/whm...

How to enable mod_suexec with Apache on cPanel

If your server requires that you run websites as the user’s account, run the following command to...