nixCraft Linux Forum

nixCraft

Linux Tech Support Forum

Ligghttpd shutdown itself.

This is a discussion on Ligghttpd shutdown itself. within the Web servers forums, part of the Mastering Servers category; I thought of shfting to lighttpd from apache but suffered at the hands of following errors ...... As i started ...


Go Back   nixCraft Linux Forum > Mastering Servers > Web servers

Register FAQ Members List Calendar Mark Forums Read
  #1 (permalink)  
Old 06-21-2008, 09:35 AM
Junior Member
User
 
Join Date: Jun 2008
My distro: centos 5
Posts: 15
Rep Power: 0
rootadmin is on a distinguished road
Arrow Ligghttpd shutdown itself.

I thought of shfting to lighttpd from apache but suffered at the hands of following errors ......
As i started lighttpd i found
1. unable to login
2. image sharing site urls started redirect to home page instead of image

and after sometime 20mins lighttpd was not running anymore . my site was

2008-05-21 09:42:12: (mod_fastcgi.c.2570) FastCGI-stderr: PHP Warning: Unknown: open(/var/lib/php/session/sess_ogv77ofh3mctp
cend5uq33pb36, O_RDWR) failed: Permission denied (13) in Unknown on line 0
PHP Warning: Unknown: Failed to write session data (file. Please verify that the current setting of session.save_path is c
orrect (/var/lib/php/session) in Unknown on line 0



2008-05-21 09:51:41: (mod_fastcgi.c.2570) FastCGI-stderr: PHP Warning: session_start() [<a href='function.session-start'>fun
ction.session-start</a>]: open(/var/lib/php/session/sess_aqn7ihrddt382ilqvj7go7o0a2, O_RDWR) failed: Permission denied (13) i
n /var/www/html/file/captcha.php on line 18
PHP Notice: Undefined variable: imagetype in /var/www/html/file/captcha.php on line 74



2008-05-21 09:51:42: (mod_fastcgi.c.2570) FastCGI-stderr: PHP Warning: Unknown: open(/var/lib/php/session/sess_aqn7ihrddt382
ilqvj7go7o0a2, O_RDWR) failed: Permission denied (13) in Unknown on line 0
PHP Warning: Unknown: Failed to write session data (file. Please verify that the current setting of session.save_path is c
orrect (/var/lib/php/session) in Unknown on line 0



2008-05-21 10:07:22: (mod_fastcgi.c.2570) FastCGI-stderr: PHP Notice: Use of undefined constant servers - assumed 'servers'
in /var/www/html/file/includes/upload.class.php on line 67
PHP Notice: Use of undefined constant upload_dir - assumed 'upload_dir' in /var/www/html/file/includes/upload.class.php on l
ine 83
PHP Notice: Use of undefined constant keepext - assumed 'keepext' in /var/www/html/file/includes/upload.class.php on line 84
PHP Notice: Undefined index: dtstart in /var/www/html/file/progress.php on line 53
PHP Notice: Undefined variable: iNums in /var/www/html/file/progress.php on line 161



PHP Notice: Use of undefined constant REMOTE_ADDR - assumed 'REMOTE_ADDR' in /var/www/html/file/includes/function.php on lin
e 1086
PHP Notice: Use of undefined constant redir - assumed 'redir' in /var/www/html/file/cross.php on line 23
PHP Notice: Undefined index: redir in /var/www/html/file/cross.php on line 23
PHP Notice: Use of undefined constant url - assumed 'url' in /var/www/html/file/cross.php on line 53
PHP Notice: Use of undefined constant url - assumed 'url' in /var/www/html/file/cross.php on line 53
PHP Notice: Use of undefined constant phpuploadscript - assumed 'phpuploadscript' in /var/www/html/file/cross.php on line 54
PHP Notice: Undefined variable: myquery in /var/www/html/file/includes/function.php on line 1034





2008-06-20 10:30:29: (mod_fastcgi.c.2570) FastCGI-stderr: PHP Warning: Unknown: open(/var/lib/php/session/sess_vveuppavuc75klpmi3khtmn3a0, O_RDWR) failed: Permission denied (13) in Unknown on line 0
PHP Warning: Unknown: Failed to write session data (file. Please verify that the current setting of session.save_path is correct (/var/lib/php/session) in Unknown on line 0

2008-06-20 10:34:53: (server.c.1253) NOTE: a request for / timed out after writing 11680 bytes. We waited 360 seconds. If this a problem increase server.max-write-idle
2008-06-20 10:38:21: (server.c.1470) server stopped by UID = 0 PID = 26343

Please advice me an coplete solution Thanks in advance
Reply With Quote
Sponsored Links
  #2 (permalink)  
Old 06-21-2008, 12:04 PM
rockdalinux's Avatar
Contributors
User
 
Join Date: May 2005
Location: Bangalore
My distro: RHEL, HP-UX, Solaris, FreeBSD, Ubuntu
Posts: 564
Rep Power: 7
rockdalinux is a jewel in the rough rockdalinux is a jewel in the rough rockdalinux is a jewel in the rough rockdalinux is a jewel in the rough
Default

Set correct permission for /var/lib/php/ so that php can access the folder
Lighttpd beware of default php session path permission
__________________
Rocky Jr.
You may have my body & soul, but you will never touch my pride!

If you have knowledge, let others light their candles at it.

Certified to work on HP-UX / Sun Solaris / RedHat
Reply With Quote
  #3 (permalink)  
Old 06-21-2008, 12:18 PM
Junior Member
User
 
Join Date: Jun 2008
My distro: centos 5
Posts: 15
Rep Power: 0
rootadmin is on a distinguished road
Default

sorry but i dnt know how to set this kind of permission , can you tell the exact command to be used for Centos 5 distro.

Thanks.
Reply With Quote
  #4 (permalink)  
Old 06-21-2008, 03:06 PM
Junior Member
User
 
Join Date: Jun 2008
My distro: centos 5
Posts: 15
Rep Power: 0
rootadmin is on a distinguished road
Default

thank ^^ problem got fixed but still
links of type
http://example.com/image/show.php/25...itled.JPG.html

gets redirected to

ample baby web site own at expample.com i.e homepage

I got no clue why thats happening . please advice an solution for it also....Thanks
Reply With Quote
  #5 (permalink)  
Old 06-21-2008, 03:21 PM
rockdalinux's Avatar
Contributors
User
 
Join Date: May 2005
Location: Bangalore
My distro: RHEL, HP-UX, Solaris, FreeBSD, Ubuntu
Posts: 564
Rep Power: 7
rockdalinux is a jewel in the rough rockdalinux is a jewel in the rough rockdalinux is a jewel in the rough rockdalinux is a jewel in the rough
Default

You must have url.redirect or url.rewrite configured and it is doing something wrong. Can you paste your config file here or link it from a webpage ?
__________________
Rocky Jr.
You may have my body & soul, but you will never touch my pride!

If you have knowledge, let others light their candles at it.

Certified to work on HP-UX / Sun Solaris / RedHat
Reply With Quote
  #6 (permalink)  
Old 06-21-2008, 04:18 PM
Junior Member
User
 
Join Date: Jun 2008
My distro: centos 5
Posts: 15
Rep Power: 0
rootadmin is on a distinguished road
Default

# lighttpd configuration file
#
# use it as a base for lighttpd 1.0.0 and above
#
# $Id: lighttpd.conf,v 1.7 2004/11/03 22:26:05 weigon Exp $

############ Options you really have to take care of ####################

## modules to load
# at least mod_access and mod_accesslog should be loaded
# all other module should only be loaded if really neccesary
# - saves some time
# - saves memory
server.modules = (
"mod_rewrite",
"mod_redirect",
"mod_alias",
"mod_access",
"mod_cml",
"mod_trigger_b4_dl",
"mod_auth",
"mod_status",
"mod_setenv",
"mod_fastcgi",
"mod_proxy",
"mod_simple_vhost",
"mod_evhost",
"mod_userdir",
"mod_cgi",
"mod_compress",
"mod_ssi",
"mod_usertrack",
"mod_expire",
"mod_secdownload",
#"mod_rrdtool",
"mod_accesslog")

## a static document-root, for virtual-hosting take look at the
## server.virtual-* options
## server.document-root = "/srv/www/lighttpd/"

server.document-root = "/var/www/html/"
## where to send error-messages to
server.errorlog = "/var/log/lighttpd/error.log"

# files to check for if .../ is requested
index-file.names = ( "index.php", "index.html",
"index.htm", "default.htm" )

## set the event-handler (read the performance section in the manual)
# server.event-handler = "freebsd-kqueue" # needed on OS X

# mimetype mapping
mimetype.assign = (
".rpm" => "application/x-rpm",
".pdf" => "application/pdf",
".sig" => "application/pgp-signature",
".spl" => "application/futuresplash",
".class" => "application/octet-stream",
".ps" => "application/postscript",
".torrent" => "application/x-bittorrent",
".dvi" => "application/x-dvi",
".gz" => "application/x-gzip",
".pac" => "application/x-ns-proxy-autoconfig",
".swf" => "application/x-shockwave-flash",
".tar.gz" => "application/x-tgz",
".tgz" => "application/x-tgz",
".tar" => "application/x-tar",
".zip" => "application/zip",
".mp3" => "audio/mpeg",
".m3u" => "audio/x-mpegurl",
".wma" => "audio/x-ms-wma",
".wax" => "audio/x-ms-wax",
".ogg" => "application/ogg",
".wav" => "audio/x-wav",
".gif" => "image/gif",
".jpg" => "image/jpeg",
".jpeg" => "image/jpeg",
".png" => "image/png",
".xbm" => "image/x-xbitmap",
".xpm" => "image/x-xpixmap",
".xwd" => "image/x-xwindowdump",
".css" => "text/css",
".html" => "text/html",
".htm" => "text/html",
".js" => "text/javascript",
".asc" => "text/plain",
".c" => "text/plain",
".cpp" => "text/plain",
".log" => "text/plain",
".conf" => "text/plain",
".text" => "text/plain",
".txt" => "text/plain",
".dtd" => "text/xml",
".xml" => "text/xml",
".mpeg" => "video/mpeg",
".mpg" => "video/mpeg",
".mov" => "video/quicktime",
".qt" => "video/quicktime",
".avi" => "video/x-msvideo",
".asf" => "video/x-ms-asf",
".asx" => "video/x-ms-asf",
".wmv" => "video/x-ms-wmv",
".bz2" => "application/x-bzip",
".tbz" => "application/x-bzip-compressed-tar",
".tar.bz2" => "application/x-bzip-compressed-tar",
# default mime type
"" => "application/octet-stream",
)

# Use the "Content-Type" extended attribute to obtain mime type if possible
#mimetype.use-xattr = "enable"


## send a different Server: header
## be nice and keep it at lighttpd
# server.tag = "lighttpd"

#### accesslog module
accesslog.filename = "/var/log/lighttpd/access.log"

## deny access the file-extensions
#
# ~ is for backupfiles from vi, emacs, joe, ...
# .inc is often used for code includes which should in general not be part
# of the document-root
url.access-deny = ( "~", ".inc" )

$HTTP["url"] =~ "\.pdf$" {
server.range-requests = "disable"
}

##
# which extensions should not be handle via static-file transfer
#
# .php, .pl, .fcgi are most often handled by mod_fastcgi or mod_cgi
static-file.exclude-extensions = ( ".php", ".pl", ".fcgi" )
Reply With Quote
  #7 (permalink)  
Old 06-21-2008, 04:19 PM
Junior Member
User
 
Join Date: Jun 2008
My distro: centos 5
Posts: 15
Rep Power: 0
rootadmin is on a distinguished road
Default

######### Options that are good to be but not neccesary to be changed #######

## bind to port (default: 80)
server.port = 81

## bind to localhost (default: all interface
#server.bind = "127.0.0.1"

## error-handler for status 404
#server.error-handler-404 = "/error-handler.html"
#server.error-handler-404 = "/error-handler.php"

## to help the rc.scripts
server.pid-file = "/var/run/lighttpd.pid"


###### virtual hosts
##
## If you want name-based virtual hosting add the next three settings and load
## mod_simple_vhost
##
## document-root =
## virtual-server-root + virtual-server-default-host + virtual-server-docroot
## or
## virtual-server-root + http-host + virtual-server-docroot
##
#simple-vhost.server-root = "/srv/www/vhosts/"
#simple-vhost.default-host = "www.example.org"
#simple-vhost.document-root = "/htdocs/"


##
## Format: <errorfile-prefix><status-code>.html
## -> ..../status-404.html for 'File not found'
#server.errorfile-prefix = "/usr/share/lighttpd/errors/status-"
#server.errorfile-prefix = "/srv/www/errors/status-"

## virtual directory listings
#dir-listing.activate = "enable"

## enable debugging
#debug.log-request-header = "enable"
#debug.log-response-header = "enable"
#debug.log-request-handling = "enable"
#debug.log-file-not-found = "enable"

### only root can use these options
#
# chroot() to directory (default: no chroot() )
#server.chroot = "/"

## change uid to <uid> (default: don't care)
server.username = "lighttpd"

## change uid to <uid> (default: don't care)
server.groupname = "lighttpd"

#### compress module
#compress.cache-dir = "/var/cache/lighttpd/compress/"
#compress.filetype = ("text/plain", "text/html")


#### proxy module
## read proxy.txt for more info
#proxy.server = ( ".php" =>
# ( "localhost" =>
# (
# "host" => "192.168.0.101",
# "port" => 80
# )
# )
# )

#### fastcgi module
## read fastcgi.txt for more info
## for PHP don't forget to set cgi.fix_pathinfo = 1 in the php.ini


fastcgi.server = ( ".php" =>
("localhost" =>
(
"bin-path" => "/usr/bin/php-cgi",
"socket" => "/tmp/php.socket",
"max-procs" => 2,
"bin-environment" => (
"PHP_FCGI_CHILDREN" => "16",
"PHP_FCGI_MAX_REQUESTS" => "10000"
),
"bin-copy-environment" => (
"PATH", "SHELL", "USER"
),
"broken-scriptfilename" => "enable"
)))

#### CGI module
cgi.assign = ( ".pl" => "/usr/bin/perl",
".cgi" => "/usr/bin/perl" )
#

#### SSL engine
#ssl.engine = "enable"
#ssl.pemfile = "/etc/ssl/private/lighttpd.pem"

#### status module
#status.status-url = "/server-status"
#status.config-url = "/server-config"

#### auth module
## read authentication.txt for more info
#auth.backend = "plain"
#auth.backend.plain.userfile = "lighttpd.user"
#auth.backend.plain.groupfile = "lighttpd.group"

#auth.backend.ldap.hostname = "localhost"
#auth.backend.ldap.base-dn = "dc=my-domain,dc=com"
#auth.backend.ldap.filter = "(uid=$)"

#auth.require = ( "/server-status" =>
# (
# "method" => "digest",
# "realm" => "download archiv",
# "require" => "user=jan"
# ),
# "/server-config" =>
# (
# "method" => "digest",
# "realm" => "download archiv",
# "require" => "valid-user"
# )
# )

#### url handling modules (rewrite, redirect, acces
#url.rewrite = ( "^/$" => "/server-status" )
#url.redirect = ( "^/wishlist/(.+)" => "http://www.123.org/$1" )
#### both rewrite/redirect support back reference to regex conditional using %n
#$HTTP["host"] =~ "^www\.(.*)" {
# url.redirect = ( "^/(.*)" => "http://%1/$1" )
#}

#
# define a pattern for the host url finding
# %% => % sign
# %0 => domain name + tld
# %1 => tld
# %2 => domain name without tld
# %3 => subdomain 1 name
# %4 => subdomain 2 name
#
#evhost.path-pattern = "/srv/www/vhosts/%3/htdocs/"

#### expire module
#expire.url = ( "/buggy/" => "access 2 hours", "/asdhas/" => "access plus 1 seconds 2 minutes")

#### ssi
#ssi.extension = ( ".shtml" )

#### rrdtool
#rrdtool.binary = "/usr/bin/rrdtool"
#rrdtool.db-name = "/var/lib/lighttpd/lighttpd.rrd"

#### setenv
#setenv.add-request-header = ( "TRAV_ENV" => "mysql://user@host/db" )
#setenv.add-response-header = ( "X-Secret-Message" => "42" )

## for mod_trigger_b4_dl
# trigger-before-download.gdbm-filename = "/var/lib/lighttpd/trigger.db"
# trigger-before-download.memcache-hosts = ( "127.0.0.1:11211" )
# trigger-before-download.trigger-url = "^/trigger/"
# trigger-before-download.download-url = "^/download/"
# trigger-before-download.deny-url = "http://127.0.0.1/index.html"
# trigger-before-download.trigger-timeout = 10

## for mod_cml
## don't forget to add index.cml to server.indexfiles
# cml.extension = ".cml"
# cml.memcache-hosts = ( "127.0.0.1:11211" )

#### variable usage:
## variable name without "." is auto prefixed by "var." and becomes "var.bar"
#bar = 1
#var.mystring = "foo"

## integer add
#bar += 1
## string concat, with integer cast as string, result: "www.foo1.com"
#server.name = "www." + mystring + var.bar + ".com"
## array merge
#index-file.names = (foo + ".php") + index-file.names
#index-file.names += (foo + ".php")

#### include
#include /etc/lighttpd/lighttpd-inc.conf
## same as above if you run: "lighttpd -f /etc/lighttpd/lighttpd.conf"
#include "lighttpd-inc.conf"

#### include_shell
#include_shell "echo var.a=1"
## the above is same as:
#var.a=1

$HTTP["host"] =~ "(^|\.)domain\.com$" {
server.document-root = "/var/www/html"
server.errorlog = "/var/log/lighttpd/domain/error_lighttpd.log"
accesslog.filename = "/var/log/lighttpd/domain/access_lighttpd.log"
server.error-handler-404 = "/e404.php"

#$HTTP["url"] =~ "file/cgi-bin/" {
# cgi.assign = ( ".pl" => "/usr/bin/perl"
# ".cgi" => "/usr/bin/perl" )
# }

}
Reply With Quote
Reply

Bookmarks


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)

 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Similar Threads

Thread Thread Starter Forum Replies Last Post
SuSe hangs on shutdown lacloai Linux software 5 08-09-2008 02:59 AM
Windows XP speed up boot and shutdown times sbmk Windows Xp/2000/2003 server administration 6 07-28-2008 06:09 AM
Remotly Shutdown unix Server sweta Solaris/OpenSolaris 2 01-22-2008 05:02 AM
Unexpected shutdown ammaro Linux software 2 04-23-2007 12:12 PM
Script to shutdown the win2k server bubloob_13 Windows Xp/2000/2003 server administration 1 01-16-2007 02:16 PM


All times are GMT +5.5. The time now is 11:17 PM.


Powered by vBulletin® Version 3.7.3 - Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.2.0

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36