web application connection time out

Dear Experts

We are running web server (10.253.18.41) which is on lamp stack and database server mysql is on another server 10.253.12.42, users are complaining the application is taking too long time also on prospect conversion takes too much time and finally timeout approx 3 mins then time out , when check the network statics below is the continuous report, please let me know what does this indicate, what could be the solution

tcp        0      0 10.253.18.41:38760          10.253.12.42:3306           TIME_WAIT
tcp        0      0 10.253.18.41:38765          10.253.12.42:3306           TIME_WAIT
tcp        0      0 10.253.18.41:38274          10.253.12.42:3306           TIME_WAIT
tcp        0      0 10.253.18.41:38130          10.253.12.42:3306           TIME_WAIT
tcp        0      0 10.253.18.41:38590          10.253.12.42:3306           TIME_WAIT
tcp        0      0 10.253.18.41:38116          10.253.12.42:3306           TIME_WAIT
tcp        0      0 10.253.18.41:39296          10.253.12.42:3306           TIME_WAIT
tcp        0      0 10.253.18.41:38577          10.253.12.42:3306           TIME_WAIT
tcp        0      0 10.253.18.41:38379          10.253.12.42:3306           TIME_WAIT
tcp        0      0 10.253.18.41:39027          10.253.12.42:3306           TIME_WAIT
tcp        0      0 10.253.18.41:38827          10.253.12.42:3306           TIME_WAIT
tcp        0      0 10.253.18.41:38222          10.253.12.42:3306           TIME_WAIT
tcp        0      0 10.253.18.41:38225          10.253.12.42:3306           TIME_WAIT
D_wathiAsked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

x
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Martyn SpencerSoftware Developer / Linux System Administrator / Managing DirectorCommented:
TIME_WAIT indicates that one side (the local side, I believe) has closed the TCP connection. Because of the way that the TCP protocol works, it cannot immediately close a connection but must wait in case other packets arrive. You can read more about this by looking up how the TCP protocol works.

With regard to the delay that you are seeing, it is more likely to be server side and application related. You have asked a few questions related to this before and I think that the delays you are experiencing are not specifically due to the network connection. You should verify your network connectivity as a separate process and not try to combine the diagnostics with the application you are experiencing problems with. Simplify your tests as much as possible and you will narrow down the problem to the cause more effectively.
1

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
nociSoftware EngineerCommented:
From the RFC: 793, pg 20.

TIME-WAIT - represents waiting for enough time to pass to be sure
    the remote TCP received the acknowledgment of its connection
    termination request.

So this is the normal state after a link has been closed.  Actually it is to prevent accidentally closing a new connection by old packets.
The time normally is 2 minutes.
This probably has little to do with slowness, unless you have >40K connections running.
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Databases

From novice to tech pro — start learning today.