[Xorp-users] xorp with click and RIP

Pavlin Radoslavov pavlin at icir.org
Thu Dec 6 12:39:47 PST 2007


>   I'm trying to set up a xorp/click configuration which 
> runs RIP. I have RIP working with xorp, but when I enable 
> the user click forwarding path, I get strange behavior. If 
> I 'duplicate-routes-to-kernel' everything works fine. 
> However, when I don't duplicate routes-to-kernel, the 
> routes still show up in xorpsh (show route table ipv4 
> unicast rip/final), but if I ping any of those addresses, 
> I get 'no route to host'. Xorp also cannot send RIP 
> updates, getting the send_from_multicast_if failed.

First the (hopefully) easy part:
As you know already, FreeBSD requires to have a matching route
(e.g., 0.0.0.0/0) in the unicast forwarding table in the kernel to
be able to originate multicast packets. If you use XORP to configure
the 0.0.0.0/0 static route, and if "duplicate-routes-to-kernel" is
disabled, this route won't reach the kernel.
Hence, to get around this problem you should add 0.0.0.0/0 to the
kernel by hand before starting XORP.

> The reason I want to turn 'duplicate-routes-to-kernel' 
> off, is so that I can check that the click forwarding path 
> is working.
> 
> I already added a static route 0.0.0.0/0 to an attached 
> interface, and put "multicast_host="YES"" in my rc.conf.
> I'm running BSD6.2, and my xorp config is below. The click 
> config I'm running is simply the one generated by 
> 'make-ip-conf.pl' which is a basic IP router
> Any ideas why xorp sees the routes in xorpsh but can't use 
> them?

If you are to use your own static config with make-ip-conf.pl, it
will be safer if you also modify the sample
"/usr/local/fea/xorp_fea_click_config_generator" generator to
unconditionally return that configuration. FYI, the config generator
is automatically called by XORP whenenever something in the
interface configuration changes, so on startup it might actually be
overwriting your own static config.

Once you eliminate the config generation factor, then you need to
investigate whether userland Click itself is working as
expected. For that purpose I'd recommend to start userland Click by
hand (without XORP), and then manually configure it with your static
config (including the routes that should be generated by RIP).
Then do the ping test to see whether userland Click on its own is
fine.
One thing to have in mind is that the ping packets originated on the
router running Click might not actually be processed by Click: such
packets will lookup the unicast forwarding table in the kernel, and
therefore fail. Hence, you might want to run ping on a machine
directly connected to the router running Click.

Hopefully the above tests will narrow the problem.

Regards,
Pavlin

P.S. In your config you don't need the plumbing/mfea4 and mfea6
sections.


> 
> interfaces{
>          restore-original-config-on-shutdown: false
>          interface xl0 {
>                  description: "from 10.0.2"
>                  disable: false
>                  vif xl0 {
>                          disable: false
>                          address 10.0.2.33 {
>                                  prefix-length: 24
>                                  broadcast: 10.0.2.255
>                                  disable: false
>                          }
>                  }
>          }
>          interface xl1 {
>                  description: "to 10.0.3"
>                  disable: false
>                  vif xl1 {
>                          disable: false
>                          address 10.0.3.33 {
>                                  prefix-length: 24
>                                  broadcast: 10.0.3.255
>                                  disable: false
>                          }
>                  }
>          }
> } /* </interfaces> */
> 
> fea{
>          unicast-forwarding4 {
>                  disable: true
>          }
> 
>          unicast-forwarding6 {
>                  disable: true
>          }
> 
>          click {
>                  disable: false  /*run autogenerated 
> config from /conf/make-ip-conf.pl*/
>                  duplicate-routes-to-kernel: true
> 
>                  kernel-click{
>                          disable: true
>                  }
> 
>                  user-click{
>                          disable: false
>                          command-file: 
> "/usr/local/bin/click"
>                          command-extra-arguments: "-R"
>                          command-execute-on-startup: true
>                          startup-config-file: 
> "/usr/local/xorp/iprouter_auto.click"
>                          user-click-config-generator-file: 
> "/usr/local/fea/xorp_fea_click_config_generator"
>                  }
>          }
> } /* </fea> */
> plumbing{
>          mfea4 {
>                  disable: true
>          }
>          mfea6{
>                  disable: true
>          }
> }
> policy {
>          /*Describe connected routes for redistribution*/
>          policy-statement connected {
>                  term export {
>                          from {
>                                  protocol: "connected"
>                          }
>                  }
>          }
> }
> 
> protocols {
>          static{
>                  route 0.0.0.0/0{
>                          next-hop: 10.0.2.22
>                          metric: 1
>                  }
>          }
>          rip {
>                  export: "connected"
> 
>                  /*run on both interfaces*/
>                  interface xl0 {
>                          vif xl0 {
>                                  address 10.0.2.33 {
>                                          disable: false
>                                  }
>                          }
>                  }
>                  interface xl1 {
>                          vif xl1 {
>                                  address 10.0.3.33 {
>                                          disable: false
>                                  }
>                          }
>                  }
>          } /* </rip> */
> } /* </protocols>*/
> 
> 
> 
> -Robbie
> 
> _______________________________________________
> Xorp-users mailing list
> Xorp-users at xorp.org
> http://mailman.ICSI.Berkeley.EDU/mailman/listinfo/xorp-users



More information about the Xorp-users mailing list