Skip site navigation (1)Skip section navigation (2)
Date:      3 Nov 2001 20:56:19 -0000
From:      "Martin Gignac  FreeBSD " <freebsd@mobilitylab.net>
To:        ravi@cow.org, Martin Gignac FreeBSD <freebsd@mobilitylab.net>, freebsd-questions@FreeBSD.ORG
Subject:   Re: Apache not binding to single address...
Message-ID:  <20011103205619.39204.qmail@mail.mobilitylab.net>

next in thread | raw e-mail | index | archive | help
I've used the Listen directive, as you've suggested:

===== httpd.conf =====
# Listen: Allows you to bind Apache to specific IP addresses and/or
# ports, in addition to the default. See also the <VirtualHost>
# directive.
#
#Listen 3000
#Listen 12.34.56.78:80
Listen 172.20.2.2:80
===== httpd.conf =====

Unfortunately, here are the results:

===== sockstat =====
su-2.05# sockstat | grep 80
nobody   httpd    39142   17 tcp4   *:80                  *:*
nobody   httpd    39142   18 tcp4   172.20.2.2:80         *:*
nobody   httpd    39141   17 tcp4   *:80                  *:*
nobody   httpd    39141   18 tcp4   172.20.2.2:80         *:*
nobody   httpd    39140   17 tcp4   *:80                  *:*
nobody   httpd    39140   18 tcp4   172.20.2.2:80         *:*
nobody   httpd    39139   17 tcp4   *:80                  *:*
nobody   httpd    39139   18 tcp4   172.20.2.2:80         *:*
nobody   httpd    39138   17 tcp4   *:80                  *:*
nobody   httpd    39138   18 tcp4   172.20.2.2:80         *:*
root     httpd    39137   17 tcp4   *:80                  *:*
root     httpd    39137   18 tcp4   172.20.2.2:80         *:*
===== sockstat =====

If I've read correctly in the Apache documents, Listen will _add_ a 
listener, while Bind will _instead_ bind the process to a specific 
address, which is what I am trying to achieve in this case.

-Martin

> On Sat, Nov 03, 2001 at 08:26:57PM -0000, Martin Gignac  FreeBSD  
said at one point in time:
> > Hi,
> > 
> > I'm running apache+mod_ssl-1.3.20+2.8.4 on a FreeBSD 4.4-STABLE 
system 
> > and I'm having a hard time binding the httpd server to a single IP 
> > address. I currently have many virtual IP addresses assigned to a 
> > single Ethernet card.
> > 
> [...]
> 
> how about
> 
> #
> # Listen: Allows you to bind Apache to specific IP addresses and/or
> # ports, in addition to the default. See also the <VirtualHost>
> # directive.
> #
> #Listen 3000
> #Listen 12.34.56.78:80
> 
> -r
> 
> 
> 
> -- 
> echo "send pgp key" | mail ravi@cow.org
> "I never think of the future. It comes soon enough."
>                 -- Albert Einstein
> 
> 
> To Unsubscribe: send mail to majordomo@FreeBSD.org
> with "unsubscribe freebsd-questions" in the body of the message
> 
> 



To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-questions" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20011103205619.39204.qmail>