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

2011-08-24 Thread Heikki Vatiainen
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 100 and the FarmSize is 4,
 is there a total of 400 bytes allocated or is it just 100? 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 h...@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.
___
radiator mailing list
radiator@open.com.au
http://www.open.com.au/mailman/listinfo/radiator


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

2011-08-23 Thread Frank Danielson
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? For 
example if my SocketQueueLength is 100 and the FarmSize is 4, is there a 
total of 400 bytes allocated or is it just 100? 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?

Frank Danielson
ClearSky Mobile Media, Inc. | fdaniel...@csky.commailto:fdaniel...@csky.com

A human being should be able to change a diaper, plan an invasion, butcher a 
hog, conn a ship, design a building, write a sonnet, balance accounts, build a 
wall, set a bone, comfort the dying, take orders, give orders, cooperate, act 
alone, solve equations, analyze a new problem, pitch manure, program a 
computer, cook a tasty meal, fight efficiently, die gallantly. Specialization 
is for insects.

-Robert A. Heinlein

___
radiator mailing list
radiator@open.com.au
http://www.open.com.au/mailman/listinfo/radiator