Beefy Boxes and Bandwidth Generously Provided by pair Networks
Syntactic Confectionery Delight
 
PerlMonks  

(MeowChow) Re2: Non-linear sub-routine launching

by MeowChow (Vicar)
on Apr 04, 2002 at 03:24 UTC ( #156552=note: print w/ replies, xml ) Need Help??


in reply to Re: Non-linear sub-routine launching
in thread Non-linear sub-routine launching

  
One word of warning - spawning too many children too fast can saturate your network so don't write a Denial of Service hack on your own servers!

Are you sure? I seriously doubt that a server could fork off processes at a rate fast enough to saturate a decent network, assuming that all each process does is send normal pings once every few seconds.

   MeowChow                                   
               s aamecha.s a..a\u$&owag.print


Comment on (MeowChow) Re2: Non-linear sub-routine launching
Re: (MeowChow) Re2: Non-linear sub-routine launching
by tachyon (Chancellor) on Apr 04, 2002 at 05:56 UTC

    As you correctly note with a ping of 512 bits (32 bytes each way) I agree it would seem very unlikely that you could spawn processes fast enough to cause problems (even on a narrow 10Mbps network you expect a good 3Mbps before you get collision problems so you would need to spawn over 6,000 processes in a second if they all made a single ping). However once someone discovers the awesome power of fork() it is necessary to consider the potential problems. For instance if you used the default 4 x 32 byte ping instead of a single ping you only need 1,250 odd processes.... I have some vague recollection of bringing a network to a standstill with an ill considered forking script - admittedly each process was sending more data than a simple ping. Another consideration is how many processes you spawn. You certainly can potentially spawn enough to bring a server to a grinding halt.

    cheers

    tachyon

    s&&rsenoyhcatreve&&&s&n.+t&"$'$`$\"$\&"&ee&&y&srve&&d&&print

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others lurking in the Monastery: (7)
As of 2014-09-16 00:55 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    My favorite cookbook is:










    Results (155 votes), past polls