Solved

What settings could I set the Global Configuration of Apache in order to take full advantage of server resources?

Posted on 2012-03-25
7
289 Views
Last Modified: 2012-04-29
What settings could I set the Global Configuration of Apache in order to take full advantage of my servers resources?  My site gets 40,000+ people per a day so I want my settings to be configured properly to handle all of the traffic and at the same time take full advantage of the resources of my server (btw I have my DB on a separate server and my site is coded in PHP).

There's all kinds of settings I can adjust which include: Start Servers, Minimum Spare Servers, Maximum Spare Servers, Server Limit, Max Clients, Max Requests Per Child, Keep-Alive, Keep-Alive Timeout, Max Keep-Alive Requests, Timeout, and so many more (most of them I don't really understand).

Here are the specs of my server:
Dual Intel Xeon 5620 Quad Core Processors with Hyperthreading (16 threads)
18GB DDR3 RAM
1x 1TB Hard drive
10TB Bandwidth
cPanel (WHM Accelerated 2)

Thanks
0
Comment
Question by:davideo7
  • 4
  • 3
7 Comments
 
LVL 76

Assisted Solution

by:arnold
arnold earned 500 total points
ID: 37763947
You have to adjust the number of clients you want to start with to 20, with a max of 100.
How much resources does your site require for a single page access is everything database driven?

You can start with that and then adjust,

There are several tools you can use to load test your setup
http://stackoverflow.com/questions/250866/php-load-testing-framework
There are similar tools for mysql that you should tune as well phpmyadmin, etc.
There are slow query option in mysql to log such that you could see whether you have queries that take a long time.

etc.

From the looks of the apache server, your harddrive will likely be the bottleneck.

Presumably you have 1GB network possibly two one for the web responses and one for the access to the DB.
0
 

Author Comment

by:davideo7
ID: 37768856
arnold: What do you mean I have to adjust the number of clients I want with to 20 and a max of 100?

I don't completely understand your question.
0
 
LVL 76

Assisted Solution

by:arnold
arnold earned 500 total points
ID: 37768957
The default setup is 5 spare with 50 or so max.  Without knowing what the single user connection trigger in terms of how many follow up requests it generated.
There are tools that you can use to load test your setup
25 spare
150 max
50 requests per client
Keep alive timeout 15 seconds
Timeout 5 seconds
Max keep alive requests 15
0
What Is Threat Intelligence?

Threat intelligence is often discussed, but rarely understood. Starting with a precise definition, along with clear business goals, is essential.

 

Author Comment

by:davideo7
ID: 37768970
arnold: Are you suggesting that I use those settings?
0
 
LVL 76

Expert Comment

by:arnold
ID: 37768996
Yes, and then use the tool to load test then configuration.
It is hard to predict the distribution of the 40,000+ unique visitors could reflect an active user or a few non complex page accesses.
0
 

Author Comment

by:davideo7
ID: 37769195
arnold: That didn't really help, sorry.  

Here's a little more information.

In the past 15 minutes, there's been 1100+ people on my site and according to google analytics, there's 556 people no my site at this very second.  Also my site gets nearly 500,000 page views a day.
0
 
LVL 76

Accepted Solution

by:
arnold earned 500 total points
ID: 37769228
It is still telling me nothing.  Are you having issues with the server?
Have you deteremined that the issue is with the apache configuration rather than with your PHP, mysql?

Tunning is for improving performance.  I have no way of knowing what issues you are trying to address.

information on the parameters are such
when your system boots, the number of start servers means how many httpd process will be started without waiting for a single request.

max requests per client deals with how many sequential requests within the same connection will be allowed prior to forcing the client to reconnect.  Setting the number too high could contribute to a DoS i.e. a client connects and keeps making requests multiply this by max and that is what it will take to lock your web server so that it can not respond to new requests.

http://httpd.apache.org/docs/2.0/misc/perf-tuning.html

Your question provides no context so I am trying to set one and see how your system would perform under load.
0

Featured Post

Find Ransomware Secrets With All-Source Analysis

Ransomware has become a major concern for organizations; its prevalence has grown due to past successes achieved by threat actors. While each ransomware variant is different, we’ve seen some common tactics and trends used among the authors of the malware.

Join & Write a Comment

If you've heard about htaccess and it sounds like it does what you want, but you're not sure how it works... well, you're in the right place. Read on. Some Basics #1. It's a file and its filename is .htaccess (yes, with a dot in the front). #…
Password hashing is better than message digests or encryption, and you should be using it instead of message digests or encryption.  Find out why and how in this article, which supplements the original article on PHP Client Registration, Login, Logo…
The viewer will learn how to dynamically set the form action using jQuery.
The viewer will learn how to create and use a small PHP class to apply a watermark to an image. This video shows the viewer the setup for the PHP watermark as well as important coding language. Continue to Part 2 to learn the core code used in creat…

760 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

22 Experts available now in Live!

Get 1:1 Help Now