How to Empty Directory With Large Number of Files

The easiest and the fastest way to empty directories with a large number of files is with the following command. Add this command in my public technical diary for future reference. 

Go to the directory which contains a large number of files.  For example, files name are like sip_20201002145227__410060544193744.log .

find . -name "sip_2020*" -delete

Enjoy ;)

No comments:

Post a Comment

How to deploy MySQL on Kubernetes Cluster ?

Pre-Requisite kubernetes cluster is ready if not Follow  this  blog. kubectl get nodes -o wide OUTPUT NAME STATUS ROLES A...