Beefy Boxes and Bandwidth Generously Provided by pair Networks
No such thing as a small change
 
PerlMonks  

Re: Re (tilly) 1: Limitations to chmod and performance

by arhuman (Vicar)
on Nov 12, 2001 at 18:48 UTC ( [id://124835]=note: print w/replies, xml ) Need Help??


in reply to Re (tilly) 1: Limitations to chmod and performance
in thread Limitations to chmod and performance

Working with a list of files and letting chmod do the loop is probably faster than looping over chmod statements. But if your list of files is very large, you could run out of memory. (Very unlikely, but there is a theoretical limit there.)

I'll furthermore add that, with many implementations of 'chmod' the number of args is limited,
and you'll probably hit a 'arg list too long' error way before you exhaust your memory...
(For example on my linux box I'm limited to around 12900 files as arguments...)

To my mind you'd definitly better use the one-at-a-time strategy...

Note : This problem also occurs with a lot of others file related tools : rm, ls...

"Only Bad Coders Code Badly In Perl" (OBC2BIP)
  • Comment on Re: Re (tilly) 1: Limitations to chmod and performance

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://124835]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others browsing the Monastery: (4)
As of 2024-04-19 01:33 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found