homepage Welcome to WebmasterWorld Guest from 54.242.241.20
register, free tools, login, search, pro membership, help, library, announcements, recent posts, open posts,
Become a Pro Member

Home / Forums Index / Hardware and OS Related Technologies / Website Technology Issues
Forum Library, Charter, Moderators: phranque

Website Technology Issues Forum

    
Outgrowing server - what now?
expert_21

10+ Year Member



 
Msg#: 4605 posted 1:48 pm on May 22, 2006 (gmt 0)

Alright, basiclly I need to host a rather busy PHP/MYSQL website. Currently I have a webserver ( Dual Xeon 2.8GHz, 2GB, SCSI HD) cross connected to a database server of similar spec. I've done all optimization I could and it seems that the site is just outgrowing the server. I've got rather high server loads sometimes, sometimes services like FTP & DNS crashes, etc. The problem lies in the webserver as the database server is still fine.

So the question is, what is my next move?

Do I get some caching system? (cant use the mmCache / APC cause they frequently crashes my apache)
Do I get a better speced webserver?
Do I get 2 webservers and load balanced?
Do I get hardware load balancing or dns load balancing?
Do I get a private rack?

Note that the database server has to be somehow connected to the webservers.
Please give your opinions, thank you :)

 

txbakers

WebmasterWorld Senior Member txbakers us a WebmasterWorld Top Contributor of All Time 10+ Year Member



 
Msg#: 4605 posted 2:10 pm on May 22, 2006 (gmt 0)

If you are crashing the database with that powerful a server either you are getting millions of hits, or your queries are very inefficient.

Anothe factory could be that you have severe memory leakage.

Are your connections closed after using them? Are you destroying your objects?
Have youoptimized all your queries for efficiency?
Using indexes wherever possible?

all these things cut down on the hit to the server memory.

jfricker

5+ Year Member



 
Msg#: 4605 posted 3:30 am on May 30, 2006 (gmt 0)

Nifty problem. Gotta love success.

First, you should examine your database schema and make sure that you have all the indices you should. One index can make a world of difference.

If that doesn't save the day (or buy you more time) than consider a database upgrade. MySQL will use extra RAM for query caching. If your queries are well designed, it can save a ton of time on reads.

Next, you really shouldn't move forward without specific analysis of your systems - hardware and software. There are many directions to go to improve performance and some will work in certain situations and some won't.

If your site is filled with db reads and your pages have a ttl of a couple minutes, you might consider putting Squid in front of the web server as a reverse proxy. A single CPU with 4 GB of ram can make an enormous load with Squid.

Reveal a few more details about your website and I'll try to help.

jfricker

5+ Year Member



 
Msg#: 4605 posted 3:34 am on May 30, 2006 (gmt 0)

Oh two more simple ideas.

Move DNS off the webserver. And remove FTP if you can. It won't save the day, but I believe that web servers should serve the web and that other servers can do the other things.

Also, 2GB might be too little for the webserver. Tune down the MaxRequests to defeat any hidden memory leaks and reduce the MaxClients and corresponding Min/MaxSpare configs. Reduce the amount of memory needed. Heck throw another 2GB in the box for grins.

I assume since it's so successful you've got budget.

Global Options:
 top home search open messages active posts  
 

Home / Forums Index / Hardware and OS Related Technologies / Website Technology Issues
rss feed

All trademarks and copyrights held by respective owners. Member comments are owned by the poster.
Home ¦ Free Tools ¦ Terms of Service ¦ Privacy Policy ¦ Report Problem ¦ About ¦ Library ¦ Newsletter
WebmasterWorld is a Developer Shed Community owned by Jim Boykin.
© Webmaster World 1996-2014 all rights reserved