MyBB Community Forums

Full Version: MySQL Errors
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2
One of our MyBBs gives several MySQL errors. It usually has more than 500 unique visitors online. So mostly gives "max_user_connection" errors. However I see those following errors firstly. I have repaired them in phpMyAdmin, but now it gives "max_user_connection" error. I wonder what caused all these errors.



MySQL error: 1194
Table 'mybb_forums' is marked as crashed and should be repaired
Query: SELECT fid,name,linkto FROM mybb_forums WHERE fid IN (0,2,101,69,8,160,71,69,69,139,70,91,69,111,152,152,11,2,70,108,7,23,5,4,9,12,62,167,62,62,7,105,25,
16,4,135,10,83,69,76,4,91,72,161,83,91,91,23,161,135,8,8,8,8,8,8,8,7,74,60,2,70,10,25,9,70,105,8,8,7,8,
101,2,7,69,105,66,105,7,15,8,83,8,60,8,107,131,69,69,62,89,89,23,66,66,62,8,62,69,82,107,8,8,102,8,60,
62,60,62,62,77,111,77,106,163,62,8,102,107,12,72,79,12,105,2,132,4,101,76,132,17,108,108,69,164,135,
8,5,12,69,62,12,23,135,12,161,77,9,74,108,66,111,111,135,161,161,157,15,9,2,12,162,161,135,163,4,69,
72,66,163,111,93,111,111,15,165,165,71,72,102,102,69,165,62,2,77,132,8,111,83,62,77,70,111,62,82,62,
75,167,101,62,2,76,77,77,111,23,62,5,15,89,135,23,101,102) AND fid NOT IN ('90')


MySQL error: 126
Incorrect key file for table './XXX_XXX/mybb_datacache.MYI'; try to repair it
Query: REPLACE INTO mybb_datacache (title, cache) VALUES ('stats','a:5:{s:10:\"numthreads\";i:8280;s:8:\"numposts\";i:94325;s:8:\"numusers\";i:17793;s:7:
\"lastuid\";s:5:\"17864\";s:12:\"lastusername\";s:7:\"sat7ram\";}')



MySQL error: 1194
Table 'mybb_forums' is marked as crashed and should be repaired
Query: SELECT * FROM mybb_forums WHERE active != 'no' ORDER BY pid, disporder
You should discuss this with your host.
That is a sign that your host simply cannot handle the load. It's nothing that MyBB purposely causes. You should look into optimizing your MyBB setup like caching the datacache to flat files (an option in the acp) among other things. MyBB Games, and My Blog have tutorials on optimization
I tried all optimization methods as it's told in MyBB Games, but our board has still the same problems and also gives Internal Server error as well as it's very slow, especially the mainpage. I contacted the server admin; he says "there is no problem with the server, but the board's database locks mysql" I couldn't understand the problem exactly. Should I change the server? If I do, what kind of server should we have so as to handle this load? Thanks.
The MySQL server isn't configured to support the number of requests your forums would appear to be receiving.

Is it shared web hosting?

This could also be caused by a large amount of plugins which are not optimised.

How many queries do you see in the footer on the index, forum display and show thread pages?

Regards,
Chris
In fact, while opening showthread, forumdisplay and other pages, there is not an important problem. But the problem is with the main page; it's so slow. For example, try opening those two pages, and you'll see the difference:

any thread page (slow): http://www.ingilizceforum.net/why-academ...-7382.html
mainpage (more and more slower): http://www.ingilizceforum.net

The previous server was a shared one, which also caused the same problems. But now I pay a dedicated server from Superb in Washington Hopone, still have the same problems. The new server is just hosting around 30 websites.

I use SEO plugin, maybe the reason for max load? But it's very important as it let Google send many visitors to the site.

In main page, queries: header, header_include, forums, todays_birthdays, online_today, footer, and etc. I think they are standart.

If the problem with the server, how can we configure the number of requests for the board? What about etc/my.cnf configuration? For example, max_connection is set to 100, etc. Thanks.
max_connections should be higher than that if you're on a dedicated server. It sounds to me as if your entire server could do with a deal of optimisation (MySQL, PHP, Apache) to be getting the most juice out of it.

By queries, I meant the total number. Can you scroll to the bottom of the page when logged in as an administrator and copy the slab of text talking about page generation time, MySQL queries and server load and paste it here? It should be similar to the following:
Quote:Generated in 0.0763020 seconds (48.10% PHP / 51.90% MySQL)
MySQL Queries: 15 / Global Parsing Time: 0.0365140 / Memory Usage: 1.73 MB
PHP version: 5.2.5-0.dotdeb.1 / Server Load: 0.2 / GZip Compression: Disabled
[advanced details]

Can you paste that information for the index, show thread and forum display plugins? Even though they may be quick loading, they could be sending a large amount of queries to the MySQL server.
Mainpage;

Quote:Generated in 46.2564211 seconds (3.57% PHP / 96.43% MySQL)
MySQL Queries: 30 / Global Parsing Time: 11.9589541 / Memory Usage: 6.35 MB
PHP version: 5.2.5 / Server Load: / GZip Compression: Disabled

Show Thread;

Quote:Generated in 0.5575762 seconds (25.78% PHP / 74.22% MySQL)
MySQL Queries: 15 / Global Parsing Time: 0.1080861 / Memory Usage: 5.46 MB
PHP version: 5.2.5 / Server Load: / GZip Compression: Disabled

Thanks.
That's uhh, quite bad.

Can you click "[advanced details]", save the contents of that page and upload it here?

Regards,
Chris
Yes, it's unfortunately bad. I attach the debug info page here. Thanks.


[I removed the file] (Thanks)

I think "#28 - Query Time is 18.7323079" Who's online today 'pugin'?
Pages: 1 2