Virtual hosts/virtual IP

Virtual hosts/virtual IP

Post by Simon Richards » Fri, 18 Oct 1996 04:00:00



Apologies if this is a commonly asked question.

We would like to have one machine respond to maybe a dozen IP addresses, so
that we can run virtual websites.  The machine we would like to do this feat
is running FreeBSD 2.1, and connected via an ethernet card.  What we don't
want to do is hang a dozen serial/ethernet cards off it, so what we want is
to allocate a block of addresses to the one card.

I believe we need something called a "virtual interface".  Does such a beast
exist for FreeBSD?  (And if it doesn't, can anyone offer pointers on writing
one?  I know C pretty well, and have written character device drivers for
386BSD and MS-DOG.)

Our newsfeed is really flaky, so please copy to E-mail.

Simon

------------------------------------------------------------------------
Simon Richardson                One Chip Solutions
Network Administrator           85, St Judes Road        
                                Englefield Green
                                EGHAM
                                Surrey TW20 ODF
                                ENGLAND        

 
 
 

Virtual hosts/virtual IP

Post by Ken Bigelo » Fri, 18 Oct 1996 04:00:00



> Apologies if this is a commonly asked question.

> We would like to have one machine respond to maybe a dozen IP addresses, so
> that we can run virtual websites.  The machine we would like to do this feat
> is running FreeBSD 2.1, and connected via an ethernet card.  What we don't
> want to do is hang a dozen serial/ethernet cards off it, so what we want is
> to allocate a block of addresses to the one card.

> I believe we need something called a "virtual interface".  Does such a beast
> exist for FreeBSD?  (And if it doesn't, can anyone offer pointers on writing
> one?  I know C pretty well, and have written character device drivers for
> 386BSD and MS-DOG.)

> Our newsfeed is really flaky, so please copy to E-mail.

> Simon

[CC sent]

You're talking here about aliasing, which FreeBSD does with no problem.
The Apache webserver also runs virtual hosts nicely. Further info on the
Apache end from http://www.apache.org/ .
--
Ken

Are you interested in   |
byte-sized education    |   http://www.play-hookey.com
over the Internet?      |

 
 
 

Virtual hosts/virtual IP

Post by Nick Say » Sat, 19 Oct 1996 04:00:00



>Apologies if this is a commonly asked question.
>We would like to have one machine respond to maybe a dozen IP addresses, so
>that we can run virtual websites.  The machine we would like to do this feat
>is running FreeBSD 2.1, and connected via an ethernet card.  What we don't
>want to do is hang a dozen serial/ethernet cards off it, so what we want is
>to allocate a block of addresses to the one card.

RTFM: ifconfig - the part that talks about 'alias'.

Quote:>I believe we need something called a "virtual interface".  Does such a beast
>exist for FreeBSD?

Short answer: yes, it's built in to the OS.

Longer answer: No, FreeBSD doesn't support virtual interfaces because it
doesn't need them. It is able to handle multiple IP addresses per
Ethernet interface without any trouble.

--


+1 408 249 9630, log in as 'guest' | What goes around, comes around.
URL: http://www.kfu.com/~nsayer/   |

 
 
 

Virtual hosts/virtual IP

Post by Craig Shrimpt » Sun, 20 Oct 1996 04:00:00



> Longer answer: No, FreeBSD doesn't support virtual interfaces because it
> doesn't need them. It is able to handle multiple IP addresses per
> Ethernet interface without any trouble.

How do you easily see the aliased interfaces?  Ifconfig -a only shows the
"real" one.  Linux has a nice feature where ifconfig -a shows them as
eth:0, eth:1, eth:2, ....

Anything like that planned for FBSD?

-Craig

 
 
 

Virtual hosts/virtual IP

Post by Dan Busaro » Mon, 21 Oct 1996 04:00:00



> How do you easily see the aliased interfaces?  Ifconfig -a only shows the
> "real" one.  Linux has a nice feature where ifconfig -a shows them as
> eth:0, eth:1, eth:2, ....

netstat -i
 
 
 

Virtual hosts/virtual IP

Post by J Wuns » Mon, 21 Oct 1996 04:00:00



> How do you easily see the aliased interfaces?  Ifconfig -a only shows the
> "real" one.

netstat -i worked all the time.  ifconfig -a works now (2.2-current).

--
cheers, J"org


Never trust an operating system you don't have sources for. ;-)

 
 
 

1. Apache 1.3b2: Default Host and all virtual hosts serve only first virtual hosts pages?

Hello.

Have been running 1.2b8 for a intranet and decided to move upto 1.3b2. I
have several name based virtual hosts that have been working under
1.2b8. After compiling and installing 1.3b2 my virtual hosts do not
work. In fact what happens is that even though DocumentRoot and default
server name is different, eg: www.serverA.net pointing to /www/default,
Apache 1.3b2 will always take me to the first defined virtual host as if
it's locked to it no matter what virtual host I try to browse. What
gives? Please post and E-Mail.

In /etc/hosts for my machines IP address I have

A.B.C.D         www.default.net www.virtA.net www.virtB.net

In ../conf/httpd.conf I have;

<VirtualHost www.virtA.net>

DocumentRoot /usr/local/www/virtA
ServerName www.virtA.net
ErrorLog logs/virtA.error.log
TransferLog logs/virtA.access.log
</VirtualHost>

<VirtualHost www.virtB.net>

DocumentRoot /usr/local/www/virtB
ServerName www.virtB.net
ErrorLog logs/virtB.error.log
TransferLog logs/virtB.access.log
</VirtualHost>

--

2. Microsoft Mouse

3. FrontPage virtual hosting, removal or reset of virtual host

4. USB DDK 0.9 available for downloading

5. : How to prevent one named virtual host from "seeing" another virtual hosts files ?

6. PPP setup: 'resolv.conf' in RH 6.0

7. Mixing Apache Name Based Virtual Hosts and SSL Virtual Host

8. Need shell scripting help

9. For Discussion: web virtual hosting vs mail virtual hosting

10. Name Based Virtual Hosting - Unable to access Virtual domain from IE/Lynx

11. Virtual interface/Virtual web hosting

12. Virtual Server vs. Virtual Host

13. Virtual Servers: WWW, FTP, POP, SMTP, SSL capable (not simply Virtual Hosting)