News:

Want to get involved in developing SMF, then why not lend a hand on our github!

Main Menu

Issue with cached pages/refreshing pages

Started by MadCityKaren, August 06, 2018, 07:19:54 PM

Previous topic - Next topic

MadCityKaren

I'm not sure how to best describe what's going on with my forum: I'd noticed when clicking around on my forum that occasionally I'll find the timestamp in the upper left corner "travels" back in time (presuming it pulls up a last cached copy) which typically resolves on clicking the link again (e.g. "show unread posts since last visit", etc).  This is also problematic when making a post in that it doesn't appear initially that it has been made, but more likely that it's just a 'cached' copy was pulled up until refreshed again.  (One of my forum members just spoke up and thought it was her device that is the problem, but I've noted it on tablet, phone, and laptop/desktop.)

I'm a little stymied as to the best way to deal with this ... before I start messing with a mostly working well forum, I thought I would ask the experts here.  I'm thinking running some of the tasks in Forum Maintenance > Routine may be the answer.  Thoughts/advice?

Version 2.0.15

Looking

Does your host use a cache system for displaying pages? I have seen this behavior with Nginx.

MadCityKaren

In speaking with the webhost, it appears to be "CacheWall" -- I've disabled it (as instructed by webhost), but still having the same issue.

(The webhost also asked me to clear my browser cache, which wouldn't affect my forum members experiencing the same issue ... or would it?)

Looking

Does not hurt to tell everyone to clear their cache but I would only do so if it is working for you now.

Sir Osis of Liver

Do you have forum cache enabled in Admin -> Server Settings -> Caching?  Unless you have a very busy forum, you can disable caching, clear cache in Admin -> Forum Maintenance.

Ashes and diamonds, foe and friend,
 we were all equal in the end.

                                     - R. Waters

MadCityKaren

Quote from: Sir Osis of Liver on August 06, 2018, 09:59:10 PM
Do you have forum cache enabled in Admin -> Server Settings -> Caching
It's set at "Level 1 Caching (Recommended)" currently.   

SMF recognizes APC installed as the accelerator. 
(Memcache settings shows nothing in the box ... should there be something there?)


Quote from: Sir Osis of Liver on August 06, 2018, 09:59:10 PMUnless you have a very busy forum, you can disable caching, clear cache in Admin -> Forum Maintenance.
I may try that ... although am trying to figure out what has changed that this has become an issue. 

Sir Osis of Liver

Memcache settings would only apply if you're using memcached accelerator.  Your host must have changed something that affects server caching.  I would disable caching, empty forum /cache, clear your browser, see if problem persists.
Ashes and diamonds, foe and friend,
 we were all equal in the end.

                                     - R. Waters

Arantor

And yet none of those caching things would affect the displayed time going backwards...

GigaWatt

It's not going backwards, it "travels back in time", like in a previous state.
"This is really a generic concept about human thinking - when faced with large tasks we're naturally inclined to try to break them down into a bunch of smaller tasks that together make up the whole."

"A 500 error loosely translates to the webserver saying, "WTF?"..."

Arantor

Yes, which SMF has no control over and nothing cached by SMF would affect that.

It's a cache that caches the entire page that sits further along the chain than SMF is, therefore clearing none of SMF's caches would affect it.

drewactual

go to:  admin>configuration>server>sessions and cookie

de-select : "Allow browsers to go back to cached pages"

this will use marginally more bandwidth, but the pages output will be updated on every re-load instead of simply showing 'them' what they've already seen.

after reading your first post, this is what seems to me is happening... yeah, there are cache settings and such and playing with them may replicate the same issue, but i wager your issue is this simple... insofar as users seeing cached pages, you only have so much control over that if they're stored on the users computers (such as FF and IE do) or if they're stored in part in a DB residing on a google owned cloud (such as Chrome).  Adding to this difficulty, there are literally hundreds of servers in between you and your users that also cache so they appear to operate quicker- and you have zero control over that...

an aside: SirOsis- the memcache and the memcached are different- memcache used for sessions storage uses the port 11211, and memcached used as sessions handler does the same thing... the sessions handler isn't an accelerator, it's just a better means of managing sessions (not requiring i/o to store sessions)- the memcached accelerator uses the igbinary, the json, and the msgpack support to work as an accelerator.... memcache handles data completely differently than memcached (which is the memcache daemon) .... same package and directory, but two distinct purposes.  APCe and OPCache store script outputs as their means of accelerating and aren't server stored file caches at all... all this crap is tricky............ and can dang sure confound and confuse.


Arantor

Honestly I'd still be blaming CacheWall for this as I haven't seen a legitimate case in years where the setting mentioned would actually cause this. Browsers 15 years ago had trouble with this... not recent ones.

Gwenwyfar

I've seen something similar happen with SMF load balancing enabled (which I have no idea how even got enabled on my test install, if it isn't by default), where occasionally some actions would go back to a previous state when loading the page, settings taking time to do anything, etc.
"It is impossible to communicate with one that does not wish to communicate"

MadCityKaren

#13
Quote from: Arantor on August 07, 2018, 02:58:39 AM
And yet none of those caching things would affect the displayed time going backwards...
This is an example of what I've been seeing:
I'm logged in right now to the main page of the forum -- the timestamp is 9:43:11PM
I click onto a link ("show unread posts since last visit") -- the timestamp on that page is 9:44:14PM
I click back onto home (main page) -- the timestamp reads 9:43:11PM; clicking on home AGAIN updates to 9:44:53

(This was done in real time over the course of about a minute; when on a page for a longer period of time, the delay is much longer and will appear to be 10-15 minutes in the past.)

This happens to other members of my forum too; not isolated to my computer ...

MadCityKaren

Quote from: drewactual on August 07, 2018, 02:27:44 PM
go to:  admin>configuration>server>sessions and cookie

de-select : "Allow browsers to go back to cached pages"

this will use marginally more bandwidth, but the pages output will be updated on every re-load instead of simply showing 'them' what they've already seen.
Thanks.  I've tried this ... doesn't seem to address the issue.   :(

I have another message in with the webhost.  They'd run some Google developer tools which showed the X-cache as "MISS" which they'd explained as meaning there is no server side cache showing.  (I'm not entirely certain what that means and am requesting further confirmation from them.)

drewactual

honestly, there is so much caching taking place out there it's ridiculous..... some ISP's literally use your own modem/router to do the deed with their firmware; almost all of them cache at a server level to seemingly improve their response to request times... then there are servers in between that do the same thing... it's almost bordering nefarious when it is all for their own gain and at the expense of web developers, and to the point that 'cache busting' is a thing that is a niche industry... but enough of that. 

do you have a phpinfo file you can share?  If not, google for phpinfo single line code in a php file you create on the root directory of your webpage- and post either a link to it here or a screenshot... if YOU'RE (or your host) is caching, it'll demonstrate it there with out exception.  if it doesn't, it likely isn't you or your host doing this.......... and what i'd tell you is to connect to a different device (such as use your mobile phone's hotspot) to connect... and see if it happens on it. 

MadCityKaren

#16
Webhost confirms "All of your server side cache software is disabled."

Quote from: Sir Osis of Liver on August 06, 2018, 09:59:10 PM
Do you have forum cache enabled in Admin -> Server Settings -> Caching?  Unless you have a very busy forum, you can disable caching, clear cache in Admin -> Forum Maintenance.
Have caching level as 'no caching' and cleared the cache in Maintenance.  No difference noted.  :(


Quote from: drewactual on August 07, 2018, 11:29:01 PM
do you have a phpinfo file you can share?  If not, google for phpinfo single line code in a php file you create on the root directory of your webpage- and post either a link to it here or a screenshot... if YOU'RE (or your host) is caching, it'll demonstrate it there with out exception.  if it doesn't, it likely isn't you or your host doing this..........
{LINK REMOVED}

Honestly, I'm not sure what to even look at here ...  :o

(Not sure whether it's helpful to know or not: updated to https from http back in mid-May.  I don't recall this being an issue at that time.)


Quote from: drewactual on August 07, 2018, 11:29:01 PMand what i'd tell you is to connect to a different device (such as use your mobile phone's hotspot) to connect... and see if it happens on it. 
I tried with my tablet away from home earlier today and noticed the same issue with cached pages (by timestamp).


~ Removed link, per request ~

Sir Osis of Liver

I've registered on your forum, please activate my account.
Ashes and diamonds, foe and friend,
 we were all equal in the end.

                                     - R. Waters

MadCityKaren


Sir Osis of Liver

Can you make me admin?  Would like to see error log and package manager.
Ashes and diamonds, foe and friend,
 we were all equal in the end.

                                     - R. Waters

Advertisement: