Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Computing > NZ Computing > HELP REQ: getting rid of cached webpage

Reply
Thread Tools

HELP REQ: getting rid of cached webpage

 
 
Enkidu
Guest
Posts: n/a
 
      01-04-2010
Donchano wrote:
> On Sun, 03 Jan 2010 17:54:14 +1300, Lawrence D'Oliveiro
> <(E-Mail Removed)_zealand> shouted from the highest rooftop:
>
>> In message <(E-Mail Removed)>, Donchano wrote:
>>
>>> But the problem persists. I've just updated another page (just to test
>>> things out) and all I can load in FF and IE is the page as it looked
>>> before I updated.

>> Does the problem also show with wget? Worth trying that, because it takes
>> browser peculiarities completely out of the equation.
>>
>> And does the question-mark trick work?

>
> Thanks, but I'm afraid I'm not familiar with wget or the question-mark
> trick.
>

wget is on Linux, so if you have Windows you'll not have it, probably.
If you do have Linux use 'wget <URL>' (if you have wget installed) and
see what it says.

I'm not familiar with the question-mark trick either. Could be that you
follow the URL with ? eg 'http://www.cliffp.com?'. I'm not sure what
that gets you though.

Cheers,

Cliff

--

The Internet is interesting in that although the nicknames may change,
the same old personalities show through.
 
Reply With Quote
 
 
 
 
Squiggle
Guest
Posts: n/a
 
      01-04-2010
Enkidu threw some characters down the intarwebs:
> Donchano wrote:
>> On Sun, 03 Jan 2010 17:54:14 +1300, Lawrence D'Oliveiro
>> <(E-Mail Removed)_zealand> shouted from the highest rooftop:
>>
>>> In message <(E-Mail Removed)>, Donchano wrote:
>>>
>>>> But the problem persists. I've just updated another page (just to test
>>>> things out) and all I can load in FF and IE is the page as it looked
>>>> before I updated.
>>> Does the problem also show with wget? Worth trying that, because it
>>> takes browser peculiarities completely out of the equation.
>>>
>>> And does the question-mark trick work?

>>
>> Thanks, but I'm afraid I'm not familiar with wget or the question-mark
>> trick.
> >

> wget is on Linux, so if you have Windows you'll not have it, probably.
> If you do have Linux use 'wget <URL>' (if you have wget installed) and
> see what it says.
>
> I'm not familiar with the question-mark trick either. Could be that
> you follow the URL with ? eg 'http://www.cliffp.com?'. I'm not sure
> what that gets you though.
>
> Cheers,
>
> Cliff
>


Wget is also available for windows, and is a useful thing to have handy.

http://gnuwin32.sourceforge.net/packages/wget.htm
 
Reply With Quote
 
 
 
 
Donchano
Guest
Posts: n/a
 
      01-04-2010

On Mon, 04 Jan 2010 21:01:50 +1300, Enkidu <(E-Mail Removed)>
shouted from the highest rooftop:

>> I remain baffled.
> >

>Me too! Hehe! What Operating System is this? Did you type the 'telnet
><URL> 80' first?


Yes: telnet www.surfwriter.net 80

WinXPpro SP3

>Try HEAD / HTTP/1.1 as well.


I also tried that and got the same error as I did with 1.0.
 
Reply With Quote
 
Squiggle
Guest
Posts: n/a
 
      01-04-2010
Donchano threw some characters down the intarwebs:
> On Mon, 04 Jan 2010 16:56:08 +1300, Nik Coughlin <(E-Mail Removed)>
> shouted from the highest rooftop:
>
>
>> On 4/01/2010 3:39 pm, Enkidu wrote:
>>
>>> Donchano wrote:
>>>
>>>> On Mon, 04 Jan 2010 01:23:54 +1300, Richard <(E-Mail Removed)> shouted
>>>> from the highest rooftop:
>>>>
>>>>
>>>>> Donchano wrote:
>>>>>
>>>>>> On Sun, 03 Jan 2010 14:26:13 +1300, Enkidu <(E-Mail Removed)>
>>>>>> shouted from the highest rooftop:
>>>>>>
>>>>>> In retrrospect I'm inclined to believe that the reason the explanation
>>>>>> worked had little to do with me finding that the cached pages had
>>>>>> finally stopped loading this morning and that the new, updated pages
>>>>>> had taken their place.
>>>>>>
>>>>>> But the problem persists. I've just updated another page (just to test
>>>>>> things out) and all I can load in FF and IE is the page as it looked
>>>>>> before I updated.
>>>>>>
>>>>> You still havent answerd what expiration directives the server is
>>>>> issuing to the ISPs cache along with the page. If it is giving is
>>>>> several days before expiry what you are seeing is the expected
>>>>> behaviour.
>>>>>
>>>> That's because I don't know how. But since I haven't changed anything
>>>> other than a few words of text on each the pages I can think why the
>>>> expiration directives would have suddenly changed. As I said earlier,
>>>> up until Boxing Day, the changes/updates I made and uploaded used to
>>>> visible online within seconds of me publishing them - and have so for
>>>> years.
>>>>
>>>>> Trying to troubleshoot ISP caching issues without looking at what
>>>>> your server is instructing the cache to do is like trying to diagnose
>>>>> a faulty car without seeing it.
>>>>>
>>>> Is there somewhere you can point me to that has a tutorial on this?
>>>> Because I don't know how to figure out why expiration directives the
>>>> server is issuing to Xtra's cache along with the pages.
>>>>
>>>>
>>> If you know how to use a command prompt you may be able to get a bit
>>> more information. See below, pulled from
>>> http://forums.remote-exploit.org/tut...-grabbing.html
>>>
>>>
>>> It shows how to connect to the server from the command line and get info
>>> back. Note that you might not *see* the 'HEAD / HTTP/1.0' bit and you'll
>>> have to type it blind, follow by a couple of 'enters'.
>>>

