/bin/rm: Argument list too long
You type: rm * -f
You get: /bin/rm: Argument list too long
Reason: in shell when you do * after rm and get Argument list too long, your shell actually expands that * and puts all the filenames after rm and since length of the command line is limited, you end up getting argument list too long.
Possible solutions:
- You can remove the whole directory and recreate the directory
- When 1 is not an option, you can you “find” to delete for you. I actually use this method more often then removing/creating directory.
find . -exec rm {} \;This will delete everything in current directory on. Be careful with this command since you could potentially delete things you may not wanted to. I suggest runningfind . |morefirst to see what will be affected. To read more about find see: man find
————————————-
DISCLAIMER: Please be smart and use code found on internet carefully. Make backups often. And yeah.. last but not least.. I am not responsible for any damage caused by this posting. Use at your own risk.


[...] La solución que más me ha convencido y que al final he acabado utilizando ha sido la que puede encontrarse en esta página. [...]