Project

General

Profile

Actions

Bug #487

closed

Lighty 1.4.9 no likey relative bin-paths

Added by Anonymous over 16 years ago. Updated over 14 years ago.

Status:
Fixed
Priority:
Normal
Category:
mod_fastcgi
Target version:
-
ASK QUESTIONS IN Forums:

Description

I'm running FreeBSD and recently upgraded to lighttpd 1.4.9. When I did, most of my apps stopped working. I eventually discovered that the problem has to do with the relative bin-paths given for mod_fastcgi. Even in a fresh rails installation, trying to execute ./script/server will end in:


=> Booting lighttpd (use 'script/server webrick' to force WEBrick)
=> Rails application started on http://0.0.0.0:3000
=> Call with -d to detach (requires absolute paths in config/lighttpd.conf)
=> Ctrl-C to shutdown server (see config/lighttpd.conf for options)
2006-01-25 11:32:50: (mod_fastcgi.c.989) execve failed for: public/dispatch.fcgi No such file or directory
2006-01-25 11:32:50: (mod_fastcgi.c.1015) the fastcgi-backend public/dispatch.fcgi failed to start:
2006-01-25 11:32:50: (mod_fastcgi.c.1019) child exited with status 2 public/dispatch.fcgi
2006-01-25 11:32:50: (mod_fastcgi.c.1022) if you try do run PHP as FastCGI backend make sure you use the FastCGI enabled version.
You can find out if it is the right one by executing 'php -v' and it should display '(cgi-fcgi)' in the output, NOT (cgi) NOR (cli)
For more information check http://www.lighttpd.net/documentation/fastcgi.html#preparing-php-as-a-fastcgi-program
2006-01-25 11:32:50: (mod_fastcgi.c.1027) If this is PHP on Gentoo add fastcgi to the USE flags
2006-01-25 11:32:50: (mod_fastcgi.c.1314) [ERROR]: spawning fcgi failed.
2006-01-25 11:32:50: (server.c.702) Configuration of plugins failed. Going down.

But if I change the reference to dispatch.fcgi to its full path, things start working. Or if I downgrade to 1.4.8, everything works as expected again. It just seems strange that this isn't all over the place, so I'm slightly inclined to believe it's something funky with my setup or in the freebsd port of lighttpd. But again, it works as expected when downgraded, and the symptoms exist on a virgin rails program.

-- GUI

Actions #1

Updated by jan over 16 years ago

  • Status changed from New to Fixed
  • Resolution set to fixed

in lighttpd 1.4.10 you will have CWD in your configfiles:

"bin-path" => CWD + "/public/dispatch.fcgi"

which will point to the current working dir. We had to change the bin-path base dir to / for security reasons.

Fixed in changeset r965

Actions #2

Updated by Anonymous over 14 years ago

You can get this cryptic error message when the lighttpd user cannot access the fcgi socket directory or the directory of the .fcgi file.

-- Ryan T Mulligan

Actions

Also available in: Atom