[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

Re: Number of processes and memory allocation

On Sun, Apr 23, 2006 at 10:58:36PM +0200, Joerg Maschtaler wrote:
> I run two Tor server which settings are very similar and i can't figure
> out why one of them runs only one process with a memory allocation of ~
> 10 MB (online since 6 h) and the other one runs six processes with a
> memory allocation up to 120MB.

Another explanation is that the small one is hibernating, meaning it
killed all its worker processes. When it wakes up it will respawn them.


> So my question is:
> How does Tor determine the number of processes and the allocation of memory?


The number of processes is 1 + the number of dns workers + the number
of cpuworkers.

The number of cpuworkers is typically 1, but you can control it with
the NumCpus torrc option. The number of dnsworkers is three to start,
and then Tor tries to be smart depending on how many DNS resolve requests
it's getting at once.