Previous Thread
Next Thread
Print Thread
Rate Thread
#243850 04/23/2003 8:39 PM
Joined: Feb 2002
Posts: 295
Member
Member
Offline
Joined: Feb 2002
Posts: 295
Hi,

Lately I have been getting more and more complaints from my users that my board is very slow, and unfortunately they are right.

The problem is that we can't find out what is causing this. We are running on a dual Netra 300 MHz with 1Gb of memory (dedicated server) and the board isn't that big (~30-35 users at any given time, ~170K posts). I would think that the machine should be able to cope, but according to my partner it is running at 0% idle time and both harddisk are busy contiuously as well.

Obviously the easiest solution would be to throw more hardware at this, but hardware is not cheap. Besides we only upgraded to this server (donated by our members, btw) 6 months ago.

For the moment we have switched off full tracking, but both I and the members much prefer having this switched on.

One possible solution we are thinking about is moving all posts older than 3 months to a read-only archive. Unfortunately since we would want this to be in a different database, we have not figured out how to do this.

Suggestions would be more than welcome.

Sanuk!

PS Oh, we are running 6.1.1 btw

Sponsored Links
Joined: Apr 2001
Posts: 3,266
Member
Member
Offline
Joined: Apr 2001
Posts: 3,266
You could also set the default postlist to 10 posts which will save alot of queries to the database versus say a 20 post limit.

Joined: Apr 2002
Posts: 1,768
Addict
Addict
Offline
Joined: Apr 2002
Posts: 1,768
Did switching off full tracking make the response time acceptible?

Joined: Feb 2002
Posts: 295
Member
Member
Offline
Joined: Feb 2002
Posts: 295
Hi,

Thanks for the suggestion, but it already is set to 10.

Sanuk!

Joined: Apr 2002
Posts: 206
Member
Member
Offline
Joined: Apr 2002
Posts: 206
Have you isolated it to be a board thing? IE - if you close the boards for a few minutes, does the server calm down?

What are the most accessed files? Do you have logs running for that? If you can find out what's being used the most, you can work on reducing the load that the particular script does to the server.

A suggestion would be to turn off zlib compression if it is running. It improves speed by compressing files -- the problem is that in high-traffic sites this means that the processor is doing a lot of extra work compressing stuff.

Hope that helps a bit.

Sponsored Links
beatdown #243855 04/23/2003 10:26 PM
Joined: Feb 2002
Posts: 295
Member
Member
Offline
Joined: Feb 2002
Posts: 295
Hi,

"Have you isolated it to be a board thing?"
Not really, but since this is the only thing running on the server (AFAIK) it seems highly unlikely that it is something else, right?

"What are the most accessed files?"
From the logs:
Code
<br />1 215546   9.03%   /showflat.php<br />2 110445   4.63%   /postlist.php<br />3  62068   2.60%   /stylesheets/nanaplaza_ubb61.css<br />4  49674   2.08%   /ubbthreads.php<br />5  23681   0.99%   /stylesheets/nanaplaza.css<br />

The stylesheets I am assuming are irrelevant.

"A suggestion would be to turn off zlib compression if it is running."
It isn't.

Anyway, thanks for the suggestions.

Sanuk!

Joined: Feb 2002
Posts: 295
Member
Member
Offline
Joined: Feb 2002
Posts: 295
Hi,

One of my board members suggested upgrading the MySQL to version 4.0.12 and switching on the caching. However he also mentioned that this is still very new and that perhaps it could conflict with UBBT.

Does anybody here know?

Sanuk!

Joined: Apr 2002
Posts: 206
Member
Member
Offline
Joined: Apr 2002
Posts: 206
In the case of showflat being the highest hit page (215 000 - is that in one month? Quite the traffic )...

-in theme settings, you could turn sown the default number of shown posts from where it is now. (variable amount of speed recovered)
-not show pictures with people's posts (a little speed recovered)
-turn off/remove ratings (a little speed recovered)
-if installed with php, turn on zlib as an experiment...it will reduce the size of the info being sent, but increase processor usage... it has the potential to make it much slower, or much faster, or balance out to do nothing (in which case it might be best with it off)

anyone else got any ideas?

