[Xorp-users] Is it possible to configure the NAT on XORP??

sanjeev kumar ror.sanjeev at gmail.com
Mon Sep 17 04:33:22 PDT 2007


Hi,

   I want to configure the NATing on XORP,but i do not know how ..could u
please suggest me some steps.

   One more thing : I want to test OSPF on two machines,both of them running
XORP router..instead of say..i want to connect two machines back to
back,then want to configure OSPF..Is it possible and provide me some
guidance.

Thanks...
Sanjeev

On 9/14/07, xorp-users-request at xorp.org <xorp-users-request at xorp.org> wrote:
>
> Send Xorp-users mailing list submissions to
>         xorp-users at xorp.org
>
> To subscribe or unsubscribe via the World Wide Web, visit
>         http://mailman.ICSI.Berkeley.EDU/mailman/listinfo/xorp-users
> or, via email, send a message with subject or body 'help' to
>         xorp-users-request at xorp.org
>
> You can reach the person managing the list at
>         xorp-users-owner at xorp.org
>
> When replying, please edit your Subject line so it is more specific
> than "Re: Contents of Xorp-users digest..."
>
>
> Today's Topics:
>
>    1. Re: Questions on OSPF (kristian at spritelink.net)
>    2. Re: Questions on OSPF (Atanu Ghosh)
>    3. Re: Questions on OSPF (kristian at spritelink.net)
>    4. Re: Questions on OSPF (Atanu Ghosh)
>    5. Re: Questions on OSPF (kristian at spritelink.net)
>    6. Re: Unreachable default route. (Pavlin Radoslavov)
>
>
> ----------------------------------------------------------------------
>
> Message: 1
> Date: Thu, 13 Sep 2007 20:52:03 +0200
> From: <kristian at spritelink.net>
> Subject: Re: [Xorp-users] Questions on OSPF
> To: atanu at ICSI.Berkeley.EDU
> Cc: xorp <xorp-users at xorp.org>
> Message-ID: <4cfe4c3ba67b049473b1d94a88052842 at Mail.SpriteLink.NET>
> Content-Type: text/plain; charset="UTF-8"
>
> On Thu, 13 Sep 2007 11:51:32 -0700, Atanu Ghosh <atanu at icsi.berkeley.edu>
> wrote:
> >>>>>> "Kristian" == Kristian Larsson <kristian at spritelink.net> writes:
> >
> >     Kristian> Hansi wrote:
> >     >> Hello All,
> >     >>
> >     >> I'm currently learning how to configure OSPFv2 on two XORP
> >     >> machines just to establish adjacency with one another. In a p2p
> >     >> link type, is it still necessary to explicitly set the 'neighbor'
> >     >> parameter of each machine before adjacency is established?
> >     >> Furthermore, would it be possible to set the router-id to its
> >     >> loopback address? instead of say.. the ip address of the
> >     >> interface on which ospf will be used?
> >
> >     Kristian> The neighbor command is only useful if you are using a
> >     Kristian> medium on which the routers cannot broadcast and thus
> >     Kristian> cannot discover each other.  If you're using ethernet
> >     Kristian> (which I presume from your NIC names) you do not have to
> >     Kristian> use the neighbor statements. I would advice configuring
> >     Kristian> the interfaces as link-type p2p as this avoids DR election
> >     Kristian> and unnecessary CPU load.
> >
> > I am fairly sure that it is necessary to use the neighbour statements.
>
> Are you serious?
> I haven't used the XORP code in quite some time now.. but at least I
> thought XORP implemented the OSPF standard. AFAIK, that includes being
> able
> to discover neighbors and turn up adjacencies to them. Is this not the
> case?
> Observe that he is running an Ethernet point-to-point link, ie, it is not
> a
> non-broadcast medium.
> Or are you saying that you can't do link-type p2p without configuring
> neighbours ?
>
>   -K
>
>
>
> ------------------------------
>
> Message: 2
> Date: Thu, 13 Sep 2007 12:18:42 -0700
> From: Atanu Ghosh <atanu at ICSI.Berkeley.EDU>
> Subject: Re: [Xorp-users] Questions on OSPF
> To: kristian at spritelink.net
> Cc: xorp <xorp-users at xorp.org>
> Message-ID: <6353.1189711122 at tigger.icir.org>
>
> >>>>> "kristian" == kristian  <kristian at spritelink.net> writes:
>
>     kristian> On Thu, 13 Sep 2007 11:51:32 -0700, Atanu Ghosh
>     kristian> <atanu at icsi.berkeley.edu> wrote:
>     >>>>>>> "Kristian" == Kristian Larsson <kristian at spritelink.net>
>     >>>>>>> writes:
>     >>
>     Kristian> Hansi wrote:
>     >> >> Hello All,
>     >> >>
>     >> >> I'm currently learning how to configure OSPFv2 on two XORP >>
>     >> machines just to establish adjacency with one another. In a p2p
>     >> >> link type, is it still necessary to explicitly set the
>     >> 'neighbor' >> parameter of each machine before adjacency is
>     >> established?  >> Furthermore, would it be possible to set the
>     >> router-id to its >> loopback address? instead of say.. the ip
>     >> address of the >> interface on which ospf will be used?
>     >>
>     Kristian> The neighbor command is only useful if you are using a
>     Kristian> medium on which the routers cannot broadcast and thus
>     Kristian> cannot discover each other.  If you're using ethernet
>     Kristian> (which I presume from your NIC names) you do not have to
>     Kristian> use the neighbor statements. I would advice configuring
>     Kristian> the interfaces as link-type p2p as this avoids DR election
>     Kristian> and unnecessary CPU load.
>
>     >>  I am fairly sure that it is necessary to use the neighbour
>     >> statements.
>
>     kristian> Are you serious?  I haven't used the XORP code in quite
>     kristian> some time now.. but at least I thought XORP implemented
>     kristian> the OSPF standard. AFAIK, that includes being able to
>     kristian> discover neighbors and turn up adjacencies to them. Is
>     kristian> this not the case?  Observe that he is running an Ethernet
>     kristian> point-to-point link, ie, it is not a non-broadcast medium.
>     kristian> Or are you saying that you can't do link-type p2p without
>     kristian> configuring neighbours ?
>
> If the link-type is set to "broadcast" then the neighbours will be
> correctly discovered. If the link-type is set to "p2p" (Point-to-point)
> or "p2m" (Point-to-multipoint) then it is necessary to configure the
> neighbours. It has been argued that it should not be necessary to
> configure the neighbours if the routers are connected via a true
> Point-to-point link, but unfortunately even in this case it is necessary
> to configure the neighbour.
>
>                Atanu.
>
>
>
> ------------------------------
>
> Message: 3
> Date: Thu, 13 Sep 2007 21:31:49 +0200
> From: <kristian at spritelink.net>
> Subject: Re: [Xorp-users] Questions on OSPF
> To: atanu at ICSI.Berkeley.EDU
> Cc: xorp <xorp-users at xorp.org>
> Message-ID: <93a9e57afbb58e1bf4d6d68740135f89 at Mail.SpriteLink.NET>
> Content-Type: text/plain; charset="UTF-8"
>
>
>
> On Thu, 13 Sep 2007 12:18:42 -0700, Atanu Ghosh <atanu at icsi.berkeley.edu>
> wrote:
> >>>>>> "kristian" == kristian  <kristian at spritelink.net> writes:
> >
> >     kristian> On Thu, 13 Sep 2007 11:51:32 -0700, Atanu Ghosh
> >     kristian> <atanu at icsi.berkeley.edu> wrote:
> >     >>>>>>> "Kristian" == Kristian Larsson <kristian at spritelink.net>
> >     >>>>>>> writes:
> >     >>
> >     Kristian> Hansi wrote:
> >     >> >> Hello All,
> >     >> >>
> >     >> >> I'm currently learning how to configure OSPFv2 on two XORP >>
> >     >> machines just to establish adjacency with one another. In a p2p
> >     >> >> link type, is it still necessary to explicitly set the
> >     >> 'neighbor' >> parameter of each machine before adjacency is
> >     >> established?  >> Furthermore, would it be possible to set the
> >     >> router-id to its >> loopback address? instead of say.. the ip
> >     >> address of the >> interface on which ospf will be used?
> >     >>
> >     Kristian> The neighbor command is only useful if you are using a
> >     Kristian> medium on which the routers cannot broadcast and thus
> >     Kristian> cannot discover each other.  If you're using ethernet
> >     Kristian> (which I presume from your NIC names) you do not have to
> >     Kristian> use the neighbor statements. I would advice configuring
> >     Kristian> the interfaces as link-type p2p as this avoids DR election
> >     Kristian> and unnecessary CPU load.
> >
> >     >>  I am fairly sure that it is necessary to use the neighbour
> >     >> statements.
> >
> >     kristian> Are you serious?  I haven't used the XORP code in quite
> >     kristian> some time now.. but at least I thought XORP implemented
> >     kristian> the OSPF standard. AFAIK, that includes being able to
> >     kristian> discover neighbors and turn up adjacencies to them. Is
> >     kristian> this not the case?  Observe that he is running an Ethernet
> >     kristian> point-to-point link, ie, it is not a non-broadcast medium.
> >     kristian> Or are you saying that you can't do link-type p2p without
> >     kristian> configuring neighbours ?
> >
> > If the link-type is set to "broadcast" then the neighbours will be
> > correctly discovered. If the link-type is set to "p2p" (Point-to-point)
> > or "p2m" (Point-to-multipoint) then it is necessary to configure the
> > neighbours. It has been argued that it should not be necessary to
> > configure the neighbours if the routers are connected via a true
> > Point-to-point link, but unfortunately even in this case it is necessary
> > to configure the neighbour.
>
> Okey, that "kinda" makes sense. I apparently forgot or missed the
> conversation on this.
> What I want to configure with link-type p2p is not whether or not the
> router should try to broadcast but if it should setup one of those virtual
> router thingys, hehe. I'm not very familiar with the terminology but (as
> you know) on a broadcast medium you first have a DR selection and all that
> and then you're gonna run your SPF. Since SPF can't handle the concept of
> a
> broadcast medium it creates a "virtual router" to represent the broadcast
> medium and connects all routers in that broadcast domain as adjacencies to
> the virtual router.
> When I configure 'isis network point-to-point' on a Cisco router I expect
> it to not setup one of these "virtual routers" in it's SPF topology. And
> this is different with XORP?
>
> Perhaps the increase in simplicity to the SPF topology that 'isis network
> point-to-point' brings is so small that it's negligable. I think SPF runs
> take in the order of 10ms or so for a network with a couple of hundred
> routers on a normal routing engine these days.
>
>   -K
>
>
>
> ------------------------------
>
> Message: 4
> Date: Thu, 13 Sep 2007 14:58:01 -0700
> From: Atanu Ghosh <atanu at ICSI.Berkeley.EDU>
> Subject: Re: [Xorp-users] Questions on OSPF
> To: kristian at spritelink.net
> Cc: xorp <xorp-users at xorp.org>
> Message-ID: <44891.1189720681 at tigger.icir.org>
>
> >>>>> "kristian" == kristian  <kristian at spritelink.net> writes:
>
>     kristian> On Thu, 13 Sep 2007 12:18:42 -0700, Atanu Ghosh
>     kristian> <atanu at icsi.berkeley.edu> wrote:
>     >>>>>>> "kristian" == kristian <kristian at spritelink.net> writes:
>     >>
>     kristian> On Thu, 13 Sep 2007 11:51:32 -0700, Atanu Ghosh
>     kristian> <atanu at icsi.berkeley.edu> wrote:
>     >> >>>>>>> "Kristian" == Kristian Larsson <kristian at spritelink.net>
>     >> >>>>>>> writes:
>     >> >>
>     Kristian> Hansi wrote:
>     >> >> >> Hello All,
>     >> >> >>
>     >> >> >> I'm currently learning how to configure OSPFv2 on two XORP
>     >> >> >> machines just to establish adjacency with one another. In a
>     >> p2p >> >> link type, is it still necessary to explicitly set the
>     >> >> 'neighbor' >> parameter of each machine before adjacency is >>
>     >> established?  >> Furthermore, would it be possible to set the >>
>     >> router-id to its >> loopback address? instead of say.. the ip >>
>     >> address of the >> interface on which ospf will be used?
>     >> >>
>     Kristian> The neighbor command is only useful if you are using a
>     Kristian> medium on which the routers cannot broadcast and thus
>     Kristian> cannot discover each other.  If you're using ethernet
>     Kristian> (which I presume from your NIC names) you do not have to
>     Kristian> use the neighbor statements. I would advice configuring
>     Kristian> the interfaces as link-type p2p as this avoids DR election
>     Kristian> and unnecessary CPU load.
>     >>  >> I am fairly sure that it is necessary to use the neighbour >>
>     >> statements.
>     >>
>     kristian> Are you serious?  I haven't used the XORP code in quite
>     kristian> some time now.. but at least I thought XORP implemented
>     kristian> the OSPF standard. AFAIK, that includes being able to
>     kristian> discover neighbors and turn up adjacencies to them. Is
>     kristian> this not the case?  Observe that he is running an Ethernet
>     kristian> point-to-point link, ie, it is not a non-broadcast medium.
>     kristian> Or are you saying that you can't do link-type p2p without
>     kristian> configuring neighbours ?
>
>     >>  If the link-type is set to "broadcast" then the neighbours will
>     >> be correctly discovered. If the link-type is set to "p2p"
>     >> (Point-to-point) or "p2m" (Point-to-multipoint) then it is
>     >> necessary to configure the neighbours. It has been argued that it
>     >> should not be necessary to configure the neighbours if the
>     >> routers are connected via a true Point-to-point link, but
>     >> unfortunately even in this case it is necessary to configure the
>     >> neighbour.
>
>     kristian> Okey, that "kinda" makes sense. I apparently forgot or
>     kristian> missed the conversation on this.  What I want to configure
>     kristian> with link-type p2p is not whether or not the router should
>     kristian> try to broadcast but if it should setup one of those
>     kristian> virtual router thingys, hehe. I'm not very familiar with
>     kristian> the terminology but (as you know) on a broadcast medium
>     kristian> you first have a DR selection and all that and then you're
>     kristian> gonna run your SPF. Since SPF can't handle the concept of
>     kristian> a broadcast medium it creates a "virtual router" to
>     kristian> represent the broadcast medium and connects all routers in
>     kristian> that broadcast domain as adjacencies to the virtual
>     kristian> router.  When I configure 'isis network point-to-point' on
>     kristian> a Cisco router I expect it to not setup one of these
>     kristian> "virtual routers" in it's SPF topology. And this is
>     kristian> different with XORP?
>
> Setting the link type to "broadcast" or "p2p" will both result in the
> hello packets being broadcast, the distinction is that if the link-type
> is set to "p2p" no DR election will be attempted. The XORP OSPF behaves
> as specified in the relevant RFCs and interoperates with other OSPF
> implementations, the only difference is in configuration of a "p2p"
> where we require the neighbour to be specified, which as I mentioned
> before should not strictly be necessary.
>
>     Atanu.
>
>
>
> ------------------------------
>
> Message: 5
> Date: Thu, 13 Sep 2007 23:51:06 +0200
> From: <kristian at spritelink.net>
> Subject: Re: [Xorp-users] Questions on OSPF
> To: atanu at ICSI.Berkeley.EDU
> Cc: xorp <xorp-users at xorp.org>
> Message-ID: <5f7ec0f76565b4e68ed2457fdf8df3b8 at Mail.SpriteLink.NET>
> Content-Type: text/plain; charset="UTF-8"
>
> On Thu, 13 Sep 2007 14:58:01 -0700, Atanu Ghosh <atanu at icsi.berkeley.edu>
> wrote:
> >>>>>> "kristian" == kristian  <kristian at spritelink.net> writes:
> >
> >     kristian> On Thu, 13 Sep 2007 12:18:42 -0700, Atanu Ghosh
> >     kristian> <atanu at icsi.berkeley.edu> wrote:
> >     >>>>>>> "kristian" == kristian <kristian at spritelink.net> writes:
> >     >>
> >     kristian> On Thu, 13 Sep 2007 11:51:32 -0700, Atanu Ghosh
> >     kristian> <atanu at icsi.berkeley.edu> wrote:
> >     >> >>>>>>> "Kristian" == Kristian Larsson <kristian at spritelink.net>
> >     >> >>>>>>> writes:
> >     >> >>
> >     Kristian> Hansi wrote:
> >     >> >> >> Hello All,
> >     >> >> >>
> >     >> >> >> I'm currently learning how to configure OSPFv2 on two XORP
> >     >> >> >> machines just to establish adjacency with one another. In a
> >     >> p2p >> >> link type, is it still necessary to explicitly set the
> >     >> >> 'neighbor' >> parameter of each machine before adjacency is >>
> >     >> established?  >> Furthermore, would it be possible to set the >>
> >     >> router-id to its >> loopback address? instead of say.. the ip >>
> >     >> address of the >> interface on which ospf will be used?
> >     >> >>
> >     Kristian> The neighbor command is only useful if you are using a
> >     Kristian> medium on which the routers cannot broadcast and thus
> >     Kristian> cannot discover each other.  If you're using ethernet
> >     Kristian> (which I presume from your NIC names) you do not have to
> >     Kristian> use the neighbor statements. I would advice configuring
> >     Kristian> the interfaces as link-type p2p as this avoids DR election
> >     Kristian> and unnecessary CPU load.
> >     >>  >> I am fairly sure that it is necessary to use the neighbour >>
> >     >> statements.
> >     >>
> >     kristian> Are you serious?  I haven't used the XORP code in quite
> >     kristian> some time now.. but at least I thought XORP implemented
> >     kristian> the OSPF standard. AFAIK, that includes being able to
> >     kristian> discover neighbors and turn up adjacencies to them. Is
> >     kristian> this not the case?  Observe that he is running an Ethernet
> >     kristian> point-to-point link, ie, it is not a non-broadcast medium.
> >     kristian> Or are you saying that you can't do link-type p2p without
> >     kristian> configuring neighbours ?
> >
> >     >>  If the link-type is set to "broadcast" then the neighbours will
> >     >> be correctly discovered. If the link-type is set to "p2p"
> >     >> (Point-to-point) or "p2m" (Point-to-multipoint) then it is
> >     >> necessary to configure the neighbours. It has been argued that it
> >     >> should not be necessary to configure the neighbours if the
> >     >> routers are connected via a true Point-to-point link, but
> >     >> unfortunately even in this case it is necessary to configure the
> >     >> neighbour.
> >
> >     kristian> Okey, that "kinda" makes sense. I apparently forgot or
> >     kristian> missed the conversation on this.  What I want to configure
> >     kristian> with link-type p2p is not whether or not the router should
> >     kristian> try to broadcast but if it should setup one of those
> >     kristian> virtual router thingys, hehe. I'm not very familiar with
> >     kristian> the terminology but (as you know) on a broadcast medium
> >     kristian> you first have a DR selection and all that and then you're
> >     kristian> gonna run your SPF. Since SPF can't handle the concept of
> >     kristian> a broadcast medium it creates a "virtual router" to
> >     kristian> represent the broadcast medium and connects all routers in
> >     kristian> that broadcast domain as adjacencies to the virtual
> >     kristian> router.  When I configure 'isis network point-to-point' on
> >     kristian> a Cisco router I expect it to not setup one of these
> >     kristian> "virtual routers" in it's SPF topology. And this is
> >     kristian> different with XORP?
> >
> > Setting the link type to "broadcast" or "p2p" will both result in the
> > hello packets being broadcast, the distinction is that if the link-type
> > is set to "p2p" no DR election will be attempted.
>
> Alright, just as I expected.
>
> > The XORP OSPF behaves
> > as specified in the relevant RFCs and interoperates with other OSPF
> > implementations, the only difference is in configuration of a "p2p"
> > where we require the neighbour to be specified, which as I mentioned
> > before should not strictly be necessary.
>
> Okey, not what I expected. Why is it so? Just lack of time to do the
> actual
> implementation (although I don't see how it would actually be more code
> than it is today) or has there been a policy decision against it?
>
>   -K
>
>
>
> ------------------------------
>
> Message: 6
> Date: Thu, 13 Sep 2007 16:11:57 -0700
> From: Pavlin Radoslavov <pavlin at icir.org>
> Subject: Re: [Xorp-users] Unreachable default route.
> To: Ben Greear <greearb at candelatech.com>
> Cc: xorp-users at xorp.org, Pavlin Radoslavov <pavlin at icir.org>,   Tim
>         Durack <tdurack at gmail.com>
> Message-ID: <200709132312.l8DNBvsa040733 at possum.icir.org>
>
> Ben Greear <greearb at candelatech.com> wrote:
>
> > Pavlin Radoslavov wrote:
> >
> > > You could use the following configuration on Linux to configure a
> > > discard interface and a static route that is blackhole:
> > >
> > > interfaces {
> > >     interface my_discard {
> > >         discard: true
> > >         vif my_discard {
> > >         }
> > >     }
> > > }
> >
> > [snip]
> >
> > Ok, this does indeed create a blackhole route.  But, it seems this will
> just
> > silently eat packets.  What I really want is unreachable, which will
> return
>   ~~~~~~~~~~~~~~~~~~~~
>
> Correct. This is the definition of "blackhole" :)
>
> > the proper ICMP packet saying the destination is unreachable.
> >
> > Any idea how hard it would be to add this functionality?
>
> You need to install a different type of route in the kernel which I
> believe in Linux is RTN_UNREACHABLE instead of RTN_BLACKHOLE.
> However, XORP doesn't support such routes.
> You could try experimenting with such routes by replacing all
> references (I counted two references) of RTN_BLACKHOLE with
> RTN_UNREACHABLE inside file
> fea/data_plane/fibconfig/fibconfig_entry_set_netlink_socket.cc
>
> This is not the right solution, but allows you to play with such
> routes.
>
> Just curious, could you describe your particular scenario you have
> that requires installing RTN_UNREACHABLE routes.
>
> > In the meantime, I'll work on a patch that makes the 'static' priority
> > configurable with an environment variable.
>
> I should tell you upfront that configurable admin distances in RIB
> has been on our TODO list for quite some time. However it is not
> trivial if we want to do it properly by taking into account various
> considerations.
> E.g., one of the goals is to be able to configure the priorities (on
> the fly) inside the XORP config file.
>
> Hence, most likely we won't use a solution that is based on
> setting an environmental variable (or something like this).
> In other words, don't be offended if your patch is not applied to
> the CVS.
> Though, if I were in your position I would use such shortcut in my
> local XORP copy.
>
> Regards,
> Pavlin
>
> > Thanks,
> > Ben
> >
> > --
> > Ben Greear <greearb at candelatech.com>
> > Candela Technologies Inc  http://www.candelatech.com
> >
> > _______________________________________________
> > Xorp-users mailing list
> > Xorp-users at xorp.org
> > http://mailman.ICSI.Berkeley.EDU/mailman/listinfo/xorp-users
>
>
>
> ------------------------------
>
> _______________________________________________
> Xorp-users mailing list
> Xorp-users at xorp.org
> http://mailman.ICSI.Berkeley.EDU/mailman/listinfo/xorp-users
>
>
> End of Xorp-users Digest, Vol 18, Issue 15
> ******************************************
>



-- 
Efforts may fail,But don't Fail to make efforts.
---------
Sanjeev Kumar
Project Engineer
CDAC(Formerly NCST)
Juhu,Mumbai-400049
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mailman.ICSI.Berkeley.EDU/pipermail/xorp-users/attachments/20070917/54b8c6f1/attachment-0001.html 


More information about the Xorp-users mailing list