>> Or use Firefox and you can just use one of the many add-ons for working
>> with HTTP headers.
>>

>
> Would "Live HTTP Headers" be one of those? I've installed it and used
> it to see the Request Headers and Response Headers for a particular
> page, but I haven't a clue what it all means, except that the response
> was OK, the connection is Keep Alive and the age is 34263. I can also
> see that the date of last modification is not correct and displays an
> earlier modification date rather than the latest date (yesterday).
>
>

This may be of some use to you, these are the responses seen from the
server when accessing the links1 page via my Xnet connection. The
response didn't change at all when I tried the --no-cache option.

******
C:\Program Files (x86)\GnuWin32\bin>wget -S
http://www.surfwriter.net/links1.htm

SYSTEM_WGETRC = c:/progra~1/wget/etc/wgetrc
syswgetrc = C:\Program Files (x86)\GnuWin32/etc/wgetrc
--2010-01-04 23:55:52-- http://www.surfwriter.net/links1.htm
Resolving www.surfwriter.net... 72.167.232.158
Connecting to www.surfwriter.net|72.167.232.158|:80... connected.
HTTP request sent, awaiting response...
HTTP/1.1 200 OK
Date: Mon, 04 Jan 2010 10:55:53 GMT
Server: Apache
Last-Modified: Sun, 03 Jan 2010 04:03:23 GMT
ETag: "2260500-13307-4b40170b"
Accept-Ranges: bytes
Content-Length: 78599
Keep-Alive: timeout=15, max=100
Connection: Keep-Alive
Content-Type: text/html
Length: 78599 (77K) [text/html]
Saving to: `links1.htm'

100%[======================================>] 78,599 49.3K/s in 1.6s

2010-01-04 23:55:58 (49.3 KB/s) - `links1.htm' saved [78599/78599]

******
There appear to be no cache-control directives being sent by the server,
and no expiry date been sent. This means it's up to any intermediate
cache to determine its own expiry date as I understand it.

Compare with the response below from a server that is issuing
cache-control directives:
******
HTTP request sent, awaiting response...
HTTP/1.1 200 OK
Date: Mon, 04 Jan 2010 11:35:29 GMT
Server: Apache
X-Powered-By: PHP/5.2.10
Set-Cookie: 758a9608193e02d80ba8f77ebc398920=-; path=/
Expires: Mon, 26 Jul 1997 05:00:00 GMT
Last-Modified: Mon, 04 Jan 2010 11:35:29 GMT
Cache-Control: no-store, no-cache, must-revalidate
Cache-Control: post-check=0, pre-check=0
Pragma: no-cache
Vary: Accept-Encoding
Connection: close
Content-Type: text/html
 
Reply With Quote
 
Richard
Guest
Posts: n/a
 
      01-04-2010
Donchano wrote:
>> You still havent answerd what expiration directives the server is
>> issuing to the ISPs cache along with the page. If it is giving is
>> several days before expiry what you are seeing is the expected behaviour.

>
> That's because I don't know how. But since I haven't changed anything
> other than a few words of text on each the pages I can think why the
> expiration directives would have suddenly changed. As I said earlier,
> up until Boxing Day, the changes/updates I made and uploaded used to
> visible online within seconds of me publishing them - and have so for
> years.


If you dont know what you are requesting caches to do then you are not
able to have any confidence that any of your changes are visible to a
bulk of the internet.

>> Trying to troubleshoot ISP caching issues without looking at what your
>> server is instructing the cache to do is like trying to diagnose a
>> faulty car without seeing it.

>
> Is there somewhere you can point me to that has a tutorial on this?
> Because I don't know how to figure out why expiration directives the
> server is issuing to Xtra's cache along with the pages.


If they are static .html files then it is up to the server config. If it
is a script like php or asp or perl generating it than it can make the
headers what it feels like.

Your best bet is to ask your server administrator what they have it
sending. If its apache which most cheap hosting is running on you may
have some control over it in the .htaccess file, but its something that
cheap hosts set to a long time in the future intentionally so that their
bandwidth costs in serving a site which doesnt pay a lot is reduced.
 
Reply With Quote
 
Richard
Guest
Posts: n/a
 
      01-04-2010
Enkidu wrote:
> I'm not familiar with the question-mark trick either. Could be that you
> follow the URL with ? eg 'http://www.cliffp.com?'. I'm not sure what
> that gets you though.


