FUDforum
Fast Uncompromising Discussions. FUDforum will get your users talking.

Home » FUDforum Development » Bug Reports » slow mysql query (may not be a bug......)
Show: Today's Messages :: Polls :: Message Navigator
Switch to threaded view of this topic Create a new topic Submit Reply
slow mysql query [message #166476] Mon, 19 December 2011 21:23 Go to next message
andy_scouser is currently offline  andy_scouser
Messages: 76
Registered: June 2003
Karma: 1
Member
Hi there.

I upgraded the forum today to 3.0.3 and am now experiencing a noticeable slow down when ever a message is selected. My mysql-slow.log is reporting lots of the same errors.

I wonder if you could offer any guidance please?

# Time: 111219 23:17:31
# User@Host: honda[honda] @ localhost []
# Query_time: 14 Lock_time: 0 Rows_sent: 7 Rows_examined: 252391
SELECT
m.*, COALESCE(m.flag_cc, u.flag_cc) AS disp_flag_cc, COALESCE(m.flag_country, u.flag_country) AS disp_flag_country,
t.thread_opt, t.root_msg_id, t.last_post_id, t.forum_id,
f.message_threshold,
u.id AS user_id, u.alias AS login, u.avatar_loc, u.email, u.posted_msg_count, u.join_date, u.location,
u.sig, u.custom_status, u.icq, u.jabber, u.affero, u.aim, u.msnm, u.yahoo, u.google, u.skype, u.twitter, u.users_opt, u.last_
visit AS time_sec,
l.name AS level_name, l.level_opt, l.img AS level_img,
p.max_votes, p.expiry_date, p.creation_date, p.name AS poll_name, p.total_votes,
1 AS cant_vote
FROM forum_msg m
INNER JOIN forum_thread t ON m.thread_id=t.id
INNER JOIN forum_forum f ON t.forum_id=f.id
LEFT JOIN forum_users u ON m.poster_id=u.id
LEFT JOIN forum_level l ON u.level_id=l.id
LEFT JOIN forum_poll p ON m.poll_id=p.id WHERE m.thread_id=16286 AND m.apr=1 ORDER BY m.id ASC LIMIT 20 OFFSET 0;
Re: slow mysql query [message #166477 is a reply to message #166476] Tue, 20 December 2011 02:37 Go to previous messageGo to next message
naudefj is currently offline  naudefj   South Africa
Messages: 3771
Registered: December 2004
Karma: 28
Senior Member
Administrator
Core Developer
The query takes 0.0010 secs to run here on fudforum.org.
Re: slow mysql query [message #166480 is a reply to message #166477] Wed, 21 December 2011 06:44 Go to previous messageGo to next message
andy_scouser is currently offline  andy_scouser   United Kingdom
Messages: 76
Registered: June 2003
Karma: 1
Member
ok, maybe i have a local issue then.... can you offer any ideas at all please? all the database tables look ok but i ran a 'repair table' on them any way.

Here is my environment if it held at all.



UDforum version: 3.0.3
PHP version: 5.2.6-1+lenny13
Database type: mysql (mysql)
Database version: 5.0.51a-24+lenny5-log
Web server: Apache
Web Server load: 4.99
Web server to PHP interface: apache2handler
WebServer User/Group: www-data / www-data (33/33)
Relevant PHP settings:
Safe mode: OFF
Open basedir: none
Display errors: ON
File uploads: ON
Maximum file upload size: 8M
Magic quotes: ON
Output buffering: No
Disabled functions: none
PSpell support: No
Zlib support: Yes


[Updated on: Wed, 21 December 2011 06:44]

Report message to a moderator

Re: slow mysql query [message #166483 is a reply to message #166480] Wed, 21 December 2011 12:27 Go to previous message
andy_scouser is currently offline  andy_scouser   United Kingdom
Messages: 76
Registered: June 2003
Karma: 1
Member
Update, I've had to roll back the forum 3.0.2 and the forum is now 'super fly fast' as usual and all of my slow searches have disappeared. I did however take a full dump of the forum (filesystem and database), which ill apply to my home media server (acer r3700) to see if i can reproduce the problems. Hopefully if i do find out anything ill report back and have another go at 3.0.3.

Thanks all and have a fantastic, well earned christmas
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: Avatar Approval
Next Topic: Bug with display of date in Russian
Goto Forum:
  

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ]

Current Time: Thu Nov 21 14:34:04 GMT 2024

Total time taken to generate the page: 0.02009 seconds