Spill Group | 1 Nov 2006 13:04

Missing cleanup in fastcgi

Hi,

I have been investigating this for a while but came up with nothing.
I've searched the mailing list, Trac, the forum etc but could not find
anything useful.

Here's the deal: our error logs are literally being swamped by these
messages:

2006-11-01 11:44:01: (connections.c.816) missing cleanup in fastcgi 
2006-11-01 11:44:01: (mod_fastcgi.c.1449) 
2006-11-01 11:44:01: (connections.c.816) missing cleanup in fastcgi 
2006-11-01 11:44:01: (mod_fastcgi.c.1449) 
2006-11-01 11:44:01: (connections.c.816) missing cleanup in fastcgi 
2006-11-01 11:44:01: (mod_fastcgi.c.1449) 

This is happening since we put our custom FastCGI app into production on
Lighttpd 1.4.13. The test system ran 1.4.11, and we haven't seen these
messages on it.

I've scanned the Lighttpd 1.4.13 source code, but the only thing I came
up with is line 1448-51 in mod_fastcgi (as indicated in the logs):

        if (con->mode != p->id) {
                WP();
                return;
        }

This makes the fastcgi plugin return before it has the chance to
cleanup.
(Continue reading)

Cameron Ring | 1 Nov 2006 18:44
Favicon

RE: Missing cleanup in fastcgi

>Hi,
>
>I have been investigating this for a while but came up with nothing.
>I've searched the mailing list, Trac, the forum etc but could not find
>anything useful.
>
>Here's the deal: our error logs are literally being swamped by these
>messages:
>
>2006-11-01 11:44:01: (connections.c.816) missing cleanup in fastcgi
>2006-11-01 11:44:01: (mod_fastcgi.c.1449)
>2006-11-01 11:44:01: (connections.c.816) missing cleanup in fastcgi
>2006-11-01 11:44:01: (mod_fastcgi.c.1449)
>2006-11-01 11:44:01: (connections.c.816) missing cleanup in fastcgi
>2006-11-01 11:44:01: (mod_fastcgi.c.1449)

i've seen that error when the configuration file causes two plugins
to try and handle the same request (e.g. mod_cgi and mod_fastcgi),
so it's worth double checking your configuration to make sure that's
not happening.

thanks,
cam

Spill Group | 2 Nov 2006 09:40

RE: Missing cleanup in fastcgi

Cameron Ring wrote:
> i've seen that error when the configuration file causes two
> plugins to try and handle the same request (e.g. mod_cgi and
> mod_fastcgi), so it's worth double checking your
> configuration to make sure that's not happening.

Hi Cameron,

Thanks for the reply! You're absolutely right. I had this construction
in one of my config files:

$HTTP["host"] =~ "^www\.mydomain\.org(:[0-9]+)?$(?i)" {
	global {
		server.modules  += ("mod_fastcgi")
	}

	fastcgi.server          = ( ... )

}

$HTTP["host"] =~ "^www10\.mydomain\.org(:[0-9]+)?$(?i)" {
	global {
		server.modules  += ("mod_fastcgi")
	}

	fastcgi.server          = ( ... )

}

So I enabled the fastcgi module globally for two separate vhosts. This
is correct syntax, right? And it appears to work fine, apart from the
"missing cleanup in fastcgi" messages... So, is this a bug?

For now I removed the mod_fastcgi additions from the vhost config file
and enabled the module globally in my main config.

Regards,

-- 
Matthijs van der Klip
Technical Infrastructure Manager

Spill Group
Arendstraat 23
1223RE Hilversum
The Netherlands

T: +31 (0)35 647 82 48
F: +31 (0)35 647 82 49

W: http://www.spillgroup.com
E: matthijs <at> spillgroup.com

Confidentiality: This e-mail and its attachments are intended for the
above named only and may be confidential. If they have come to you in
error you must take no action based on them, nor must you copy or show
them to anyone; please reply to this e-mail and highlight the error.   

