• : Function ereg() is deprecated in /home/happlee4/public_html/infoentropy/includes/file.inc on line 644.
  • : Function ereg() is deprecated in /home/happlee4/public_html/infoentropy/includes/file.inc on line 644.
  • : Function ereg() is deprecated in /home/happlee4/public_html/infoentropy/includes/file.inc on line 644.
  • : Function ereg() is deprecated in /home/happlee4/public_html/infoentropy/includes/file.inc on line 644.
  • : Function ereg() is deprecated in /home/happlee4/public_html/infoentropy/includes/file.inc on line 644.
  • : Function ereg() is deprecated in /home/happlee4/public_html/infoentropy/includes/file.inc on line 644.
  • : Function ereg() is deprecated in /home/happlee4/public_html/infoentropy/includes/file.inc on line 644.
  • : Function ereg() is deprecated in /home/happlee4/public_html/infoentropy/includes/file.inc on line 644.
  • : Function ereg() is deprecated in /home/happlee4/public_html/infoentropy/includes/file.inc on line 644.
  • : Function ereg() is deprecated in /home/happlee4/public_html/infoentropy/includes/file.inc on line 644.
  • : Function ereg() is deprecated in /home/happlee4/public_html/infoentropy/includes/file.inc on line 644.
  • : Function ereg() is deprecated in /home/happlee4/public_html/infoentropy/includes/file.inc on line 644.
  • : Function ereg() is deprecated in /home/happlee4/public_html/infoentropy/includes/file.inc on line 644.
  • : Function ereg() is deprecated in /home/happlee4/public_html/infoentropy/includes/file.inc on line 644.
  • : Function ereg() is deprecated in /home/happlee4/public_html/infoentropy/includes/file.inc on line 644.
  • : Function ereg() is deprecated in /home/happlee4/public_html/infoentropy/includes/file.inc on line 644.
  • : Function ereg() is deprecated in /home/happlee4/public_html/infoentropy/includes/file.inc on line 644.
  • : Function ereg() is deprecated in /home/happlee4/public_html/infoentropy/includes/file.inc on line 644.
  • : Function ereg() is deprecated in /home/happlee4/public_html/infoentropy/includes/file.inc on line 644.
  • : Function ereg() is deprecated in /home/happlee4/public_html/infoentropy/includes/file.inc on line 644.
  • : Function ereg() is deprecated in /home/happlee4/public_html/infoentropy/includes/file.inc on line 644.
  • : Function ereg() is deprecated in /home/happlee4/public_html/infoentropy/includes/file.inc on line 644.
  • : Function ereg() is deprecated in /home/happlee4/public_html/infoentropy/includes/file.inc on line 644.
  • : Function ereg() is deprecated in /home/happlee4/public_html/infoentropy/includes/file.inc on line 644.
  • : Function ereg() is deprecated in /home/happlee4/public_html/infoentropy/includes/file.inc on line 644.
  • : Function ereg() is deprecated in /home/happlee4/public_html/infoentropy/includes/file.inc on line 644.
  • : Function ereg() is deprecated in /home/happlee4/public_html/infoentropy/includes/file.inc on line 644.
  • : Function ereg() is deprecated in /home/happlee4/public_html/infoentropy/includes/file.inc on line 644.
  • : Function ereg() is deprecated in /home/happlee4/public_html/infoentropy/includes/file.inc on line 644.
  • : Function ereg() is deprecated in /home/happlee4/public_html/infoentropy/includes/file.inc on line 644.
  • : Function ereg() is deprecated in /home/happlee4/public_html/infoentropy/includes/file.inc on line 644.
  • : Function ereg() is deprecated in /home/happlee4/public_html/infoentropy/includes/file.inc on line 644.
  • : Function ereg() is deprecated in /home/happlee4/public_html/infoentropy/includes/file.inc on line 644.
  • : Function ereg() is deprecated in /home/happlee4/public_html/infoentropy/includes/file.inc on line 644.
  • : Function ereg() is deprecated in /home/happlee4/public_html/infoentropy/includes/file.inc on line 644.
  • : Function ereg() is deprecated in /home/happlee4/public_html/infoentropy/includes/file.inc on line 644.
  • : Function ereg() is deprecated in /home/happlee4/public_html/infoentropy/includes/file.inc on line 644.
  • : Function ereg() is deprecated in /home/happlee4/public_html/infoentropy/includes/file.inc on line 644.
  • : Function ereg() is deprecated in /home/happlee4/public_html/infoentropy/includes/file.inc on line 644.
  • : Function ereg() is deprecated in /home/happlee4/public_html/infoentropy/includes/file.inc on line 644.
  • : Function ereg() is deprecated in /home/happlee4/public_html/infoentropy/includes/file.inc on line 644.