beatdown #243858 04/24/2003 11:51 PM
Joined: Feb 2002
Posts: 295
Member
Member
Offline
Joined: Feb 2002
Posts: 295
Hi,

"In the case of showflat being the highest hit page (215 000 - is that in one month? Quite the traffic )..."
About 22 days, I think. Traffic is decent yes

"-in theme settings, you could turn sown the default number of shown posts from where it is now."
Already down to 10.

"-not show pictures with people's posts (a little speed recovered)"
Hmmm, I think this would hardly be worth the bother since those come from other servers.

"-turn off/remove ratings (a little speed recovered)"
Removed already.

"-if installed with php, turn on zlib as an experiment...it will reduce the size of the info being sent, but increase processor usage... it has the potential to make it much slower, or much faster, or balance out to do nothing (in which case it might be best with it off)"
I'd rather not try this since our server is already at 0% idle time

Anyway, thanks for the suggestions.

Sanuk!

joeuser #243859 04/24/2003 11:54 PM
Joined: Feb 2002
Posts: 295
Member
Member
Offline
Joined: Feb 2002
Posts: 295
Hi,

(sorry missed this one)

"Did switching off full tracking make the response time acceptible?"
Yes, it made a rather large difference. It is annoying to check the board without it though

Sanuk!

Sponsored Links
Joined: Apr 2002
Posts: 206
Member
Member
Offline
Joined: Apr 2002
Posts: 206
[]ksanuk said:
"-not show pictures with people's posts (a little speed recovered)"
Hmmm, I think this would hardly be worth the bother since those come from other servers.
[/]

They may come from other servers, but the URL is grabbed from your database. It is just a tiny recovery though.

beatdown #243861 04/25/2003 1:56 AM
Joined: Feb 2002
Posts: 295
Member
Member
Offline
Joined: Feb 2002
Posts: 295
Hi,

Okay, point taken. Still I think this would not be noticable.
Our biggest problem seems to be too many posts (I think my partner said that the post table was something like 1Gb?), which is why I would like to move a chunk of them to an archive.

Sanuk!

Joined: Dec 2000
Posts: 1,471
Addict
Addict
Offline
Joined: Dec 2000
Posts: 1,471
[]One of my board members suggested upgrading the MySQL to version 4.0.12 [/]

We use MySQL 4.0x for several months now. It runs stable and the performance improvement is quiet impressive.
Caching will not work, cause the posts table gets changed all the time.

-Fusion- #243863 04/25/2003 2:15 AM
Joined: Apr 2002
Posts: 102
Journeyman
Journeyman
Offline
Joined: Apr 2002
Posts: 102
[]Astaran said:
Caching will not work, cause the posts table gets changed all the time. [/]

It may not work on the posts table, but it will help on a lot of other tables, and if you run any other php/mysql scripts on your site it would help with them as well.

Turning off full new post tracking on the front page is inevitable once you reach a certain popularity (unless you have wads of cash to throw into hardware).

Joined: Apr 2002
Posts: 1,768
Addict
Addict
Offline
Joined: Apr 2002
Posts: 1,768
[]"Did switching off full tracking make the response time acceptible?"
Yes, it made a rather large difference. It is annoying to check the board without it though [/]

I've also heard that upgrading to MySQL 4 can help, but don't have personal experience with this.

Is your MySQL configuration file tuned optimally for your server? The MySQL distribution includes three or four sample config files, designed for different situations. Then you can customize it further yourself.

I don't know enough about MySQL to help with this, but others might be able to help. Also, I think that at mysql.com, you can pay them for a custom tuning.

AleksejVL #243865 04/25/2003 3:38 AM
Joined: Dec 2000
Posts: 1,471
Addict
Addict
Offline
Joined: Dec 2000
Posts: 1,471
I can't say anything about tables apart from the ubbthreads ones, but cache rate for the ubbthreads tables is rather bad.

I tested it on my live board, i got:

| Qcache_queries_in_cache | 823
| Qcache_inserts | 22941
| Qcache_hits | 26280

So it doesn't have much effect.

If you have a large post table, the search option is normally the bottleneck.
If users submit queries that fullfill several table scans, the server load increased dramatically and all others queries are locked.

