On 07/03/2011 10:56 PM, Eugene Grosbein wrote:

There is internal queue of messages in the mpd-5.5 with length 8129.
Messages are generated based on various events and enqueued there, then 
processed.

Mpd uses GRED algorithm to prevent overload: it accepts all new L2TP connections
when queue has 10 or less slots occupied (unprocessed events).

It drops all connections then it has over 60 slots occupied.
s/all/new incoming/

In between, it drops new message with probability equal to (q-10)*2 percents
s/message/L2TP connection/

where q is number of occupied queue slots. These constants are hardcoded in its 
src/ppp.h

Each time it decided to ignore incoming L2TP requests it notes that in the log,
as you have already seen.
Eugene Grosbein


Hi Eugene,
if I undestand corectly, in order to increase the connection rate I need to replace 60 with 600 and 10 with 100 like this:

  #define SETOVERLOAD(q)        do {                                    \
                                    int t = (q);                        \
                                    if (t > 600) {                      \
                                        gOverload = 100;                \
                                    } else if (t > 100) {               \
                                        gOverload = (t - 100) * 2;      \
                                    } else {                            \
                                        gOverload = 0;                  \
                                    }                                   \
                                } while (0)

 Is this enough, or I need to modify something else ?

--
Best regards,



_______________________________________________
freebsd-net@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-net
To unsubscribe, send any mail to "freebsd-net-unsubscr...@freebsd.org"

Reply via email to