[RADIATOR] Question on FarmSize, SocketQueueLength, and net.core.rmem_max on Linux

Heikki Vatiainen hvn at open.com.au
Wed Aug 24 03:59:20 CDT 2011


On 08/23/2011 05:52 PM, Frank Danielson wrote:

> We are currently running Radiator 4.7 under Redhat 5.5 and I am 
> trying to make sure I understand the effect that the FarmSize
> setting has on the amount of memory allocated for the SocketQueue.
>
> If Radiator is configured with some FarmSize does each worker have
> its own SocketQueue with the effect of making the total amount of
> memory allocated = FarmSize * SocketQueueLength?

I think the allocated memory is always 1*SocketQueueLength. This is
based on the fact that the socket is shared between the clients and the
assumption that the socket queue is part of kernel and the fan out to
the workers happens on the OS/user space boundary. In other words, my
take is one socket queue servers one or multiple readers.

If someone know better, please let me know.

> For example if my SocketQueueLength is 1000000 and the FarmSize is 4,
> is there a total of 4000000 bytes allocated or is it just 1000000? In
> either instance I am assuming that the net.core.rmem_max size needs
> to be at least as large as that number, is that correct?

If my theory holds, then it might be a good idea to increase rmem_max
because there are multiple readers that can dequeue packets and smooth
incoming bursts.

An alternate view is, if there are always workers that are ready to
process messages, then they should be able to drain normal size queue
even if the queue input rate is high.

There's also /proc/sys/net/ipv4/udp_mem which migh be useful to tune UDP
queues only.

http://www.kernel.org/doc/man-pages/online/pages/man7/udp.7.html

This is an interesting question. If you decide to experiment with
different settings, maybe you could let us know of results.

Thanks!
Heikki

-- 
Heikki Vatiainen <hvn at open.com.au>

Radiator: the most portable, flexible and configurable RADIUS server
anywhere. SQL, proxy, DBM, files, LDAP, NIS+, password, NT, Emerald,
Platypus, Freeside, TACACS+, PAM, external, Active Directory, EAP, TLS,
TTLS, PEAP, TNC, WiMAX, RSA, Vasco, Yubikey, MOTP, HOTP, TOTP,
DIAMETER etc. Full source on Unix, Windows, MacOSX, Solaris, VMS,
NetWare etc.


More information about the radiator mailing list