- To: georgev@xxxxxxxxxxxxxxxxxxxxxx
- Subject: Re: [SLUG] Help with rm
- From: Russell Davies <russell.davies@xxxxxxxxxxxxx>
- Date: Tue Aug 29 09:45:31 2000
- Cc: slug@xxxxxxxxxxx
; I have this from time to time and I think the way I did it is remove the
; files 1 at a time using this command:
;
; find /bad/directory/* -print -exec rm -fr {} \;
that's horribly inefficient (assuming it works), surely if the problem
is a limitation on argv, then wouldn't your /bad/directory/* above
overflow as well? It was for this reason that I didn't suggest
something like
cd $dir && echo * | xargs -n 400 rm -f
which would certainly be preferable to unlinking one file at a time.
Then you would probably get everything in two separate invocations.
r.