views:

98

answers:

2

We host our web-service on a dedicated server. Sometimes (I'd say 1 out of 20) a response is not received from the server. That makes the browser fallback with time-out error.

An important detail: the request is not logged by Apache in this case.

There is no load on Apache, there are a lot of free memory and CPU power left.

[UPDATE] I have profiled the problem case with tcpdump utility. These are the good and bad sessions traced by tcpdump. The request is the same in both experiments. Good - server returns response. Bad - no response, time-out error.

Do you see why the problem happens from these data? How can I move further to get closer to the source of the error?

I've replaced my real ip address with 123.45.67.890

---- Bad ----
12:23:36.366292 IP 123.45.67.890.61749 > myserver.superbservers.com.www: S 2125316338:2125316338(0) win 8192 <mss 1460,nop,wscale 2,nop,nop,sackOK>
12:23:39.362394 IP 123.45.67.890.61749 > myserver.superbservers.com.www: S 2125316338:2125316338(0) win 8192 <mss 1460,nop,wscale 2,nop,nop,sackOK>
12:23:45.365567 IP 123.45.67.890.61749 > myserver.superbservers.com.www: S 2125316338:2125316338(0) win 8192 <mss 1460,nop,nop,sackOK>
--------

---- Good ----
12:27:07.632229 IP 123.45.67.890.63914 > myserver.superbservers.com.www: S 3581365570:3581365570(0) win 8192 <mss 1460,nop,wscale 2,nop,nop,sackOK>
12:27:10.620946 IP 123.45.67.890.63914 > myserver.superbservers.com.www: S 3581365570:3581365570(0) win 8192 <mss 1460,nop,wscale 2,nop,nop,sackOK>
12:27:10.620969 IP myserver.superbservers.com.www > 123.45.67.890.63914: S 2654770980:2654770980(0) ack 3581365571 win 5840 <mss 1460,nop,nop,sackOK,nop,wscale 6>
12:27:10.838747 IP 123.45.67.890.63914 > myserver.superbservers.com.www: . ack 1 win 4380
12:27:10.957143 IP 123.45.67.890.63914 > myserver.superbservers.com.www: P 1:213(212) ack 1 win 4380
12:27:10.957152 IP myserver.superbservers.com.www > 123.45.67.890.63914: . ack 213 win 108
12:27:10.965543 IP myserver.superbservers.com.www > 123.45.67.890.63914: P 1:630(629) ack 213 win 108
12:27:10.965621 IP myserver.superbservers.com.www > 123.45.67.890.63914: F 630:630(0) ack 213 win 108
12:27:11.183540 IP 123.45.67.890.63914 > myserver.superbservers.com.www: . ack 631 win 4222
12:27:11.185657 IP 123.45.67.890.63914 > myserver.superbservers.com.www: F 213:213(0) ack 631 win 4222
12:27:11.185663 IP myserver.superbservers.com.www > 123.45.67.890.63914: . ack 214 win 108
--------

Hosting: SuperbHosting OS: Ubuntu

+1  A: 

I don't think this is the kind of question you ask on SO or any other forum - you should ask that question to yourself first.

I would suggest running a bunch of tests: 1) simple ping over a longer amount of time 2) run sniffer on your pc and on the server - look at what's going on there.

Depending on the results you may try some other things.

kubal5003
Thanks. I have the following details so far.1. Ping fails occasionally. 1 out of 402. Client sniffer (HTTP Analyser) does not display the response in case of error.I'm going to track down the network packets with wireshark on the server. Though I'm not a network specialist, don't know how to interprete the data.
Pavel
Since ping is also failing, it seems a network issue, like an overloaded link somewhere on the path between you and your server. Maybe traceroute can help to find where exactly your packets get lost?
Wim
I have profiled server network traffic with tcpdump. See the update to the question. Can you tell from the dumps why the server does not respond?
Pavel
+1  A: 

Packets are getting dropped somewhere along the path. The Internet is one very large network and each link is a potential point where packets can get dropped. The tcpdump does not tell you anything except that there is no response coming back from the server.

You can try traceroute on UNIX or tracert on Windows to possibly find a routing issue. You can also try using a hosted tool like http://network-tools.com/ to see if it has the same packet drops. If it doesn't then this would point to your source network is the problem, not the network your web server is at.

hwatkins