crowell / modpagespeed_tmp

Automatically exported from code.google.com/p/modpagespeed
Apache License 2.0
0 stars 0 forks source link

Problem with ModPagespeedLoadFromFileMatch #616

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
I am still getting a few errors thrown up in the logs along the lines of:

[Sat Feb 02 00:23:07 2013] [warn] [mod_pagespeed 1.2.24.1-2300 @30521] Fetch 
timed out: http://127.0.0.1/uploaded/img/1693_100_0569-qpr_100px.jpg (30) 
waiting for 50 ms

I am however, using:
    ModPagespeedLoadFromFileMatch "^https?://127.0.0.1/.*uploaded/img/" "/var/www/html/uploaded/img/"

in the pagespeed.conf file.

I am puzzled as to why this is not being matched and accessing the file 
directly.

Original issue reported on code.google.com by rwap.services on 2 Feb 2013 at 9:29

GoogleCodeExporter commented 9 years ago
ModPagespeedLoadFromFileMatch is trying to match against the "rewritten" 
domain, computed from:
   The domain of the HTML file
   The domain of the URL in the <img> reference
   Any ModPagespeedMapRewriteDomain directives

If that fails, then mod_pagespeed attempts to fetch the file via HTTP, and only 
at that point does it map to 127.0.0.1 for loopback fetches.

Hope this helps!
-Josh

Original comment by jmara...@google.com on 2 Feb 2013 at 2:13

GoogleCodeExporter commented 9 years ago
Not much help - the actual URL of the image is:

http://www.sellmyretro.com/uploaded/img/1693_100_0569-qpr_100px.jpg

Ie, with the domain name this is present, so I don't know why ModPagespeed is 
trying to access it using http://127.0.0.1/ and then failing - it should be 
using the directive:
ModPagespeedLoadFromFileMatch 
"^https?://(?:www.)?sellmyretro\.com/.*uploaded/img/" 
"/var/www/html/uploaded/img/"

and loading it from file anyway...

Original comment by rwap.services on 4 Feb 2013 at 9:18

GoogleCodeExporter commented 9 years ago

Original comment by sligocki@google.com on 29 Oct 2014 at 7:47