*BSD News Article 81644


Return to BSD News archive

Path: euryale.cc.adfa.oz.au!newshost.carno.net.au!harbinger.cc.monash.edu.au!munnari.OZ.AU!news.ecn.uoknor.edu!feed1.news.erols.com!howland.erols.net!vixen.cso.uiuc.edu!ais.net!news.sprintlink.net!news-chi-8.sprintlink.net!hermes.is.co.za!news
From: Inus Scheepers <inus@dockside.co.za>
Newsgroups: comp.unix.bsd.freebsd.misc
Subject: Re: Alias IP to a Network Card
Date: Mon, 28 Oct 1996 09:19:28 -0200
Organization: Animatica
Lines: 36
Message-ID: <327496C0.515E@dockside.co.za>
References: <3273DD7D.4CE7@sheltonlink.com>
NNTP-Posting-Host: ppp-2.dockside.co.za
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
X-Mailer: Mozilla 2.02 (Win16; I)
To: Butch Evans <butche@sheltonlink.com>

Butch Evans wrote:
> 
> I am trying to set up an alias for my webserver (Apache 1.1.1) under
> FreeBSD 2.1.  I have read the FAQ, and it said use
> 
> ifconfig_<interface> "inet <ip> netmask 0xffffffff alias"
> 
> This just killed my main IP...I have tried several of the other
> suggestions, and no luck. 

I got it to work (with about 5 aliases) by doing this:

If the first ip is x.y.z.1, (on ethernet) add another by

	ifconfig ed1 inet x.y.z.2 alias 0xffffffff

If you ping this and there's no response, this might get it up:
type the following two commands:

	ifconfig ed1 inet x.y.z.2 alias 0xffffff00

At which, I normally get "SIOCFG file exists", and again, go
	
	ifconfig ed1 inet x.y.z.2 alias 0xffffffff

But if I ping the alias, I sometimes get duplicate responses, which
go away if you repeat the last ifconfig command.

I've also noticed that aliases can only be added in strict order,
i.e. if you add x.y.z.10, you can't have anything below 10 afterwards.

I'm running 2.1-R, and I'd appreciate any information that could help
me get this fixed. Adding the aliases by hand after a reboot is no
fun after the 100th time!
--
Inus