You can do some mysql and change the search routines, but that depends on the individual server configuration.

joeuser #243866 04/25/2003 3:45 AM
Joined: Feb 2002
Posts: 295
Member
Member
Offline
Joined: Feb 2002
Posts: 295
Hi,

"Is your MySQL configuration file tuned optimally for your server?"
Knowing my partner I think it likely is. His MySQL skills are quite decent (much better than mine ).

Perhaps a combination is in order, more RAM, upgrade MySQL and remove a bunch of old posts.

Sanuk!

-Fusion- #243867 04/25/2003 4:35 AM
Joined: Apr 2002
Posts: 102
Journeyman
Journeyman
Offline
Joined: Apr 2002
Posts: 102
How long had your mysql server been up when those stats were taken?

You are correct about the search being the bottleneck, it's the same with most bulletin board software. I've recently written a search modification to disallow certain words that are very common on our board as well as requiring that the search term is at least 5 characters.

joeuser #243868 04/25/2003 4:45 AM
Joined: Nov 2001
Posts: 10,369
I type Like navaho
I type Like navaho
Joined: Nov 2001
Posts: 10,369
Maybe one of you MySQL 4 users can see this post at community. Someone is having trouble. But it must be them.

Ksnnuk - I think Lisa_P once "archived" old posts to a different table to speed things up... I know her board is huge. I think she's on vacation now... but she might have some insight into how that was done.

AleksejVL #243869 04/25/2003 6:25 AM
Joined: Dec 2000
Posts: 1,471
Addict
Addict
Offline
Joined: Dec 2000
Posts: 1,471
That stats are from my developing board that hasn't much traffic so.
Here are some stats from my production board.
Uptime witch cache ~ 3h

select statements total 138.337
Qcache queries in cache 2935
Qcache inserts 137368
Qcache hits 153421


So it has very little effect. It has no effect on the main tables that cause the heavy load (posts, messages, users).
The small tables that have static content like categories, addressbook and smilies can be cached, but that should have much effect, cause this tables are normaly very small.


AleksejVL #243870 04/25/2003 10:43 PM
Joined: Feb 2002
Posts: 295
Member
Member
Offline
Joined: Feb 2002
Posts: 295
Hi,

"You are correct about the search being the bottleneck, "
Hmmm, had not realized that. I think search is used quite a bit on the board.

"I've recently written a search modification to disallow certain words that are very common on our board as well as requiring that the search term is at least 5 characters."
Would you mind sharing the code for this? Might be useful on my board as well.

Sanuk!

Daine #243871 04/25/2003 10:44 PM
Joined: Feb 2002
Posts: 295
Member
Member
Offline
Joined: Feb 2002
Posts: 295
Hi,

"I think Lisa_P once "archived" old posts to a different table to speed things up... I know her board is huge. I think she's on vacation now... but she might have some insight into how that was done."
Thanks. I might PM her.

Sanuk!

Joined: Jun 2003
Posts: 1,025
Junior Member
Junior Member
Offline
Joined: Jun 2003
Posts: 1,025
Hi,
How long has it been since the tables were optimized? I'm sure that you have done this but I just thought I would throw it out there since you didn't mention it.

BrokenToy #243873 04/28/2003 11:56 PM
Joined: Feb 2002
Posts: 295
Member
Member
Offline
Joined: Feb 2002
Posts: 295
Hi,

"How long has it been since the tables were optimized? "
To be honest, I have no idea. My partner handles all of the server stuff.
I'll ask him. Thanks.

Sanuk!

Joined: Feb 2002
Posts: 950
Hacker
Hacker
Offline
Joined: Feb 2002
Posts: 950
I optomized my Users table last night (red line for overhead) and then this morning it was back to the same number in the red line.

Not sure that optomizing has any long term effects based on my little experiment.

gailg #243875 04/29/2003 3:57 PM
Joined: Jun 2003
Posts: 1,025
Junior Member
Junior Member
Offline
Joined: Jun 2003
Posts: 1,025
[]extremebikini said:
I optomized my Users table last night (red line for overhead) and then this morning it was back to the same number in the red line.

Not sure that optomizing has any long term effects based on my little experiment. [/]