Security Warning: Please note that this e-mail has been created in the
knowledge that Internet e-mail is not a 100% secure communications
medium. We advise that you understand and observe this lack of security
when e-mailing us.   

Viruses: Although we have taken steps to ensure that this e-mail and
attachments are free from any virus, we advise that in keeping with
good computing practice the recipient should ensure they are actually
virus free.   

Ted Johnson | 2 Nov 2006 18:50
Picon
Favicon

Still Cannot Get Cert To Work!

109110
Hi;
I posted this almost 2 weeks ago and nobody replied. I've been out of action since then, but can somebody please tell me how to get certs installed using lightty? I'd hate to have to search for yet another server just because I can't install a cert.

TIA,
Ted

Hi;
I'm trying to install the cert I generated in lighttpd.conf and running
into trouble. I'm not sure if it's lighty's problem or CACert's, but I'm
hoping someone out there can help me. (It's been a long time since I've
installed a cert.) I followed instructions implicitly for installing the
cert and all looked well. Then I followed instructions in lighty for
incorporating the cert. I entered this in the conf file:

#### SSL
engine
ssl.engine                 = "enable"
ssl.pemfile                = "/root/lighttpd/ssl/shop.2012.vi.pem"
ssl.ca-file                = "/root/lighttpd/ssl/shop.2012.vi.crt"

Then I went to start lighty, but got this complaint:

server167# /usr/local/sbin/lighttpd -f
/usr/ports/www/lighttpd/doc/lighttpd.conf 2006-10-17 14:36:20:
(network.c.358) SSL: error:00000000:lib(0):func(0):reason(0)
/root/lighttpd/ssl/shop.2012.vi.crt

TIA,
Ted


Luis Bruno | 2 Nov 2006 20:47
Picon

Re: Still Cannot Get Cert To Work!

Ted Johnson wrote:
> I'm trying to install the cert I generated in lighttpd.conf and running
> into trouble. I'm not sure if it's lighty's problem or CACert's,

Funny you should mention CACert, as I'm having a bit of a problem with 
a certificate provided by them as well. My certificate is being used 
for IMAP-SSL, not even remotely connected with lighty.

You might want to check against another certificate.
--

-- 
Luis Bruno
Attachment (smime.p7s): application/pkcs7-signature, 2169 bytes
Chris Roos | 3 Nov 2006 11:04
Picon

mod accesslog and %D (time used in ms (not supported))

Does anyone have any info as to why this isn't implemented in lighttpd?

We'd like to pipe the logs out to a process that records response
times for certain requests.  We'd like to see these times in
real-time.  Are there any thoughts on how to achieve this given that
lighttpd doesn't seem to supply us with the data we required?

Cheers,

Chris

Robert Locke | 6 Nov 2006 08:10
Picon

mod_geoip

Hi gang,

Is anyone out there using "mod_geoip" in production?  Does it add a 
significant overhead to each request?  Is it best to store the GEO_IP 
database in memory?

Also, on a related note, is there a best approach to take in 
"internationalizing" a site for various languages, in terms of server, 
directory, code structure, etc?

Best,

Rob

Spill Group | 6 Nov 2006 10:21

RE: mod_geoip

Robert Locke wrote:
> Is anyone out there using "mod_geoip" in production?  Does it
> add a significant overhead to each request?  Is it best to
> store the GEO_IP database in memory?

Hi Robert,

We're using it production for a few weeks now. We haven't noticed
significant performance issues. We load the database in memory (the
country db is small), and are using an experimental patch on the
redirect module which is able to replace the environment variables set
by mod_geoip. Our config looks like this:

        # country preference through cookie
        $HTTP["cookie"] =~ "country=([^;]*)" {
                url.redirect = ( "^(/)?$" => "http://%1.mydomain.com/" )
        }

        # country detection through mod_geoip
        else $HTTP["cookie"] =~ ".*" {
                geoip.default_country_code = "global"
                geoip.force_lowercase = "enable"
                url.redirect = ( "^(/)?$" =>
"http://#GEOIP_COUNTRY_CODE#.mydomain.com/" )
        }

