Report this

What is the reason for this report?

How to sort out - bash: /bin/rm: Argument list too long

Posted on February 8, 2020

When running rm * in a directory that contains a lot of individual files might get the following error:

  1. bash: /bin/rm: Argument list too long

There are a few ways to delete the files inside that specific directory:

  • You could delete the whole folder
  • You could the find command - this is my personal favorite
  • Or use a for loop - much slower!

Here’s how to do that!

The developer cloud

Scale up as you grow — whether you're running one virtual machine or ten thousand.

Start building today

From GPU-powered inference and Kubernetes to managed databases and storage, get everything you need to build, scale, and deploy intelligent applications.