[Webinar] Streamline your web hosting managementRegister Today

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 347
  • Last Modified:

TCP Connections and System Responsiveness.

Hi Experts,

My questions relate to linux tcp connections and the responsiveness of programs that reqiure them.  Let me lay the background.  

We have a webserver, (its extreemly busy, runs about 30-40 sites, most of which receive thousands of visitors a day).  It runs a CGI language called lasso, (similar to php).  From that CGI we have created a content management system for those 30-40 sites, which is fairly database entinsive.  It runs about 10-15 queries to load 1 simple page.  More intense pages could be between 50-100 database queries per page.

Now that CGI has a database connector which it uses to connect to MySQL.  To do that it creates a TCP connection on a specific port, doing a netstat on the server will show all active connections.

We are having major stability problems at this point and I want to understand why this is happening and whos problem it is.

What happens is suddenly the server stops accepting incoming connections to the CGI, and therefore stops serving our websites.  If we do a netstat at this point we see hundreds of connections for a whole bunch of different programs, the CGI language being 1, but also apache  and mysql sometimes as well.  Restarting any one of these programs to free up those TCP connections allows for the server to start serving the websites again.

What I am wondering is, can I increase the Max # of tcp connections, and would this help my cause?  Is this safe to do?  How do I go about doing it?

Any ideas or insight are greatly appreciated.

Thanks for your time.
0
seanostephens
Asked:
seanostephens
  • 3
  • 2
1 Solution
 
omarfaridCommented:
Before thinking of increasing the # of tcp connections, what about CPU load, memory, IO on the disks, etc?

If you have a loaded server, then consider expanding it or moving some load to another server.
0
 
seanostephensAuthor Commented:
CPU, memory and disk usage are nil, during the times when the server isn't responsive because it isn't accepting connections to do anything.   The only processes are happening are internal ones.  
0
 
omarfaridCommented:
So try to increase the max and see if it improves
0
Get expert help—faster!

Need expert help—fast? Use the Help Bell for personalized assistance getting answers to your important questions.

 
seanostephensAuthor Commented:
Omarfarid, Thanks for your comments.  I am running RedHat EL 4.4.  How would I go about doing that?  I suppose I would need to rebuild the kernel?  Would there be any performace detriments to doing so?  Is there something else that could be causing the symptoms I describe?

Thanks again.
0
 
omarfaridCommented:
Here link to performance tuning guide:

http://www.eslim.co.kr/pds/pds/2/5/RHEL_Tuning_Guide.pdf
0
 
Computer101Commented:
Forced accept.

Computer101
EE Admin
0

Featured Post

Receive 1:1 tech help

Solve your biggest tech problems alongside global tech experts with 1:1 help.

  • 3
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now