[Gllug] adding multiple IP's to one interface?

Bruce Richardson itsbruce at uklinux.net
Thu Nov 15 13:09:52 UTC 2001


On Thu, Nov 15, 2001 at 01:08:13AM -0000, Steve Nicholson wrote:
> How do I add more than one IP address to eth0?

How terribly profligate of you, didn't you know there's a shortage;)

I use the iproute suite for this.

	ip addr add 10.0.0.2/24 brd + dev eth0 alias eth0:alias1


does the business.  The iproute tools are great, let you set up all
kinds of clever things (policy routing etc) but some features require
you to have configured the kernel as an advanced router.

(Note: if you also run ipx on a network then you need to make sure each
extra ip address is aliased to the same name as the interface - dev eth0
alias eth0 in this case - or bad things happen).


-- 
Bruce

You can fool some of the people all the time, you can fool all of
the people some of the time but you can never fool your mother.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 261 bytes
Desc: not available
URL: <http://mailman.lug.org.uk/pipermail/gllug/attachments/20011115/e9d855c4/attachment.pgp>


More information about the GLLUG mailing list