Web Hosting Talk







View Full Version : BIG Problem


anile8
09-09-2002, 12:46 AM
Well, my site is getting about 15k uniques / day now and things are becoming SLOW. Really slow. I don't know if it's because of a lack of bandwidth or because of my configuration. What do you recommend for MaxClients MaxChilds in Apache config? Any ideas?

Thanks.

EDIT: I don't think it's bandwidth. After 5 mins of restarting apache check this out:

1:36am up 11:16, 1 user, load average: 0.11, 0.32, 0.17
178 processes: 176 sleeping, 1 running, 1 zombie, 0 stopped
CPU states: 0.3% user, 1.9% system, 0.0% nice, 97.6% idle
Mem: 239404K av, 216760K used, 22644K free, 48K shrd, 4152K buff
Swap: 1052248K av, 18988K used, 1033260K free 106544K cached

It ate the memory so damn fast.

I have
MinSpareServers 20
MaxSpareServers 50
StartServers 50
MaxClients 256
MaxRequestsPerChild 50

mod_gzip is not on. I'm using Apache 1.3.26

Server specs: Athlon XP 1800, 256MB Ram

How can I get a 15k uniques / day site running on this server?

2host.com
09-09-2002, 06:26 AM
This would likely be caused by some CGI or PHP script, or possibly one of the two above using a lot of MysQL processes, or something else. Check "ps aux" and see what results you get. If this shows Apache as being high usage, then match the PID (proccess ID number (the first one shown on each line)) in "ps aux" and match that up with the same PID it shows on Apache's server-satus page. You might need to enable server status in your Apache configueation file (be sure to limit the IP's that can view it).

You can use that information to see what sites are matching that particular PID and if they are getting a lot of hits and to what path to what file. You can better pinpoint the cause of the load if that's the case. You can also check netstat to see what owner, process and the like and how many accesses are being made to what port and what program/service.

anile8
09-09-2002, 08:40 AM
So you think it's more likely PHP and MySQL?

goldenplanet
09-09-2002, 11:10 AM
Originally posted by anile8
Well, my site is getting about 15k uniques / day now and things are becoming SLOW. Really slow. I don't know if it's because of a lack of bandwidth or because of my configuration. What do you recommend for MaxClients MaxChilds in Apache config? Any ideas?

Thanks.

EDIT: I don't think it's bandwidth. After 5 mins of restarting apache check this out:

1:36am up 11:16, 1 user, load average: 0.11, 0.32, 0.17
178 processes: 176 sleeping, 1 running, 1 zombie, 0 stopped
CPU states: 0.3% user, 1.9% system, 0.0% nice, 97.6% idle
Mem: 239404K av, 216760K used, 22644K free, 48K shrd, 4152K buff
Swap: 1052248K av, 18988K used, 1033260K free 106544K cached

It ate the memory so damn fast.

Server specs: Athlon XP 1800, 256MB Ram


I really don't see a problem in the above numbers... :confused:

CPU-usage is low and the load is fair - stay below 1.00 - 1.50 and you're generally in the green. The memory usage is fair as well - Linux usually uses up all available memory for cache and reduces the cache as needed.

Do you have any idea what your bandwith usage may be?

coight
09-09-2002, 11:13 AM
mod_perl eats memory up if your using cpanel. Try to disable it in httpd.conf

anile8
09-09-2002, 11:30 AM
Turns out the speed problem was some idiot DoSing FDC.

Seems to be better now. Thanks for the help.