-   Linux - Server (
-   -   could not bind to address, driving me crazy! (

jbcolmena 07-22-2010 06:47 AM

could not bind to address, driving me crazy!
Hi all.

I'm using xubuntu 9.10. NOT ubuntu server. I need to install a lamp server on my box. I cannot install a new OS like ubuntu server, have to use what I got.

when I run apache2, I get:

(98)Address already in use: make_sock: could not bind to address
no listening sockets available, shutting down
Unable to open logs
I've changed the port that php listens too to 8080, 81, and I get the same message but with the new port number.

I've removed and installed apache three times, read all kind of threats on the web, but cannot find the solution! it's just driving crazy. Any ideas?

jbcolmena 07-22-2010 07:06 AM

I changed the ports editing the /etc/apache2/ports.conf file, which is:

# If you just change the port or add more ports here, you will likely also
# have to change the VirtualHost statement in
# /etc/apache2/sites-enabled/000-default
# This is also true if you have upgraded from before 2.2.9-3 (i.e. from
# Debian etch). See /usr/share/doc/apache2.2-common/NEWS.Debian.gz and
# README.Debian.gz

NameVirtualHost *:80
Listen 80

<IfModule mod_ssl.c>
# SSL name based virtual hosts are not yet supported, therefore no
# NameVirtualHost statement here
Listen 443
netstat -A inet -lnp gives:

Protocolo Recv-Q Send-Q Dirección Local Dirección Externa Estado PID/Program name
tcp 0 0* ESCUCHAR -
tcp 0 0* ESCUCHAR -
tcp 0 0* ESCUCHAR -
tcp 0 0* ESCUCHAR -
tcp 0 0* ESCUCHAR -
tcp 0 0* ESCUCHAR -
tcp 0 0* ESCUCHAR -
udp 0 0* -
udp 0 0* -
udp 0 0* -
which yes, shows something listening to port 80, but what? BTW, "escuchar" is listening is spanish. Live in italy, box in spanish, in an english forum... confusing.

sem007 07-22-2010 07:22 AM

Hi jbcolmena,

kindly paste output of below command

dpkg --list apache*

netstat -antlp | grep 80

jbcolmena 07-22-2010 07:42 AM

Of course port 80 was busy... because apache was listening to it! apache has been working all the time...

read something the wrong way, don't know, but made a newbie mistake and wasted like 6 hours on a problem that didn't even exists.

Sorry to waste your time.

All times are GMT -5. The time now is 07:32 AM.