can't bind to port 80

Bug #551211 reported by Lenin
54
This bug affects 10 people
Affects Status Importance Assigned to Milestone
lighttpd (Ubuntu)
Fix Released
High
Unassigned

Bug Description

Binary package hint: lighttpd

i'm sure nothing is already bound, since netstat -plunt | grep 80 returns nothing. the version in karmic works, the one in lucid not: (1.4.22-1ubuntu4 and 1.4.26-1.1ubuntu1). I backported karmic version, that works again now. i'm on a powerpc g4 imac.

Revision history for this message
Kenneth O'Brien (kobrien) wrote :

Output from me. (clean install lucid beta 1)

* Starting web server lighttpd 2010-03-29 23:32:04: (network.c.345) can't bind to port: :: 80 Address already in use [fail] invoke-rc.d: initscript lighttpd, action "start" failed. Setting up spawn-fcgi (1.6.3-1) ... update-alternatives: using /usr/bin/spawn-fcgi.standalone to provide /usr/bin/spawn-fcgi (spawn-fcgi) in auto mode. update-alternatives: warning: not replacing /usr/share/man/man1/spawn-fcgi.1.gz with a link.

Changed in lighttpd (Ubuntu):
status: New → Confirmed
Revision history for this message
Kenneth O'Brien (kobrien) wrote :

I assume a missing a dependency?

Revision history for this message
Daniel Hahler (blueyed) wrote :

No, that's not related to spawn-fcgi.
I can confirm that nothing is running on port 80 for me, too ("netstat -tulpen | grep 80").
Using port 81 in the lighttpd conf works however.

@Kenneth: does lighty start for you on port 80?

Changed in lighttpd (Ubuntu):
importance: Undecided → High
status: Confirmed → Triaged
milestone: none → ubuntu-10.04-beta-2
Revision history for this message
Kenneth O'Brien (kobrien) wrote :

Doesn't start, no.

Changed in lighttpd (Ubuntu):
assignee: nobody → Kenneth O'Brien (kobrien)
Revision history for this message
Kenneth O'Brien (kobrien) wrote :

*patching this*

Revision history for this message
Andres Rodriguez (andreserl) wrote :

Hi all,

You might want to commend in lighttpd.conf the following:

include_shell "/usr/share/lighttpd/use-ipv6.pl"

On the other hand, you might wan't to check [1]:

[1]: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=560837

Revision history for this message
Andres Rodriguez (andreserl) wrote :

According to comment [1] from upstream, they will have a new logic to handle IPV6 for lighttpd 2.0.x. They recommend to drop the use of use-ipv6.pl script by default.

Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package lighttpd - 1.4.26-1.1ubuntu2

---------------
lighttpd (1.4.26-1.1ubuntu2) lucid; urgency=low

  * debian/lighttpd.conf: Comment 'use-ipv6.pl' by default, which causes
    failure to bind port in ipv4 (LP: #551211)
 -- Andres Rodriguez <email address hidden> Sat, 03 Apr 2010 15:37:37 -0400

Changed in lighttpd (Ubuntu):
status: Triaged → Fix Released
Revision history for this message
Kenneth O'Brien (kobrien) wrote :

This fixes the issue.

Changed in lighttpd (Ubuntu):
assignee: Kenneth O'Brien (kobrien) → nobody
Revision history for this message
RoyK (roysk) wrote :

The proposed fix seems to break IPv6 after all, changing bind address to localhost instead of "any".

Revision history for this message
Andres Rodriguez (andreserl) wrote :

That's why the use-ipv6 script in lighttpd.conf is now disabled by default. As I previously said over a discussion on irc and as explained in the Debian bug, this will be addressed differently by upstream developers of lighttpd [1], for lighttpd sandbox/2.0.

[1]: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=560837#38

Revision history for this message
bodhi.zazen (bodhi.zazen) wrote :

This bug is still a "problem" in lucid.

# service lighttpd start
Syntax OK
 * Starting web server lighttpd 2010-05-13 20:37:27: (network.c.345) can't bind to port: :: 80 Address already in use

# apt-cache show lighttpd
Package: lighttpd
Priority: optional
Section: universe/web
Installed-Size: 1012
Maintainer: Ubuntu Developers <email address hidden>
Original-Maintainer: Debian lighttpd maintainers <pkg-lighttpd-maintainers@lists .alioth.debian.org>
Architecture: amd64
Version: 1.4.26-1.1ubuntu3
Provides: httpd, httpd-cgi
Depends: libattr1 (>= 2.4.41-1), libbz2-1.0, libc6 (>= 2.4), libgamin0 | libfam0 , libldap-2.4-2 (>= 2.4.7), libpcre3 (>= 7.7), libssl0.9.8 (>= 0.9.8k-1), zlib1g (>= 1:1.1.4), lsb-base (>= 3.2-14), mime-support, libterm-readline-perl-perl
Recommends: spawn-fcgi
Suggests: openssl, rrdtool, apache2-utils, ufw
Conflicts: cherokee (<= 0.6.1-1)
Filename: pool/universe/l/lighttpd/lighttpd_1.4.26-1.1ubuntu3_amd64.deb
Size: 297310
MD5sum: 0b4788bed2a0c0ed7d303c376a57b30f
SHA1: 039999c1e10cd4d7294bf8a54d56522fa49d8132
SHA256: 670764b138cc37b00574c636ac6c3d88bcb9bb146746a2a018cd3cfe56a8635c
Description: A fast webserver with minimal memory footprint
 lighttpd is a small webserver and fast webserver developed with
 security in mind and a lot of features.
 It has support for
   * CGI, FastCGI and SSI
   * virtual hosts
   * URL rewriting
   * authentication (plain files, htpasswd, ldap)
   * transparent content compression
   * conditional configuration
 and configuration is straight-forward and easy.
Homepage: http://www.lighttpd.net
Bugs: https://bugs.launchpad.net/ubuntu/+filebug
Origin: Ubuntu

# grep ipv6 /etc/lighttpd/lighttpd.conf
## Use ipv6 only if available.
include_shell "/usr/share/lighttpd/use-ipv6.pl"

I can start lighttpd by commenting out that line

#include_shell "/usr/share/lighttpd/use-ipv6.pl"

Revision history for this message
Durand D'souza (durand1) wrote :

It's still a problem in maverick.

Revision history for this message
Stefan Bühler (stbuehler) wrote :

This has been fixed upstream in 1.4.27, for details see http://redmine.lighttpd.net/projects/lighttpd/wiki/IPv6-Config
The debian script can be used again.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.