Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 17 May 1998 17:25:57 -800
From:      walton@nordicdms.com (Dave Walton)
To:        Kurt Jones <kurt@woftam.com.au>, questions@FreeBSD.ORG
Subject:   Re: A couple of IP aliasing questions
Message-ID:  <19980518002557350.AAA155@mail.nordicdms.com>
In-Reply-To: <3.0.5.32.19980518074731.008fbc80@woftam.com.au>

next in thread | previous in thread | raw e-mail | index | archive | help
On 18 May 98 at 7:47, Kurt Jones wrote:

> When I set up an IP alias I enter the following:
> 
> ifconfig ed1 inet xxx.xxx.xxx.xxx netmask 255.255.255.240 alias
> route add -host xxx.xxx.xxx.xxx 127.0.0.1 0
> 
> This seems to work OK but after the first line it reports:
> 
> "ifconfig: ioctl (SIOCAIFADDR): File exists"
> 
> What does this mean and do I need to worry about it?


I've seen that error, too.  I noticed that the sample alias entry in 
/etc/rc.conf used a netmask of 255.255.255.255, so I changed my alias 
netmask to that.  Problem solved.  I don't know exactly what causes 
the error, and ifconfig(8) doesn't mention any requirement for the 
alias netmask (hint to docs people!), but that change makes the error 
go away.


> Also to automate this proceedure at startup, in which file should I make
> the IP aliasing entries?

Put:

  ifconfig_ed1_alias0="inet xxx.xxx.xxx.xxx netmask 0xffffffff"

into your /etc/rc.conf, just below the "ifconfig_ed1=" line.


I haven't messed with routes yet, but based on the example in 
"The Complete FreeBSD" you should put something like this in 
/etc/rc.conf:

  static_routes="route_woftam"
  route_woftam="-host xxx.xxx.xxx.xxx 127.0.0.1 0"


Dave

----------------------------------------------------------------------
Dave Walton                                                           
Webmaster, Postmaster                   Nordic Entertainment Worldwide
walton@nordicdms.com                          http://www.nordicdms.com
----------------------------------------------------------------------

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?19980518002557350.AAA155>