[Xorp-users] wanted: OSPF metrics per neighbor. can vif help?

Kristian Larsson kristian@juniks.net
Thu, 10 Nov 2005 18:07:04 +0100


On Thu, Nov 10, 2005 at 11:39:55AM -0500, Nick Feamster wrote:
> On Thu, Nov 10, 2005 at 05:15:27PM +0100, Kristian Larsson wrote:
> > On Thu, Nov 10, 2005 at 01:48:04AM -0500, Nick Feamster wrote:
> > > On Thu, Nov 10, 2005 at 06:25:03AM +0100, Kristian Larsson wrote:
> > > > > I understand what the RFC says, and sticking to standards seems like a
> > > > > good idea in general.  If I could create multiple virtual interfaces
> > > > > (vifs) on top of a single phyiscal interface (e.g., one vif per
> > > > > neighbor) and subsequently set the interface cost per vif, then would
> > > > > that not comply with the standard and give me the functionality we
> > > > > want/need?
> > > > Even if you could create several interfaces it
> > > > would not do you much good. How would you separate
> > > > the traffic between the interfaces?
> > > > I beleive it to be very difficult.
> > > 
> > > Easy: each vif would have a separate IP address on which traffic could
> > > be demuxed.
> > If you want separate ip adresses in different this
> > should be possible to solve via alias interface.
> > On linux:
> > ifconfig eth0 1.1.1.1 netmask 255.255.255.0
> > ifconfig eth0:1 2.2.2.2 netmask 255.255.255.0
> > though if you wan't them all in the same subnet it
> > would be hard. This was what I assumed but I
> > suppose I'm wrong.
> 
> Yes, IP aliasing is the functionality I was referring to; I want to know
> how to do this in *XORP*.  I don't want to do this in the kernel
> because:
You are going to do it in the kernel whether you
like it or not. XORP merely instructs the kernel
to set up another ip alias. Doing it via XORP is
no different from doing it via ifconfig, iproute2
or something else.
However the example given above does not work.
XORP does not seem to be able to handle alias
interfaces such as eth0:1...
> 
> 1. This is not possible on planetlab.
What is planetlab and why is it not possible?
> 2. Even if it were, I want to configure vifs that correspond to those
>    aliases.  This does not seem possible since the vif name would match the
>    physical interface name.
That was why I proposed the eth0:1 since then
creates another virtual interface, though as
stated above it does not work :/
> 
> Back to my original question and what I am trying to achieve:
> 
> Given one physical interface, can I configure multiple vifs and set an
> interface-cost per vif?  I don't care if all vifs or what have you have
> the same IP address, even, as long as I can set different OSPF interface
> costs for each one.
Vifs are as of today nothing more than internals
to XORP, you can't actually do anything with them.
You have to configure and can only configure _one_
vif per interface and thus to allow what you are
currently looking for ie setting cost per neighbor
you would need several interfaces. This could be
solved in at least two ways:
1. setup alias interfaces (eth0:1)
 As described above, XORP unfortunately does not
 support this :( so you're kinda down to:
2. one VLAN interface to each router
 this is however a pain in the a** since you would
 essentially have to full-mesh your ospf routers
 if you wan't to be able to set cost on each.

you could always tunnel or do something with black
magic... but basically you're full meshing with
vlans or waiting for per-neihbor cost in xorp.

Why is it you want to set different costs per
neighbor?

Hope it helps :)

   Kristian.