SPUG:CGI header question

Brian Hatch spug at ifokr.org
Thu Jun 19 16:09:14 CDT 2003



> This was about four years ago now. It may have gotten better. If anyone knows
> why shells don't/didn't do dynamic allocation of memory for big * expansions,
> I'd be curious.

Denial of service.  You don't want processes taking up all the memory
on a machine.

And there are many non-shell workarounds:

	$ find . -maxdepth 1 -print | xargs -n 100 -P 20 rm
	

Would run 20 copies of rm simultaneously, with 100 files to
be deleted at a time.  Drop the '-maxdepth 1' if you want
it to recurse all subdirs too.


Now many filesystems do slow down as your directory gets too
big.  However the kernel also should be caching in memory those
files that are accessed most recently, so those should be faster
to respond anyway.

--
Brian Hatch                  I admire your bad
   Systems and                qualities and I
   Security Engineer          wouldn't have you
http://www.ifokr.org/bri/     part with a single one

Every message PGP signed
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
Url : http://mail.pm.org/pipermail/spug-list/attachments/20030619/bdef2180/attachment.bin


More information about the spug-list mailing list