Yeah almost - http://whatever.com/?

Most proxys see the ? and assume its a form so will not serve cached
content since so many clueless web developers use gets for actions so a
cached responce isnt suitable.

Also, if you are using cookies it will often detect that and request
everything even if not expired.

Its just static stuff that normally gets cached and I suspect the cache
is operating properly inline with the servers instructions and its just
a cheap web host with a massively long time to the expires to make it
cheaper to run.
 
Reply With Quote
 
Donchano
Guest
Posts: n/a
 
      01-12-2010

On Sat, 02 Jan 2010 17:32:08 +1300, Donchano
<(E-Mail Removed)> shouted from the highest rooftop:

>
>It started on Christmas Eve day.


Thank you everyone for your suggestions and help. After spending
literally hours on the phone with my ISP's technical support we have
finally figured out what the problem is. Unfortunately, they haven't
figured out a solution as yet.

The problem is a very localised cache problem with a very narrow band
of IP addresses which includes mine and a few neighbours. For some
reason nobody can explain, the server cache for these addresses takes
48 or more hours to be cleared.

While the Xtra's technical support (somewhere in the Philippines)
searches for a solution, I've experimented by adding the following
code to one of my webpages' header and it works for me.

<meta http-equiv="Cache-Control" content="no-cache">

As I understand it, the code forces Xtra's server (even the problem
server) to check the originating server for a new copy of the page.

I'm hoping I don't have to add this meta-tag to each and every one of
my webpages, but if Xtra can't come up with a fix at their server end
of things, then at least there's an alternative to me having to wait
48+ hours to check any changes to my website online.

Again ... thanks for all of your suggestions and help. It has been a
very interesting and valuable learning curve. Cheers, b
 
Reply With Quote
 
Richard
Guest
Posts: n/a
 
      01-12-2010
Donchano wrote:
> On Sat, 02 Jan 2010 17:32:08 +1300, Donchano
> <(E-Mail Removed)> shouted from the highest rooftop:
>
>> It started on Christmas Eve day.

>
> Thank you everyone for your suggestions and help. After spending
> literally hours on the phone with my ISP's technical support we have
> finally figured out what the problem is. Unfortunately, they haven't
> figured out a solution as yet.
>
> The problem is a very localised cache problem with a very narrow band
> of IP addresses which includes mine and a few neighbours. For some
> reason nobody can explain, the server cache for these addresses takes
> 48 or more hours to be cleared.
>
> While the Xtra's technical support (somewhere in the Philippines)
> searches for a solution, I've experimented by adding the following
> code to one of my webpages' header and it works for me.
>
> <meta http-equiv="Cache-Control" content="no-cache">


So long as the caches obey it, not all do as its not a header. Also cant
do it that way with images.

Get the server making the header as the spec says, not using a kludgy
http-equiv workaround.

> As I understand it, the code forces Xtra's server (even the problem
> server) to check the originating server for a new copy of the page.


There is no problem with the server, it is obeying your instructions of
"dont care" with respect to caching, by using its own defaults.

> I'm hoping I don't have to add this meta-tag to each and every one of
> my webpages, but if Xtra can't come up with a fix at their server end
> of things, then at least there's an alternative to me having to wait
> 48+ hours to check any changes to my website online.


You should be able to control this via a .htaccess file on the server
which has the default expiration directives in it.

> Again ... thanks for all of your suggestions and help. It has been a
> very interesting and valuable learning curve. Cheers, b

 
Reply With Quote
 
Donchano
Guest
Posts: n/a
 
      01-12-2010

On Tue, 12 Jan 2010 16:31:06 +1300, Richard <(E-Mail Removed)> shouted
from the highest rooftop:

>You should be able to control this via a .htaccess file on the server
>which has the default expiration directives in it.


I've found the file on the remote server and downloaded a copy onto my
PC. But how do I open/edit it? And what should I change the expiration
directives to? TIA

 
Reply With Quote
 
Squiggle
Guest
Posts: n/a
 
      01-12-2010
Donchano threw some characters down the intarwebs:
> On Tue, 12 Jan 2010 16:31:06 +1300, Richard <(E-Mail Removed)> shouted
> from the highest rooftop:
>
>
>> You should be able to control this via a .htaccess file on the server
>> which has the default expiration directives in it.
>>

>
> I've found the file on the remote server and downloaded a copy onto my
> PC. But how do I open/edit it? And what should I change the expiration
> directives to? TIA
>
>

Its a plain text file, so any text editor should be fine

Good place to start might be:
http://httpd.apache.org/docs/
 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
cause webpage one to reload when webpage two is closed. Paul ASP .Net 14 06-19-2008 03:02 PM
check if a webpage is forwarding to a other webpage martijn@gamecreators.nl Python 1 09-06-2005 02:27 PM
Email contents of webpage or Form on webpage w/o using Server scripting sifar Javascript 5 08-24-2005 05:47 PM
my cached dataset just wont stay cached!! Craig G ASP .Net 0 03-07-2005 10:02 AM
Are my pages getting cached or something? Help very much appreciated! Simon ASP .Net 2 07-17-2004 09:17 PM



Advertisments