0

There is sometimes a 1-2 second delay when connecting to port 80 (nginx) over the public interface.

It occurs 50% of the time.

Once connected nginx serves all requests, including fastcgi proxy requests, lightning fast.

I have confirmed it is not a DNS resolution delay on the client side.

OS is Linux 2.6

What should I check to find out what is causing this initial delay to accept?

doodler
  • 1
  • 1

1 Answers1

0

I would start with two things. First get a pcap capture of the connection both when it is working and when its slow. You can use wireshark or tcpdump to do this. Wireshark will give you a nice GUI to look at it to compare. The second is to enable connection debugging in nginx. If the network capture looks good then you'll probably see some resource issue in nginx. Both should have timestamps in the output so you can see where you are losing time!

polynomial
  • 4,016
  • 14
  • 24