The 'default_country_code' and 'force_lowercase' options to mod_geoip
are custom, as well as the patch to mod_redirect. We'd like to give
these changes back to the community if anyone's interested, but we want
to make sure the code is stable before releasing it.

> Also, on a related note, is there a best approach to take in
> "internationalizing" a site for various languages, in terms
> of server, directory, code structure, etc?

As for the url, eventually we decided to go for
'COUNTRY.mydomain.com/LANGUAGE/'. We placed mod_geoip at
WWW.mydomain.com to redirect visitors to the correct country site.
Additionally some javascript is used for the language detection. This is
all static content however, so it may not apply to a fully dynamic site.

Regards,

-- 
Matthijs van der Klip
Technical Infrastructure Manager

Spill Group
Arendstraat 23
1223RE Hilversum
The Netherlands

T: +31 (0)35 647 82 48
F: +31 (0)35 647 82 49

W: http://www.spillgroup.com
E: matthijs <at> spillgroup.com

Confidentiality: This e-mail and its attachments are intended for the
above named only and may be confidential. If they have come to you in
error you must take no action based on them, nor must you copy or show
them to anyone; please reply to this e-mail and highlight the error.   

Security Warning: Please note that this e-mail has been created in the
knowledge that Internet e-mail is not a 100% secure communications
medium. We advise that you understand and observe this lack of security
when e-mailing us.   

Viruses: Although we have taken steps to ensure that this e-mail and
attachments are free from any virus, we advise that in keeping with
good computing practice the recipient should ensure they are actually
virus free.   

Matthias Saou | 6 Nov 2006 11:01

Re: mod_geoip

Spill Group wrote :

> We're using it production for a few weeks now. We haven't noticed
> significant performance issues. We load the database in memory (the
> country db is small), and are using an experimental patch on the
> redirect module which is able to replace the environment variables set
> by mod_geoip. Our config looks like this:
> 
>         # country preference through cookie
>         $HTTP["cookie"] =~ "country=([^;]*)" {
>                 url.redirect = ( "^(/)?$" => "http://%1.mydomain.com/" )
>         }
> 
>         # country detection through mod_geoip
>         else $HTTP["cookie"] =~ ".*" {
>                 geoip.default_country_code = "global"
>                 geoip.force_lowercase = "enable"
>                 url.redirect = ( "^(/)?$" =>
> "http://#GEOIP_COUNTRY_CODE#.mydomain.com/" )
>         }
> 
> The 'default_country_code' and 'force_lowercase' options to mod_geoip
> are custom, as well as the patch to mod_redirect. We'd like to give
> these changes back to the community if anyone's interested, but we want
> to make sure the code is stable before releasing it.

This looks all very nice. You could simply post a link to the sources
or patches here, or in the lighttpd trac.

Matthias

--

-- 
Clean custom Red Hat Linux rpm packages : http://freshrpms.net/
Fedora Core release 6 (Zod) - Linux kernel 2.6.18-1.2835.fc6
Load : 6.33 6.22 5.02

Rachel Florentine | 8 Nov 2006 15:43
Picon
Favicon

How Do I Set Up SSL?

Hi;
I'm new to LightTPD. I've successfully installed it (easy enough with the good instructions) and configured it with openssl. Now I need to configure a secure cert. How do I do this? I can't find any documentation. Could someone give me a hand? Is there anything similar to:

SSLCertificateFile <Path to your certificate file>/example_cert.pem
SSLCertificateKeyFile <Path to your key file>/example_key.pem
SSLCertificateChainFile <Path to your chain file>/CAcert_chain.pem

TIA,
Rachel


Gmane