My linux web server is really slow

tom on November 1st, 2006

Recently I noticed one of my new dedicated servers serving pages being somewhat sluggish.

Being that this was a brand new generic production server, it may not have been optimized. So I decided to dive in and take a look at the resolver…

First I simply typed mii-tool into the console to see the ethernet ports. The message I got meant things were pretty much alright:

eth0: negotiated 100baseTx-FD, link ok

Next I discovered that I can find information about the resolver by looking at a particular file. I typed this into the console:

cat /etc/resolv.conf

Which, for other users, may yield something similar to:

nameserver 10.0.0.1

search mydomain.com

The second line is what’s bad for me. I commented that line out and added in another resolver which I received from a technician support via an online support desk interface.

To edit files I use vi which is easy to use for quick edits in my opinion. To edit the resolv.conf file simply type:

vi /etc/resolv.conf

I just added in a second line after the first nameserver, so my resolv.conf looked something like:

nameserver 10.0.0.1

nameserver 10.0.0.2

#search mydomain.com

After which I saved the file and restarted my web server (apache).

I immediately noticed a speed increase after doing this!

This may not solve someone elses speed problem but it could be a problem plaguing someone else out there. I hope it helps.


Comments are closed.