cache control

i have added following lines in httpd.conf

<FilesMatch "^t\.cgi$">
ExpiresActive on
ExpiresDefault A1
Header unset Cache-Control
Header set Cache-Control: "no-store, no-cache, must-revalidate"
Header unset Expires
Header set Expires "Thu, 01 Dec 1994 16:00:00 GMT"
</FilesMatch>


then i did   sudo /l/apache/bin/apachectl configtest    sudo /l/apache/bin/apachectl graceful

when i open the url   http://xyz.com/cgi-bin/t.cgi (i m printing headers in t.cgi)
i get the following output:

200 OK Date: Wed, 20 Apr 2005 16:08:13 GMT
Server: Web Server/1.3.28 (Unix) mod_ssl/2.8.15 OpenSSL/0.9.7c mod_gzip/1.3.26.1a mod_security/1.6 mod_jk/1.2.5 ApacheJServ/1.1.2
Cache-Control:
Expires:
Last-Modified: Sat, 16 Apr 2005 08:09:03 GMT
Etag: "f05478-98-4260c81f"
Content-Length: 152
Content-Type: text/html

why the Expires field is empty??????  it means it is still caching data
LVL 1
shahrahulbAsked:
Who is Participating?
 
ramazanyichCommented:
also typo for Header set Cache-Control  - remove ":" sign
0
 
shahrahulbAuthor Commented:
i have already tried this in httpd.conf file:

ExpiresActive on
<FilesMatch "^t\.cgi$">
ExpiresDefault A1
Header unset Cache-Control
Header set Cache-Control: "no-store, no-cache, must-revalidate"
Header unset Expires
Header set Expires "Thu, 01 Dec 1994 16:00:00 GMT"
</FilesMatch>

i also tried this:
ExpiresActive on
<Files "t\.cgi">
ExpiresDefault A1
Header unset Cache-Control
Header set Cache-Control: "no-store, no-cache, must-revalidate"
Header unset Expires
Header set Expires "Thu, 01 Dec 1994 16:00:00 GMT"
</Files>
0
 
ramazanyichCommented:
try to remove Header unset lines.

0
 
shahrahulbAuthor Commented:
tried both  still not working
0
 
shahrahulbAuthor Commented:
not sure if mod_expire is really enabled

when i do
sudo /l/apache/bin/httpd -l

i get

Compiled-in modules:
  http_core.c
  mod_so.c
suexec: disabled; invalid wrapper /l/apache-1.3.28-20031223/bin/suexec


i cannot see mod_expires.c

is this the way ot see????

however i can see Addmodule mod_expires.c in httpd.cof   also it is uncommented
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.