max number of processes

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • yawnmoth

    #1

    max number of processes

    how can i determine what the maximum number of processes i should open
    with popen (or proc_open) is? i assume it'd depend on the hardware of
    the computer in question, but if that were teh case, then is there a
    way to get info. about it, and some general method to determine a good
    number of processes to open from that info?
  • Sundial Services

    #2
    Re: max number of processes

    yawnmoth wrote:
    [color=blue]
    > how can i determine what the maximum number of processes i should open
    > with popen (or proc_open) is? i assume it'd depend on the hardware of
    > the computer in question, but if that were teh case, then is there a
    > way to get info. about it, and some general method to determine a good
    > number of processes to open from that info?[/color]

    If you have to ask... you're contemplating opening /way/ too many processes.

    The number of processes that are alive at any one time should be small. You
    should /never/ "create a process, let it handle one request and die." The
    more runnable processes there are, the less time per-second each process
    can receive. If you want to process several requests, use a queue, and
    have the children remove requests from that queue.

    Comment

    • yawnmoth

      #3
      Re: max number of processes

      Sundial Services <info@sundialse rvices.com> wrote in message news:<co21uf$o7 j$1@domitilla.a ioe.org>...[color=blue]
      >
      > <snip>
      >
      > If you have to ask... you're contemplating opening /way/ too many processes.
      >
      > The number of processes that are alive at any one time should be small. You
      > should /never/ "create a process, let it handle one request and die." The
      > more runnable processes there are, the less time per-second each process
      > can receive. If you want to process several requests, use a queue, and
      > have the children remove requests from that queue.[/color]

      would an implementation whereby ea. process accessed a single file /
      used that file as a queue be sufficient?

      although that said, i think for my purposes, multiple processes may be
      better (please correct me if i'm wrong). i'm trying to detect whether
      or not those attempting to perform a certain action on a website are
      doing so from proxies. because it takes about a second to reject a
      proxy (well, using 1 as the timeout) it'd take about 8 seconds (if i
      wanted to take 8 ports). that's a bit too much time, so i'm using
      multiple processes to reduce it to (ideally) a second.

      Comment

      Working...