I have a problem where I have a ton of files in a folder and I can't delete them. Every time I use the RM command on the folder to delete all the files I get kicked out of my ssh connection.
Is there a way to limit the RM command to say 500 files?
You can't delete all the files and folder with rm is because the argument list is too long. You need to use xargs to break it down into smaller chunks. There was a discussion here not too long ago.
Code:
find . | xargs rm -rf
--== Anything can go wrong. It's just a matter of how far wrong it will go till people think its right. ==--
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.