Hmm , I would have thought optimizing tables would have had more of an affect on larger boards. Given the time it would take to search tables of that size you would think(or at least I would) that the more effecient the tables=less wasted time=increase in performance.

I guess the proof is in the pudding though.

Joined: Mar 2000
Posts: 21,079
Likes: 3
I type Like navaho
I type Like navaho
Joined: Mar 2000
Posts: 21,079
Likes: 3
Something sounds odd about a forum with 170k posts taking up 1 gb of space... are you allowing some huge file attachments? 100 - 120 mb sounds more like it.


- Allen wavey
- What Drives You?
Joined: Feb 2002
Posts: 295
Member
Member
Offline
Joined: Feb 2002
Posts: 295
Hi,

No attachments at all, but we do get quite a bit of large posts. Could be wrong on the 1Gb as well though. I seem to recall my partner mentioning this number, but could remember incorrectly.

Sanuk!

Joined: Jun 2003
Posts: 1,025
Junior Member
Junior Member
Offline
Joined: Jun 2003
Posts: 1,025
[]ksanuk said:
We are running on a dual Netra 300 MHz with 1Gb of memory (dedicated server) and the board isn't that big (~30-35 users at any given time, ~170K posts).

AllenAyres said:
Something sounds odd about a forum with 170k posts taking up 1 gb of space... are you allowing some huge file attachments? 100 - 120 mb sounds more like it. [/]

The way I read it the 1Gb of memory is referring to the amount of RAM the server has not how much space the board is taking up.

If I'm reading it correct...then how much space is the board taking up? How big are your database tables?

Joined: Feb 2002
Posts: 295
Member
Member
Offline
Joined: Feb 2002
Posts: 295
Hi,

It seems that I was mistaken. The database is 175Mb and not 1Gb as I first thought.

Some other info my partner send me (which means nothing to me ):

Mysql usage:
mysql Ver 11.15 Distrib 3.23.42, for sun-solaris2.8 (sparc)
Connection id: 202168
Current database:
Current user: []root@localhost[/]
Uptime: 7 days 23 hours 21 min 54 sec

Threads: 2 Questions: 2369584 Slow queries: 289 Opens: 83
Flush tables: 1 Open tables: 76 Queries per second avg: 3.440

Sanuk!

Joined: Dec 2000
Posts: 1,471
Addict
Addict
Offline
Joined: Dec 2000
Posts: 1,471
My modifications work with MySQL 4.x only.
I recommend to update your MySQL anywise. The speed improvement is significant.

-Fusion- #243881 05/01/2003 8:57 PM
Joined: Feb 2002
Posts: 295
Member
Member
Offline
Joined: Feb 2002
Posts: 295
Hi,

"I recommend to update your MySQL anywise. The speed improvement is significant."
Yeah, my partner is already testing the new version of MySQL.

Sanuk!


Link Copied to Clipboard
Donate Today!
Donate via PayPal

Donate to UBBDev today to help aid in Operational, Server and Script Maintenance, and Development costs.

Please also see our parent organization VNC Web Services if you're in the need of a new UBB.threads Install or Upgrade, Site/Server Migrations, or Security and Coding Services.
Recommended Hosts
We have personally worked with and recommend the following Web Hosts:
Stable Host
bluehost
InterServer
Visit us on Facebook
Member Spotlight
Nettomo
Nettomo
Germany, Bremen
Posts: 417
Joined: November 2001
Forum Statistics
Forums63
Topics37,575
Posts293,930
Members13,823
Most Online6,139
Sep 21st, 2024
Today's Statistics
Currently Online
Topics Created
Posts Made
Users Online
Birthdays
Top Posters
AllenAyres 21,079
JoshPet 10,369
LK 7,394
Lord Dexter 6,708
Gizmo 5,833
Greg Hard 4,625
Top Posters(30 Days)
Top Likes Received
isaac 82
Gizmo 20
Brett 7
WebGuy 2
Morgan 2
Top Likes Received (30 Days)
None yet
The UBB.Developers Network (UBB.Dev/Threads.Dev) is ©2000-2025 VNC Web Services

 
Powered by UBB.threads™ PHP Forum Software 8.0.1
(Snapshot build 20240918)