troubleshooting Question

Multiple Folder Contents Deletion & Drive Space Issue

Avatar of msryhajw
msryhajw asked on
Linux
9 Comments1 Solution262 ViewsLast Modified:
I am trying to delete the content of two folders on a dedicated linux server that I access remotely via SSH as the HD is 97% full.

The folders are called 'cache' and 'tcache' and contain cached contents that are egenerated on the fly. These folder exist on over 100 domains hosted on a cpanel server so what I am looking for is a way to recursively delete all of the files contained in these folders. It should also be noted that rm gives the following error due to file number limitations just in one of the folders "-bash: /bin/rm: Argument list too long"

The question is if there is an easier way of see where the space is being used on the server and how to remove the cache files all in one without having to manually go through each folder.

TIA

Join the community to see this answer!
Join our exclusive community to see this answer & millions of others.
Unlock 1 Answer and 9 Comments.
Join the Community
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 1 Answer and 9 Comments.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros