Welcome to the Cumulus Support forum.

Latest Cumulus MX V3 release 3.28.6 (build 3283) - 21 March 2024

Cumulus MX V4 beta test release 4.0.0 (build 4019) - 03 April 2024

Legacy Cumulus 1 release 1.9.4 (build 1099) - 28 November 2014
(a patch is available for 1.9.4 build 1099 that extends the date range of drop-down menus to 2030)

Download the Software (Cumulus MX / Cumulus 1 and other related items) from the Wiki

Page Refresh.

Discussion specific to Fine Offset and similar rebadged weather stations
Post Reply
Jeff Cook
Posts: 24
Joined: Wed 02 Mar 2011 3:49 pm
Weather Station: WH1080
Operating System: Windows 10 pro 64-bit
Location: Burscough

Page Refresh.

Post by Jeff Cook »

Dear all,

After having switched web hosts and gotten over the initial problems, I've noticed something which I haven't noticed in the past, namely that whilst the initial page (Now) and the second page (Gauges) update with every five minute ftp refresh, the rest of the pages namely Today through to Trends remain stubbornly stuck on whatever the browser cache throws up, unless I press F5 at which point it updates to the latest ftp upload. I'm using Google but I'm noticing the same effect on Internet Explorer. What have I missed please?

Jeff Cook.
User avatar
steve
Cumulus Author
Posts: 26701
Joined: Mon 02 Jun 2008 6:49 pm
Weather Station: None
Operating System: None
Location: Vienne, France
Contact:

Re: Page Refresh.

Post by steve »

Your web server is sending an expiry time of 7 days in the HTTP headers, so browsers won't try to fetch a new version of the page for that length of time. You can try to defeat this by adding the following to the <head>...</head> section of your web pages (edit the 'T' files in the Cumulus web folder):

<meta http-equiv="Cache-Control" content="no-cache, no-store, must-revalidate" />
<meta http-equiv="Pragma" content="no-cache" />
<meta http-equiv="Expires" content="0" />

But I'm not sure whether that is guaranteed to work. Might be better to talk to your web space provider to see if they can do anything.
Steve
User avatar
mcrossley
Posts: 12756
Joined: Thu 07 Jan 2010 9:44 pm
Weather Station: Davis VP2/WLL
Operating System: Bullseye Lite rPi
Location: Wilmslow, Cheshire, UK
Contact:

Re: Page Refresh.

Post by mcrossley »

Or try creating a .htaccess file in your web server folder with contents something like...

Code: Select all

ExpiresActive On
ExpiresDefault "access plus 1 hour"
Most web servers have the mod_expires module loaded to enable this.
User avatar
mcrossley
Posts: 12756
Joined: Thu 07 Jan 2010 9:44 pm
Weather Station: Davis VP2/WLL
Operating System: Bullseye Lite rPi
Location: Wilmslow, Cheshire, UK
Contact:

Re: Page Refresh.

Post by mcrossley »

of course you can specify whatever time you want - 10 minutes?

You may also need to create a similar file in your images folder to prevent them being cached too.
Jeff Cook
Posts: 24
Joined: Wed 02 Mar 2011 3:49 pm
Weather Station: WH1080
Operating System: Windows 10 pro 64-bit
Location: Burscough

Re: Page Refresh.

Post by Jeff Cook »

Dear Steve and Mark,

Thank you for your guidance, I will follow this through this afternoon and report back on how it goes.

The speed of return on this forum is remarkable, I don't know of one with a turnaround time faster than this, also the advice is effective.

Jeff Cook.

I've done as you said Steve, but as you suspected it hasn't worked. Mark I will take up your suggestion next but I'm out now for a couple of hours, shopping, arggg. Then if still no joy I will go back to my web host.

Thank you.

Jeff Cook.
Jeff Cook
Posts: 24
Joined: Wed 02 Mar 2011 3:49 pm
Weather Station: WH1080
Operating System: Windows 10 pro 64-bit
Location: Burscough

Re: Page Refresh.

Post by Jeff Cook »

Steve, I've been in touch with RS Hosting and after a couple of attempts at explaining the problem, or more accurately what I wanted, and of your advice to me, they have asked the following question:

I believe this is something to do with Apache configuration on the server. Can you please consult your developer who advised about 7 day interval in headers, as which configuration setting is he referring to in Apache? That way, we can then investigate at server end.

I will completely understand if you don't want to get involved any further as I realise that sorting problems that are not directly Cumulus is not part of your remit.

Mark, I've tried your suggestion as best I can (I would need the idiots guide to be completely sure as to what I've done) but it hasn't made any difference, but thank you for taking the time to make the suggestion.

