|
Posted by Brendan Gillatt on 10/09/07 16:38
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Gilles Ganault wrote:
> Hello
>
> A friend of mine is running a LAMP (PHP, MySQL, Apache,
> Debian) Web 2.0 site on a dedicated, hosted server with about 300
> connected users when it's really busy.
>
> The server is an Intel Celeron 2.4 GHz with 1GB of RAM, a 40GB IDE
> drive, and a 10Mbps bandwith.
>
> Here's what top says:
>
> Tasks: 196 total, 6 running, 181 sleeping, 8 stopped, 1 zombie
> Cpu(s): 71.6% us, 8.6% sy, 0.0% ni, 58.0% id, 0.8% wa, 0.3% hi, 0.7%
> si
> Mem: 1023656k total, 963348k used, 60308k free, 119612k buffers
> Swap: 514040k total, 0k used, 514040k free, 484324k cached
>
> The site is too slow in the evenings, but we don't have the skills to
> check why and what can be done about it.
>
> For all you LAMP experts out there: What things would you try to see
> where the bottlenecks are? Is there some kind of check-list that we
> could go through?
>
> Thanks for any tip!
In your code (I'm using PHP for example here, adjust to your language)
disable any output from it and insert echo time(); every now and then.
Once you've run that, consolidate the numbers into something like gnuplot
(I'm guessing you're using linux here) and make a graph to see where the
page takes most of the time.
- --
Brendan Gillatt
brendan {at} brendangillatt {dot} co {dot} uk
http://www.brendangillatt.co.uk
PGP Key: http://pgp.mit.edu:11371/pks/lookup?op=get&search=0xBACD7433
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.3 (MingW32)
iD8DBQFHC66NkA9dCbrNdDMRAoAkAKCcxc0CnYnoT9ib/2D4q5CdWpur3QCglPVw
Fm7BxGhrGCMKYGJ7/jLm//4=
=T5Mw
-----END PGP SIGNATURE-----
Navigation:
[Reply to this message]
|