Re: Server load too high



ewunia@xxxxxxxxxxxxx wrote:
> I am running the tagboard service on my server. Few months ago I bought
> the new dedicated server with Dual Xeon 3.2 GHz and 2GB Ram.
> The board is written in PHP with Mysql. Not long ago I updated the
> version PHP to 5. and the problem started.
>
> The load on the server skyrocked between 39-52. And I seriously have no
> idea what to do about it.
>
[snip]

Well, since it looks like MySQL is eating more of the CPU, it could be
part of the equation. I'm not entirely certain of all of the
differences between the PHP 4.x and PHP 5.x, but it is entirely possible
by that upgrading, you may have found a design error in the application
or database arrangement.

My inclination would be to see what version of MySQL you're using, check
that against the MySQL client library that PHP5 is using, and see if
you're using the mysql or mysqli extensions for PHP. If you're using
mysql.so and you're using a newer version of MySQL, consider switching
to the mysqli.so extension.

Also, as stated earlier by someone else, check to see what the queries
are doing.

Your load average may have jumped, also, if the way processes are
spawned changed between the releases, but I'm not sure if that's
something to do with PHP at all, so that could be totally wrong.

In any case, I've been using PHP5 for a while now, and I've not
encountered any bugs of this sort caused by valid code... although one
thing that I haven't really done yet is work with PHP4 object code on
PHP5, since I find PHP5 objects better. Do you use PHP4 objects? Maybe
you can try to isolate the behavior better somewhere, if you have the
chance to play in a test environment and try to isolate the cause.

Later,
Mike
.



Relevant Pages

  • Re: Speed up web pages : MySQL or PHP solutions ?
    ... People come to us to view 1 image or text + 1 PHP content. ... Can you click on the image = MYSQL ... Make your content cacheable by sending appropriate HTTP headers. ... Cache content on the server to avoid re-creation over and over again, ...
    (comp.lang.php)
  • Executing PHP files on remote web server
    ... We have a web app which uses PHP and MySQL on our in-house Apache web ... database to the web host because a lot of the data is sensitive. ... By loading the non-sensitive data into the web host's MySQL tables, ... running on our own web server. ...
    (comp.lang.php)
  • Re: Newbie Security Questions
    ... questions about PHP and its usage with MySQL. ... And even if they do, its a strange Mysql server that is sitting on the internet accepting requests from all and sundry..normally you run them on a local network, or the same box and set mysql to only accept requests FROM the apache server.. ... You have to layer that over the top using cookies and user logins if you want it. ...
    (comp.lang.php)
  • Re: phpMyAdmin install help
    ... this means that PHP is lacking a certain functionality. ... talking to MySQL servers. ... It doesn't really matter where the MySQL server is running. ...
    (php.general)
  • Re: getting file size for really big (10GB) files?
    ... I am surprised that PHP can't simply get the same result as 'ls'. ... limitations on the server installation I can use. ... Php5 on Fedora I really expected to ...
    (comp.lang.php)