# quagga rip problem

## CyberCrash

Hello,   :Very Happy: 

Traying to set up rip dynamic routing on x86 pc and linksys wrt54gs with OpenWRT frimware. 

x86 IP: 10.61.0.2, 10.61.1.2

wrt IP: 10.61.0.50, 10.61.2.1  

10.61.1.X  ---  x86 --- 10.61.0.X ----- linksys -- 10.61.2.X

on x86:

```

Calculating dependencies... done!

[ebuild   R   ] net-misc/quagga-0.98.6-r1  USE="ipv6 pam -bgpclassless -fix-connected-rt -multipath -ospfapi -realms -snmp -tcp-zebra -tcpmd5" 0 kB

```

wrt: quagga-ripd - 0.98.4-1

zebra.conf on x86

```

! -*- zebra -*-

!

! zebra sample configuration file

!

! $Id: zebra.conf.sample,v 1.1.1.1 2002/12/13 20:15:30 paul Exp $

!

hostname ngrouter1

password zebra

enable password zebra

!

! Interface's description.

!

!interface lo

! description test of desc.

!

interface eth0

 multicast

interface ath0

 multicast

log file /var/log/quagga/zebra.log

!log stdout

```

ripd.conf on x86

```

! -*- rip -*-

!

! RIPd sample configuration file

!

! $Id: ripd.conf.sample,v 1.1.1.1 2002/12/13 20:15:30 paul Exp $

!

hostname ngrouter1

password zebra

enable password zebra

!

! debug rip events

! debug rip packet

!

router rip

network 10.61.0.0/24

network 10.61.1.0/24

! network eth0

! route 10.0.0.0/8

! distribute-list private-only in eth0

redistribute static

redistribute connected

distribute-list private-only in eth0

distribute-list private-only out eth0

distribute-list private-only in ath0

distribute-list private-only out ath0

access-list private-only permit 10.61.0.0/16

access-list private-only deny any

!

log file /var/log/quagga/rip.log

!

!log stdout

```

zebra.conf on wrt

```

! -*- zebra -*-

!

hostname openwrt

password zebra

enable password zebra

!

! Interface's description.

!

interface vlan0

 multicast

interface eth0

 multicast

!log file /var/log/quagga/zebra.log

!log stdout

```

ripd.conf on wrt

```

! -*- rip -*-

!

! RIPd sample configuration file

!

! $Id: ripd.conf.sample,v 1.1.1.1 2002/12/13 20:15:30 paul Exp $

!

hostname openwrt

password zebra

enable password zebra

!

! debug rip events

! debug rip packet

!

router rip

network 10.61.0.0/24

network 10.61.2.0/24

neighbor 10.61.0.2

! network eth0

! route 10.0.0.0/8

! distribute-list private-only in eth0

redistribute static

redistribute connected

distribute-list private-only in eth1

distribute-list private-only out eth1

distribute-list private-only in vlan0

distribute-list private-only out vlan0

access-list private-only permit 10.61.0.0/16

access-list private-only deny any

!

!log file /var/log/quagga/rip.log

!

!log stdout

```

Routes from my wrt are not shared to x86 machine, but wrt got x86 routes. 

tcpdump on x86:

```

ng-router1 cyber # tcpdump -n -s 1500 "udp port 520"

tcpdump: verbose output suppressed, use -v or -vv for full protocol decode

listening on eth0, link-type EN10MB (Ethernet), capture size 1500 bytes

19:51:13.109995 IP 10.61.0.50.520 > 224.0.0.9.520: RIPv2, Request, length: 24

19:51:14.026031 IP 10.61.0.50.520 > 224.0.0.9.520: RIPv2, Response, length: 24

19:51:14.026891 IP 10.61.0.50.520 > 10.61.0.2.520: RIPv2, Response, length: 24

19:51:36.438916 IP 10.61.0.2.520 > 224.0.0.9.520: RIPv2, Response, length: 24

19:51:44.038884 IP 10.61.0.50.520 > 224.0.0.9.520: RIPv2, Response, length: 24

19:51:44.039350 IP 10.61.0.50.520 > 10.61.0.2.520: RIPv2, Response, length: 24

```

I have spent many hours changing zebra.conf and ripd.conf but x86 pc cant get wrt"s routes.   :Shocked:   What have I done wrong ?

----------

## jvale

