Slow Outgoing Connections

7 posts / 0 new
Last post
#1 Tue, 04/22/2014 - 08:44
diesel72

Slow Outgoing Connections

I have recently set up a 1&1 new server with Webim/Virtualmin and everything seems to be running smoothly except for outgoing connections.

On our original 1&1 server the outgoing connections whether using wget from the command line or file_get_contents from php are pretty much instant regardless of whether it's a local domain on the server or an external domain like google.com (typically less than a second)

On our new server these same outgoing connections are taking 5 seconds. And it always seems to be 5 seconds as if it's limited. I have been unable to find a reason for this.

Not even sure if this is Virtualmin realted at all, but any help would be much appreciated, as this is causing scripts on the server to timeout.

CentOS release 6.5 (Final) Webmin version 1.680 Virtualmin version 4.06.gpl GPL

Tue, 04/22/2014 - 09:26
andreychek

Howdy,

What you're describing wouldn't be Virtualmin related... it's difficult to say what the issue is, but let's start with DNS.

Try running the command "host google.com" -- when doing so, does the output show up fairly quickly? Or does it take awhile?

-Eric

Tue, 04/22/2014 - 10:03 (Reply to #2)
diesel72

Thanks for the response.

Comparing the servers, it takes 1-2 seconds on the new server , but on the old server after the 1st time it's instant. On the new server it takes the same time no matter how may times.

Tue, 04/22/2014 - 10:22
andreychek

Howdy,

What is the output of this command:

cat /etc/resolv.conf

Tue, 04/22/2014 - 10:33 (Reply to #4)
diesel72
nameserver 10.255.255.4
nameserver 10.255.255.3
nameserver 127.0.0.1
; generated by /sbin/dhclient-script
Tue, 04/22/2014 - 14:12
andreychek

Howdy,

You may want to try commenting out the first two nameservers, and just use the one that points to "127.0.0.1".

After doing that, see if the lookups occur a bit quicker for you.

-Eric

Wed, 04/23/2014 - 08:39 (Reply to #6)
diesel72

Thanks,

That seems to have done the trick.

I'm guessing that 1&1's default server set up is badly configured, then. Their support wasn't much use either.

Again Thanks.

Topic locked