httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From (David Robinson)
Subject Re: How about mixing BindAddress and VirtualHost???
Date Tue, 06 Feb 1996 18:59:00 GMT
>The problem...
>>       Note that with apache you only appear to have the following choices:
>>       *   One server (two or more processes) answering one IP address
>>       *   One server (two or more processes) answering *every* IP
>>           alias on the machine.
>>       *   One server per virtual host (two or more processes per
>>           server) each answering one IP address
>>       I have gone the second route, which implies I had to create a
>>       dummy index page which returns an error when people try to
>>       attach to IP addresses [that shouldn't be running servers.]
>>       It sure would have been nice to be able to list
>>       the addresses I wanted to accept connections on.
>Technically speaking, if you just use <VirtualHost> then Apache
>binds to *.80.  Which also means that you cannot then run another
>Apache with a different uid also using <VirtualHost>.
>Anyone care?  Anyone looked at patching Apache so you could list
>multiple BindAddress's (possibly in the <VirtualHost> section) to
>get around this?

I belive this may difficult to do portably.

What you would have to do is
1. Create a socket for every bound address.
2. Do a simultaneous accept on all the sockets.
   This can only be done by using select on all these sockets, waiting
   for a 'read' condition. Under Solaris at least, this indicates that
   that a connection is pending.

   Check the man page for accept on you system to see if it supports this.


View raw message