I don't have much experience with quagga (and the bit I have is with ospf and not rip), so I might be putting my foot in my mouth.  :Razz: 

Anyway, checking the conf's I had here, I noticed something that differed from the setup I once did. Shouldn't you specify the IP addresses of the interfaces in zebra.conf? Something like:

```

interface eth0

 ip address 10.61.1.2/24

interface ath0

 ip address 10.61.0.2/24 

```

----------

## jeroenr

 *CyberCrash wrote:*   

> Hello,  
> 
> Traying to set up rip dynamic routing on x86 pc and linksys wrt54gs with OpenWRT frimware. 
> 
> [...]
> ...

 

I have built a similar configuration using UserModeLinux and put your configs in and it works like a charm...

This is what I have:

(I have changed the IP addresses, because I have a script that automagically creates UML configs based on IP adresses)

router1:eth0:172.16.32.2

router1:eth1:172.16.33.2

router2:eth0:172.16.32.50

router2:eth1:172.16.34.1

Router 1:

```

router1# sh run

Building configuration...

Current configuration:

!

log stdout

!

interface dummy0

 ipv6 nd suppress-ra

!

interface eql

 ipv6 nd suppress-ra

!

interface eth0

 ipv6 nd suppress-ra

 multicast

!

interface eth1

 ipv6 nd suppress-ra

 multicast

!

interface eth2

 ipv6 nd suppress-ra

!

interface fa0

 ipv6 nd suppress-ra

!

interface ip6tnl0

 ipv6 nd suppress-ra

!

interface lo

!

interface sit0

 ipv6 nd suppress-ra

!

router rip

 redistribute connected

 redistribute static

 network 172.16.32.0/24

 network 172.16.33.0/24

 distribute-list private-only in eth0

 distribute-list private-only out eth0

 distribute-list private-only in eth1

 distribute-list private-only out eth1

!

access-list private-only permit 172.16.0.0/16

!

ip forwarding

!

line vty

!

router1# sh ip ro

Codes: K - kernel route, C - connected, S - static, R - RIP, O - OSPF,

       I - ISIS, B - BGP, > - selected route, * - FIB route

C>* 127.0.0.0/8 is directly connected, lo

C>* 172.16.32.0/24 is directly connected, eth0

C>* 172.16.33.0/24 is directly connected, eth1

R>* 172.16.34.0/24 [120/2] via 172.16.32.50, eth0, 00:04:44

router1# sh ver

Quagga 0.99.1 ().

Copyright 1996-2005 Kunihiro Ishiguro, et al.

```

and router2:

```

router2# sh run

Building configuration...

Current configuration:

!

log stdout

!

interface dummy0

 ipv6 nd suppress-ra

!

interface eql

 ipv6 nd suppress-ra

!

interface eth0

 ipv6 nd suppress-ra

 multicast

!

interface eth1

 ipv6 nd suppress-ra

 multicast

!

interface eth2

 ipv6 nd suppress-ra

interface fa0

 ipv6 nd suppress-ra

!

interface ip6tnl0

 ipv6 nd suppress-ra

!

interface lo

!

interface sit0

 ipv6 nd suppress-ra

!

router rip

 redistribute connected

 redistribute static

 network 172.16.32.0/24

 network 172.16.34.0/24

 distribute-list private-only in eth0

 distribute-list private-only out eth0

 distribute-list private-only in eth1

 distribute-list private-only out eth1

!

access-list private-only permit 172.16.0.0/16

access-list private-only deny any

!

ip forwarding

!

line vty

!

router2# sh ip ro

Codes: K - kernel route, C - connected, S - static, R - RIP, O - OSPF,

       I - ISIS, B - BGP, > - selected route, * - FIB route

C>* 127.0.0.0/8 is directly connected, lo

C>* 172.16.32.0/24 is directly connected, eth0

R>* 172.16.33.0/24 [120/2] via 172.16.32.2, eth0, 00:06:39

C>* 172.16.34.0/24 is directly connected, eth1

router2# sh ver

Quagga 0.99.1 ().

Copyright 1996-2005 Kunihiro Ishiguro, et al.

```

Both are running on a Debian system inside UML, which in turn is running on my Gentoo system. (I don't run Gentoo inside UML because it costs a lot of time to compile 25 systems... all competing for one Pentium IV CPU  :Wink:  )[/code]

----------

