Re: [PHP-DB] Joomla MySQL query performance affected by anything non-server related?

[email protected] (Afan Pasalic)
Newsgroups php.db
Message-ID <[email protected]>
TG wrote:
> Been getting the occasional warning on one of our client sites about 
> excessive CPU usage and/or slow MySQL queries.
>
> Looking at the logs, it looks like it's more the latter (slow queries).
>
> Some of the queries involve some joins, etc.  But nothing too crazy, and 
> there are the standard indexes on most of the relevant columns used in 
> join/where clauses.  Everything Joomla 1.5 does when it does it's initial 
> setup.
>
> I've done everything the web host recommends and the last thing they said to 
> check the PHP code and try to optimize that a bit.  But it's standard 
> Joomla 1.5 stuff.  They claim they don't have any other clients having 
> problems with Joomla 1.5.
>
> In the end, I think this is a problem with their MySQL server or their server 
> in general, but they won't admit to that.  So forgive me if this is more of 
> a MySQL issue and not so much PHP-DB related, but it's the PHP side that is 
> the last thing they're recommending I check that I technically haven't 
> because I think Joomla's probably fine.
>   
sounds like hostmonster.com :-)
had the same issue few times.
tried to figure out and wasn't able. talked several times with support 
and "suddenly" it was working ok again.

afan



> As an example of a query that showed up on the log recently:
>
> UPDATE jos_content SET hits = ( hits + 1 ) WHERE id='123'
>
> The log says this took 7 seconds.  There's an index on "id".  There are only 
> 400 or so records in the whole table.  It's not like there are a million 
> records and no index.
>
> Is there ANY rational reason this query would EVER take 7 seconds to execute?
>
>
> Any info/thoughts/advice would be appreciated.  I know my way around a 
> database or two and know a few things about optimization, but I need some 
> solid evidence to throw at this web host so they'll listen to me.  They're 
> usually really awesome, but this case is causing me to lose my hair.
>
> Thanks in advance!
>
> -TG
>
>
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.