[users@httpd] httpd-2.2.0 CacheDefaultExpire not honored?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Trying to prove a caching-proxy configuration.  With the server configured
as below cache headers are marked with the CacheMaxExpire value, not the
CacheDefaultExpire.  I'm making requests for static content (a jpg file)
on the caching-proxy server.  Meaning there is only my browser and the
server under test involved.

I don't think there is any other setting that would get in the way.  I've
been looking for the logic in the code, but set_cache_maxex and
set_cache_defex don't appear to be the right variable names to look for.

Thanks in advance.  Any help appreciated.

# Cache Configuration
#
<IfModule mod_cache.c>
  <IfModule mod_disk_cache.c>
    CacheNegotiatedDocs On
    CacheDefaultExpire 60
    CacheMaxExpire 120
    CacheRoot /usr/local/apache2/cache
    CacheEnable disk /
    CacheDirLevels 10
    CacheDirLength 1
  </IfModule>
</IfModule>

I've been working with httpd 2.1.6-alpha through 2.2.0.  I think I saw
this behavior with 2.1.9-beta but wasn't focused on it and couldn't be
sure at the time.  Entirely possible I've done something to confuse the
issue.

Reading the 48 byte binary structure and text in the header file shows the
following (system names and URL edited) info after a request made after
the original cache entry had expired;

Binary data:

Format: 4
Status: 200
Offset: 64
Version: 0
Date: Thu, 08 Dec 2005 10:32:30 PST
Expire: Thu, 08 Dec 2005 10:34:30 PST
Request: Thu, 08 Dec 2005 10:32:30 PST
Response: Thu, 08 Dec 2005 10:32:31 PST

Text:

URL: http://httpd-2.2.0:80/US/EN/brman/graphics/a.jpg
Date: Thu, 08 Dec 2005 18:32:30 GMT
Server: Apache/2.2.0 (Unix)
ETag: "34e-2936e700"
Accept-Ranges: bytes
Content-Length: 846
Expires: Thu, 08 Dec 2005 18:34:30 GMT
Via: 1.1 httpd-2.2.0
Last-Modified: Fri, 05 Nov 1999 16:11:40 GMT
Content-Type: image/jpeg

Accept: image/gif, image/x-xbitmap, image/jpeg, image/pjpeg,
application/vnd.ms-excel, application/vnd.ms-powerpoint,
application/msword, application/x-shockwave-flash, */*
Accept-Language: en-us
Accept-Encoding: gzip, deflate
User-Agent: Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; SV1; .NET
CLR 1.0.3705)
Host: httpd-2.2.0
If-None-Match: "34e-2936e700"
If-Modified-Since: Fri, 05 Nov 1999 16:11:40 GMT
Max-Forwards: 10
Via: 1.1 httpd-2.2.0


Operating System: UnixWare 7.1.3

#httpd.conf

ServerRoot "/usr/local/apache2"

PidFile /tmp/httpd.pid

Listen 80

<IfModule !mpm_winnt_module>
<IfModule !mpm_netware_module>
User nobody
Group nobody
</IfModule>
</IfModule>

DocumentRoot "/home/htdocs"

<Directory />
    Options FollowSymLinks
    AllowOverride None
    Order deny,allow
    Deny from all
</Directory>

<Directory "/home/htdocs">
    Options MultiViews IncludesNOEXEC
    AllowOverride None
    Order allow,deny
    Allow from all
    <IfModule mod_deflate.c>
      SetOutputFilter DEFLATE
      SetEnvIfNoCase Request_URI \.(?:gif|jpe?g|png|pdf)$ no-gzip dont-vary
    </IfModule>

</Directory>

<IfModule dir_module>
    DirectoryIndex index.htm index.html
</IfModule>

<FilesMatch "^\.ht">
    Order allow,deny
    Deny from all
</FilesMatch>

AccessFileName .htaccess

ErrorLog logs/error_log
LogLevel debug

<IfModule log_config_module>
    LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\"
\"%{User-Agent}i\"" combined
    LogFormat "%h %l %u %t \"%r\" %>s %b" common

    <IfModule logio_module>
      LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\"
\"%{User-Agent}i\" %I %O" combinedio
    </IfModule>

    CustomLog logs/access_log common

</IfModule>

<IfModule alias_module>
    ScriptAlias /cgi-bin/       "/home/htdocs/cgi-bin/"
</IfModule>

DefaultType text/plain

<IfModule mime_module>
    TypesConfig conf/mime.types
    AddEncoding x-gzip .gz
    AddType application/x-compress .Z
</IfModule>

EnableMMAP On
KeepAlive On
FileETag MTime Size
UseCanonicalName On

<IfModule mod_cache.c>
  <IfModule mod_disk_cache.c>
    CacheNegotiatedDocs On
    CacheDefaultExpire 60
    CacheMaxExpire 120
    CacheRoot /usr/local/apache2/cache
    CacheEnable disk /
    CacheDirLevels 10
    CacheDirLength 1
  </IfModule>
</IfModule>

<IfModule mod_proxy.c>
  ProxyRequests On
  ProxyVia On
  AllowCONNECT 443 563 9485
  NoProxy 161.161.0.0/16 10.0.0.0/8
  NoProxy .citigroup.net. .ssmb.com.
  NoProxy .nsroot.net. .citifinancial.citigroup.net.
  ProxyDomain .citifinancial.citigroup.net
  ProxyRemote * http://webproxy.ssmb.com:8080
</IfModule>





---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@xxxxxxxxxxxxxxxx
   "   from the digest: users-digest-unsubscribe@xxxxxxxxxxxxxxxx
For additional commands, e-mail: users-help@xxxxxxxxxxxxxxxx



[Index of Archives]     [Open SSH Users]     [Linux ACPI]     [Linux Kernel]     [Linux Laptop]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Squid]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]

  Powered by Linux