Caching doesn't work at all


Installed RoR under lighttpd and noticed that caching some actions
didn’t accelerate page serving. The following little example of

class TestscriptController < ApplicationController
caches_page :index

def index
	@string =





<%= controller.action_name %>

<%= @string %>

does work in development mode with caching turned on under WinXP with
Webrick. It does not work in lighttpd with fastcgi on FedoraCore. I
already browsed through the various log but no obvious errors were to be

And Rails / Ruby is able to write into the public directory (as another
script of mine puts to good effect).

So, does anyone know where the problem might lie?


Are you manually setting caching to on under development mode?

On 5/17/06, Johannes H. removed_email_address@domain.invalid wrote:

So, does anyone know where the problem might lie?

Posted via

Rails mailing list


Well, Webrick runs in development mode with caching manually turned on
and works fine.

Lighttpd runs in production mode with the default parameters from
/environment/production.rb and does not work.

I just tried some shenannigans with the config files and suddenly the
above example will create the testscript.html in /public. However, for
some weird reason, the testscript.html is always updated which somewhat
defeats the purpose of caching.

And production.log only tells me:

Processing TestscriptController#index (for 124.576.63.1 at 2006-05-17
21:31:01) [GET]
Session ID:
Parameters: {“action”=>“index”, “controller”=>“testscript”}
Rendering testscript/index
Completed in 0.00559 (178 reqs/sec) | Rendering: 0.00107 (19%) | DB:
0.00000 (0%) | 200 OK