Jeff Cook.
User avatar
steve
Cumulus Author
Posts: 26701
Joined: Mon 02 Jun 2008 6:49 pm
Weather Station: None
Operating System: None
Location: Vienne, France
Contact:

Re: Page Refresh.

Post by steve »

Sorry, I don't know, I'd have to look it up in the Apache documentation. It's a bit odd that a web space provider is having to ask someone else how to configure their web servers for them :lol:

What I can tell you is that it's the "Cache-Control: max-age=..." HTTP header, but I don't know the correct way to change that in Apache.
Steve
Jeff Cook
Posts: 24
Joined: Wed 02 Mar 2011 3:49 pm
Weather Station: WH1080
Operating System: Windows 10 pro 64-bit
Location: Burscough

Re: Page Refresh.

Post by Jeff Cook »

Yes, it struck me as a little strange that a technical support group would in effect be asking me or you how to configure their Apache server. Perhaps it will get moved up the chain, but seeing that the web hosting is costing only £14.99 for a year, I think there is a limit to what I may expect.

Jeff Cook.
Jeff Cook
Posts: 24
Joined: Wed 02 Mar 2011 3:49 pm
Weather Station: WH1080
Operating System: Windows 10 pro 64-bit
Location: Burscough

Re: Page Refresh.

Post by Jeff Cook »

Well, after a little to-ing and fro-ing things are running normally, this is what the web host did in order to get the required configuration:

We have checked your issue and applied the required changes for the website file. As it appears to be a cache issue for nginx on server, we have disabled the cache for your domain name now. Please clear the cache and cookies of the browser and check the website now.

Thanks for your guidance, it certainly helps knowing what to ask for.

Jeff Cook.
mike351
Posts: 4
Joined: Sat 30 Apr 2011 2:06 pm
Weather Station: Fine Offset WH-1091
Operating System: Win7
Location: Narre Warren, Australia
Contact:

Re: Page Refresh.

Post by mike351 »

steve wrote:Sorry, I don't know, I'd have to look it up in the Apache documentation. It's a bit odd that a web space provider is having to ask someone else how to configure their web servers for them :lol:

What I can tell you is that it's the "Cache-Control: max-age=..." HTTP header, but I don't know the correct way to change that in Apache.
Hi Steve,

I'm having the exact same issue, I know my data is being regularly uploaded (10m intervals), the FTP log shows that all uploads are successful.

I tried looking at the source of my page, and couldn't find the Cache-Control header? Am I missing something?

My website is http://www.mikesweatherstation.com

Mike

ps. I have updated it in my signature, but preview is showing the old one.
http://www.mikesweatherstation.com
My Fine Offset WH-1091 updated every 10 minutes
Narre Warren, Victoria, Australia.
water01
Posts: 3246
Joined: Sat 13 Aug 2011 9:33 am
Weather Station: Ecowitt HP2551
Operating System: Windows 10 64bit
Location: Burnham-on-Sea
Contact:

Re: Page Refresh.

Post by water01 »

Version 1.9.1 !! I would think the first thing to try is updating 1.9.4!!
David
Image
User avatar
steve
Cumulus Author
Posts: 26701
Joined: Mon 02 Jun 2008 6:49 pm
Weather Station: None
Operating System: None
Location: Vienne, France
Contact:

Re: Page Refresh.

Post by steve »

mike351 wrote:I tried looking at the source of my page, and couldn't find the Cache-Control header? Am I missing something?
It's an HTTP header which is sent by the server. The value which is sent depends on how the server is configured. Your server is sending a header with a value of 86400, i.e. 24 hours. If you want to view the headers being sent by the server, you can usually do it using the 'developer tools' in your browser. Exactly how you do it is browser-dependent.

If you want to put those three lines in your pages that I quoted earlier, then you have to ADD them. But as I said, it's not guaranteed to work, and you would be better trying one of the other solutions mentioned in this thread (i.e. the .htaccess file or speak to your provider)
Steve
mike351
Posts: 4
Joined: Sat 30 Apr 2011 2:06 pm
Weather Station: Fine Offset WH-1091
Operating System: Win7
Location: Narre Warren, Australia
Contact:

Re: Page Refresh.

Post by mike351 »

water01 wrote:Version 1.9.1 !! I would think the first thing to try is updating 1.9.4!!
This is what I mean. I had updated the software, yet the old pages seem to be cached :(

Mike
http://www.mikesweatherstation.com
My Fine Offset WH-1091 updated every 10 minutes
Narre Warren, Victoria, Australia.
Post Reply