Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Trouble with ircd server...

Status
Not open for further replies.

nicuv

Technical User
Jun 4, 2000
1
0
0
RO
My ircd server does not accept more than 40 connections from more hosts, and i don't know where is the problem. Can anybody help me?<br><br>Thank you.
 
Whenever <FONT FACE=monospace>ircd</font> gets a new connection, does it fork a new server process?&nbsp;&nbsp;ie, when you've got 40 users connected, do you have 40 <FONT FACE=monospace>ircd</font> processes?<br><br>Also, is <FONT FACE=monospace>ircd</font> running under inetd?<br><br>If it's &quot;yes&quot; to both questions, then you may have hit a built in <FONT FACE=monospace>inetd</font> default.&nbsp;&nbsp;To prevent runaway processes bringing your system to a grinding halt, <FONT FACE=monospace>inetd</font> limits the number of instances of a daemon that may be started over a set time period.&nbsp;&nbsp;The default if for <b>40</b> connections over a 60 second period.<br><br>You can change this.&nbsp;&nbsp;The following is taken from the <FONT FACE=monospace>inetd</font> man page on one of our Unix boxes here.&nbsp;&nbsp;(No Linux boxes to hand with man pages installed at the moment...)<br><FONT FACE=monospace><br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;The -i option allows you to set the time interval (in<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;seconds) over which the number of daemons started by inetd<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;will be counted.&nbsp;&nbsp;The -n option allows you to specify the<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;number of instances of the same daemon that may be started<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;during the interval specified by -i. The defaults are 40<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;instances in 60 seconds.<br><br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;An example of the use of -n and -i is:<br><br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;inetd -i 30 -n 50<br><br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;which specifies that up to 50 instances of the same daemon<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;may be started in a 30 second period before inetd decides<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;that something is wrong and makes the daemon unavailable.<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;The daemon will become available again after a fixed period<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;of ten minutes or if SIGHUP is sent to inetd.&nbsp;&nbsp;These options<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;are likely to be needed only when many connections are being<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;opened and closed.<br></font><br>Note - changing these values may result in opening up your box to DoS attacks.&nbsp;&nbsp;Maybe you should look at running <FONT FACE=monospace>ircd</font> outside of <FONT FACE=monospace>inetd</font> if possible.
 
You may want to check the include/config.h file - There's some limits you can change in there to allow more users.<br>
 
Coincidentally, a similar question has just come up on the qmail mailing list.&nbsp;&nbsp;If you're running ircd under inetd, edit inetd.conf and change the &quot;nowait&quot; for ircd to &quot;nowait.120&quot;.&nbsp;&nbsp;This will increase the number of connections to 120 allowed in 60 seconds.&nbsp;&nbsp;Try playing with this value until you reach something that works for you.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top