News:

Printed Amstrad Addict magazine announced, check it out here!

Main Menu
avatar_Gryzor

PLEASE READ: Regarding forum performance issues

Started by Gryzor, 18:06, 17 June 16

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

1024MAK


So, the time today between pressing the REPLY button and getting the edit box was less than a second. This at 12:48 UK (BST) on a iPad mini via my home wifi connecting via broadband.


Yesterday it was a different story. I hit reply at 13:42. As it stalled, I took a picture (13:43), but this forum won't let me attach it from an iPad mini  :(
Eventually the page with the edit box did load, (at 13:46) but by then I had forgotten what I wanted to write  :laugh: :


The problem with attaching photos appears to be the file extension being .jpeg rather than .jpg but I will have to investigate further to be sure.

Mark





Looking forward to summer in Somerset :-)

Gryzor

To be sure, the mobile interface is more of a hack so I wouldn't be surprised if there were such issues; most people seem happy enough to just use tapatalk for mobile browsing.


As for images being cached etc; the problem is not with loading resources, according to ALL the benchmarkings I've done. The problem is with waiting for a response. The server is fast enough as is the pipeline it's attached to. "Waiting for a response" in our case means waiting for the database to process some queries. Now, the weird part is, those slow queries are different every time, and also they're pretty mundane ones -nothing in them would justify hanging up the db for minutes at a time...

arnoldemu

@Gryzor: Is it possible to clean and/or rebuild the database?
Perhaps some optimisation pass like striping it?
My games. My Games
My website with coding examples: Unofficial Amstrad WWW Resource

1024MAK

#28
Here are the screen shots. I emailed them to myself on a PC, and in the email they have .JPG file extensions, so maybe it is just a problem between the Apple iPad and the forum.

[attach=2]
[attach=3]
Mark
Looking forward to summer in Somerset :-)

Gryzor

@arnoldemu : the database is cleaned as a cron job frequently and all unnecessary data is cleaned. I'm not sure rebuilding it would yield anything - if I'm not mistaken you rebuild your affected tables when something basic has changed, not as a maintenance process? But I may be wrong.


No idea about strip, I should look into it perhaps :)


@1024MAK : what am I looking at here? :)

1024MAK

The main purpose of the screen shots was to show the page I was on and the time (at the top). Nothing more.

Of course, since posting, so far the forum has been behaving itself, at least for me.

Mark

Looking forward to summer in Somerset :-)

Gryzor

Oh, I see. But a troubling aspect of the problem is that the slowdowns are totally random, from the looks of it. I think (not sure if I've enabled it for myself only) that at the bottom of the page you can see how long it takes to generate a page; this page I'm typing on right now, for instance, took 0.042 seconds to generate, with 31 queries on it. Server in under a second. Yet the slowdown could well occur on it at some random point, taking minutes for it to be generated...

Gryzor

By the way, the only real "issue" that benchmarking the site reveals is that the TopSites button takes a while to load. Similar benchmarks say that @Devilmarkus 's server is a bit slow to respond, BUT that's not the culprit as the page loads all the other elements concurrently. And it's not such a big slowdown anyhow, so the problem is not resource loading...

Bryce

The server has just come back to normal after about 5 to 6 minutes of no reaction.

Bryce.

Audronic

Procrastinators Unite,
If it Ain't Broke PLEASE Don't Fix it.
I keep telling you I am Not Pedantic.
As I Live " Down Under " I Take my Gravity Tablets and Wear my Magnetic Boots to Keep me from Falling off.

arnoldemu

#35
Quote from: Gryzor on 10:01, 20 June 16
@arnoldemu : the database is cleaned as a cron job frequently and all unnecessary data is cleaned. I'm not sure rebuilding it would yield anything - if I'm not mistaken you rebuild your affected tables when something basic has changed, not as a maintenance process? But I may be wrong.


No idea about strip, I should look into it perhaps :)
I wondered if rebuilding the database would help, a bit like defragging a hard disk.

The "strip" may be called "striping" or "stripeing".


This is where the files are spread accross multiple drives but you may not have control over that.
My games. My Games
My website with coding examples: Unofficial Amstrad WWW Resource

arnoldemu

btw @Gryzor: consider changing the shoutbox.

It appears to be shockwave flash (swf file) and it has a mp3 as one of the files???

and it causes a reload every second or so when the activity in the shoutbox doesn't need that.


About the delays: What do the server access logs look like? Can you view the traffic in/out at specific times to see why quite a few people have a problem at the same time?
Is there any "load" (as in cpu time) graphs that you can look at?

why do you think it's definitely database times?


My games. My Games
My website with coding examples: Unofficial Amstrad WWW Resource

Bryce

I have a feeling that it's some service or script that runs on the server. It seems to happen at about the same time most days. Maybe not on our exact server, but on some part of the providers system.

Bryce.

arnoldemu

I just got another delay. 13:41 local time.
My games. My Games
My website with coding examples: Unofficial Amstrad WWW Resource

Audronic