Configure Drupal on LigHTTPD

Submitted by jeff on Sat, 2006-11-04 18:49.

Since I use Drupal quite a bit for this website I thought it would be a good idea to setup a test environment for myself so that I can tinker with themes and explore the system some more. Unfortunately Drupal's community documentation is terrible because the support forums get off-topic frequently and the search mechanism they have a wretched search system.

These 2 sets of instructions have been particularly helpful in setting up the environment.

  1. Install Drupal to Ubuntu
  2. Then Configure LigHTTPD fastcgi for Drupal
  3. Remember to (1) restart your Lighttpd server OR (2) run from the command line to get errors and warnings.
    1. sudo /etc/init.d/lighttpd restart
    2. sudo lighttpd -D -f /etc/lighttpd/lighttpd.conf

If you try to run it before step 2 you will get an error because FastCGI isn't configured yet.

strict warning: var: Deprecated. Please use the public/private/protected modifiers in /usr/share/drupal/themes/engines/xtemplate/xtemplate.inc on line 42.

Long story short, this chunk of LigHTTPD config that I use that let's me get to drupal on http://localhost/drupal.


var.drupal="/var/www/drupal"
$HTTP["url"]=~"^/drupal" {
        #rails-stuff
        fastcgi.server = (".php" =>
                          ("localhost" =>
                           (
                             "min-procs" => 1,
                             "max-procs" => 2,
                             "socket" => "/tmp/drupal.socket",
                             "bin-path" => "/usr/bin/php4-cgi"
                         )))
}

Fri, 2007-01-05 08:16 from jeff (not verified):

remember to add this line to php.ini

add this line to the php.ini in the paths and directories section, it fixes something.

cgi.fix_pathinfo = 1

for ubuntu, the file location depending on version is

/etc/php5/cgi/php.ini

/etc/php4/cgi/php.ini

Sat, 2006-12-02 02:29 from jeff:

use php5-cgi instead

I don't know what the difference between php4-cgi or php5-cgi are but using php4-cgi gave me this error.


2006-12-01 21:26:04: (mod_fastcgi.c.1014) the fastcgi-backend /usr/bin/php4-cgi failed to start:
2006-12-01 21:26:04: (mod_fastcgi.c.1029) terminated by signal: 11
2006-12-01 21:26:04: (mod_fastcgi.c.1034) to be exact: it seg-fault, crashed, died, ... you get the idea.
2006-12-01 21:26:04: (mod_fastcgi.c.1036) If this is PHP try to remove the byte-code caches for now and try again.
2006-12-01 21:26:04: (mod_fastcgi.c.1322) [ERROR]: spawning fcgi failed.
2006-12-01 21:26:04: (server.c.832) Configuration of plugins failed. Going down.

by switching over to the bin-path to php5-cgi, fastcgi runs.

var.drupal="/usr/share/drupal"
$HTTP["url"] =~ "^/drupal" {
fastcgi.server = (".php" =>
("localhost" => (
"min-procs" => 1,
"max-procs" => 2,
"socket" => "/tmp/drupal.socket",
"bin-path" => "/usr/bin/php4-cgi",
"bin-copy-environment" => (
"PATH", "SHELL", "USER"
)
)))
}