Date: Wed, 12 Dec 2001 11:48:35 -0800 From: "Crist J. Clark" <cristjc@earthlink.net> To: =?iso-8859-1?Q?Boris_K=F6ster_?= <koester@x-itec.de> Cc: freebsd-questions@FreeBSD.ORG Subject: Re: ifconfig alias question Message-ID: <20011212114834.B487@gohan.cjclark.org> In-Reply-To: <3C160DBF.10471.35E5BD9@localhost>; from koester@x-itec.de on Tue, Dec 11, 2001 at 01:44:31PM %2B0100 References: <3C160DBF.10471.35E5BD9@localhost>
next in thread | previous in thread | raw e-mail | index | archive | help
On Tue, Dec 11, 2001 at 01:44:31PM +0100, Boris Köster wrote: > I have a question *g > > Interface: ed0 192.168.0.99/24 255.255.255.0 > > I want to add additional IP to the interface, and this works: > > ifconfig ed0 inet alias 192.168.0.98 netmask 255.255.255.255 > > Question: why netmask 255.255.255.255 instead of 255.255.255.0? Let's say you gave both 192.168.0.98 and 192.168.0.99 the same netmask of 0xffffff00. You decide to fire up telnet/ssh/ftp/whatever to connect to 192.168.0.50. You don't tell the application specifically which IP address to use as a source address. Which should the operating system chose for you? There is no good choice, both addresses are equally good choices. Computers don't like ambigious situations. When you specify a 0xffffffff netmask, suddenly that address is no longer a good choice. Now we have a clear winner and the world is a much happier place. -- Crist J. Clark cjclark@alum.mit.edu 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?20011212114834.B487>