and again at 15:3X  15:43
Both the Wiki and the forum

Ray
Procrastinators Unite,
If it Ain't Broke PLEASE Don't Fix it.
I keep telling you I am Not Pedantic.
As I Live " Down Under " I Take my Gravity Tablets and Wear my Magnetic Boots to Keep me from Falling off.

Gryzor

Quote from: arnoldemu on 13:25, 20 June 16
btw @Gryzor: consider changing the shoutbox.

It appears to be shockwave flash (swf file) and it has a mp3 as one of the files???

and it causes a reload every second or so when the activity in the shoutbox doesn't need that.


I'm not a fan of the shoutbox, but people seem to like it. I would take it out, but: yes it's a swf and it's rather heavy, but it doesn't seem to impact things that much. For instance, I just loaded the forum homepage and I got: "Page created in 0.033 seconds with 15 queries.". Served in about one second...

Quote from: arnoldemu on 13:25, 20 June 16
About the delays: What do the server access logs look like? Can you view the traffic in/out at specific times to see why quite a few people have a problem at the same time?
Is there any "load" (as in cpu time) graphs that you can look at?
why do you think it's definitely database times?


Yes, I see all the graphs there are to see, and there's no correlation with traffic etc; the server is more than enough to handle it... It'd the database because I see that SQL is gobbling up CPU cycles and when this happens the query backlog grows quite a bit before being inexplicably released. I've talked about it with the SMF devs and they have no idea why it would do that...



Quote from: arnoldemu on 13:18, 20 June 16
I wondered if rebuilding the database would help, a bit like defragging a hard disk.
The "strip" may be called "striping" or "stripeing".
This is where the files are spread accross multiple drives but you may not have control over that.


We could buy, I think, a second drive, but it wouldn't help things; our database, though large enough, is nowhere near the levels where db splitting is prescribed. Also we would not gain anything in terms of CPU (the opposite probably), just on HDD load which is not an issue.


Quote from: Bryce on 13:26, 20 June 16
I have a feeling that it's some service or script that runs on the server. It seems to happen at about the same time most days. Maybe not on our exact server, but on some part of the providers system.

Bryce.


As far as I've seen the problematic times are rather random, even people from Australia have contacted me during their daytime. Also, a script running on the host's network somewhere would not affect our server which is standalone...


Quote from: Audronic on 13:44, 20 June 16
and again at 15:3X  15:43
Both the Wiki and the forum


Yes, when the db is overloaded the engine stops serving whatever uses a db on the server.

andycadley

What DB engine is it? SQL tuning tends to be very specific to the system being used. I'm mostly an MS SQL person, but happy to help if I can.

seanb

It just took 55 seconds to reload the front page.
The forum was unresponsive in total for about 3 minutes.
I tap reload when I get impatient.
1:16 am this happened.
Thou shall not question Captain Wrong!

arnoldemu

@Gryzor: this is almost related. Do you know if personal messages are causing a problem with the database?

I have 55 pages of personal messages.  :o Sorry.

I will try and delete them all this weekend.
My games. My Games
My website with coding examples: Unofficial Amstrad WWW Resource

Bryce

Quote from: arnoldemu on 11:22, 22 June 16
@Gryzor: this is almost related. Do you know if personal messages are causing a problem with the database?

I have 55 pages of personal messages.  :o Sorry.

I will try and delete them all this weekend.

Only 55? Oops, I have quite a few more.

Bryce.

Bryce

Quote from: Bryce on 12:10, 20 June 16
The server has just come back to normal after about 5 to 6 minutes of no reaction.

Bryce.

Ok, the dropout yesterday was at 13:05. Today it was at 13:00. That's close enough for me to be predictable. Let's see what happens tomorrow between 13:00 and 13:05.

Bryce.

P.s. My inbox now only has 30 pages :)

Edit: Now down to just 2 pages of PMs and I'm pretty sure I'Ve deleted some that I still needed! :D

||C|-|E||

I experimented a problem with the server today as well, but it was much earlier... at 10:33 in UK. It was not responding for a few minutes, then it went back to normal  :)

arnoldemu

#47
@Bryce: Don't forget sent. I had 9 pages in sent.

So now I'm currently down to 0 pages in sent and 45 pages in inbox. I'll delete more later :)
edit: 24 pages now.
My games. My Games
My website with coding examples: Unofficial Amstrad WWW Resource

Bryce

I rarely save sent PMs, I only have about 3 pages of these.

Bryce.

Edit: and the server stopped reacting again from 16:29 until 16:36.

arnoldemu

Quote from: Bryce on 15:26, 22 June 16
I rarely save sent PMs, I only have about 3 pages of these.

Bryce.

Edit: and the server stopped reacting again from 16:29 until 16:36.
I wonder what would happen to the server responsiveness if everyone deleted all their sent PMs and reduced the size of all inbox PMs???
Maybe this is the cause?

I'm down to 14 pages now :)
My games. My Games
My website with coding examples: Unofficial Amstrad WWW Resource

Powered by SMFPacks Menu Editor Mod