Previous Thread
Next Thread
Print Thread
Hop To
#238595 08/10/2010 10:35 AM
Joined: Jun 2006
Posts: 28
S
newbie
newbie
S Offline
Joined: Jun 2006
Posts: 28
Am in the process of setting up and testing version 7 after upgrade from 6.5 to 7.5. We have quite a lot of posts from years past, but performance has never at all been an issue.

After creating a new user, UBB seems to go away and take *forever* running the following queries from the category/forum list screen:

# Query_time: 15 Lock_time: 0 Rows_sent: 1 Rows_examined: 52580

SELECT COUNT(p.POST_ID) AS POSTS, SUM(p.POST_IS_TOPIC) AS TOPICS, t.FORUM_ID FROM ubbt_POSTS as p, ubbt_TOPICS as t
(t.TOPIC_ID = p.TOPIC_ID) AND p.POST_IS_APPROVED = 1 AND (0 OR (t.FORUM_ID = 1 AND p.POST_POSTED_TIME > 0)) GROUP BY t.FORUM_ID;

It does this for every single forum.

The result:

"Generated in 90.780 seconds in which 90.730 seconds were spent on a total of 31 queries. Zlib compression enabled."

Clearly an index is missing somewhere, but I can't work out what needs to be added.

So:

1. Does the server REALLY need to be doing 31 queries when someone tries to pull up a list of the categories? That sounds way excessive and inefficient.

2. If yes, how can we get those queries down to a fraction of a second?

Thanks

Last edited by Snarf; 08/10/2010 10:38 AM.
Joined: Jun 2006
Posts: 28
S
newbie
newbie
S Offline
Joined: Jun 2006
Posts: 28
Well I just found the "Show total # of unread posts per forum?" option and turned that off. Looks like that reduced the # of queries to 11.

I assume that was the problem!

Joined: Apr 2007
Posts: 3,940
Likes: 1
SD Offline
Former Developer
Former Developer
Joined: Apr 2007
Posts: 3,940
Likes: 1
you should go to the content rebuilder and rebuild forums / topics (one shot)

get those indices re-indexed for going forward..

Joined: Jun 2006
Posts: 28
S
newbie
newbie
S Offline
Joined: Jun 2006
Posts: 28
Thanks, will try that.

Another unrelated question, but I don't want to start tons of new threads:

While UBB6 by default used UBB codes in format color:red, it also allowed UBB codes in the form color:"red". UBB7 doesn't accept the quote version. This is resulting in a lot of messed up UBB6 posts on our upgraded board.

Does anyone know of a simple hack to make UBB7 accept color:"red" ?

Thanks

Joined: Apr 2007
Posts: 3,940
Likes: 1
SD Offline
Former Developer
Former Developer
Joined: Apr 2007
Posts: 3,940
Likes: 1
4 ways to approach it (maybe more, if i noodle on it)

1. change bbcode.inc.php to parse it properly into html that works, then content rebuild all posts
2. modify the content rebuilder to change the original (POST_DEFAULT_BODY), then rebuild it
3. hijaack smarty output to change it on the fly right before rendering
4. if there are a small number of colors used, then use 'Active Text' (control panel option) replace to make it 'right'

either way, you'll have to rebuild, so i might lean towards #2 if there is no consistent color pattern used..

or #4 if it's just a few cases..


Link Copied to Clipboard
ShoutChat
Comment Guidelines: Do post respectful and insightful comments. Don't flame, hate, spam.
Recent Topics
spam issues
by ECNet - 03/19/2024 11:45 PM
Looking for a forum
by azr - 03/15/2024 11:26 PM
Editing Links in Post
by Outdoorking - 03/15/2024 9:31 AM
Question on barkrowler and the like
by Mors - 02/29/2024 6:51 PM
Member Permissions Help
by domspeak - 02/27/2024 6:31 PM
Who's Online Now
1 members (Havenofsobriety), 522 guests, and 99 robots.
Key: Admin, Global Mod, Mod
Random Gallery Image
Latest Gallery Images
Los Angeles
Los Angeles
by isaac, August 6
3D Creations
3D Creations
by JAISP, December 30
Artistic structures
Artistic structures
by isaac, August 29
Stones
Stones
by isaac, August 19
Powered by UBB.threads™ PHP Forum Software 8.0.0
(Preview build 20230217)