cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
763
Views
0
Helpful
3
Replies

BGP Local Pref. problem

David Kondicz
Level 1
Level 1

Hi all,

I have iBGP connection betwen 2 cityes.

R1 is connecet to peering centre and has an default route. R2 is in my town. Betwen R1 and R2 are 2 lines with different capacity.

From R2 i am propagating 2 subnets on main (1st) line: 192.168.1.0 / 25  Loc.pref 200 and 192.168.1.128 / 25 Loc.pref 300

Second "backup" line  is propagating 192.168.1.0 / 25  Loc.pref 300 and 192.168.1.128 / 25 Loc.pref 200

If i am making tracert from R1 it works great. I mean "load balancing"

But i i make traceroute behind R1, loadbalancing it is not working , all trafic is going throught main line for both subnets.

Show on R1:

ip bgp neighbout (ip) route i see all routes that I advertise from R2 to R1

but if i run show ip route  i cant see bots routes received from both lines between R2 and R1.

I dot understand why!

BR

Dave

3 Replies 3

Reza Sharifi
Hall of Fame
Hall of Fame

Hi Dave,

How are you advertising these 2 routes from r2 to r1?  Are you using an IGP, static route, network statment?

when you do "sh ip roue" on r2, do you see both routes in you routing table?

Reza

Hi,

advertising is through simple bgp session.

gi 0/1 interface connected Primary line

gi 0/2 interface connected Backup line

gi0/3 staticly added IPs 192.168.1.1 / 25  and 192.168.1.129 / 25

Local pref. is changed with output filters on R2 for prefix 192.168.1.0/25 and 192.168.1.128/25

On r2 in bgp network are set : 192.168.1.0/25 and 192.168.1.128/25

it means it is propagated for each neighbour on primary and secondary line too.

I want specifi my problem.

I have configured outgoing filter that changes local pref for each subnet.

It works great in iBGP but from eBGP network it is not working. Each traceroute is going throught only first neighbour. But in routing table is pecified which is the best way for each subnet.

This is my router in peering centre:

This router is connected to peer and with our local network too.

This is only example , that i try to simulate the config...

#show ip bgp
BGP table version is 144, local router ID is xxx.xxx.xxx.xxx
Status codes: s suppressed, d damped, h history, * valid, > best, i - internal
,
              r RIB-failure, S Stale
Origin codes: i - IGP, e - EGP, ? - incomplete

   Network          Next Hop            Metric LocPrf Weight Path
*> 10.1.1.0/24      192.108.148.10                         0 2607 i
*> 10.1.2.0/24      192.108.148.10                         0 2607 i
*> 10.1.3.0/24      192.108.148.10                         0 2607 i
*> 10.1.4.0/24      192.108.148.10                         0 2607 i
*> 10.1.5.0/24      192.108.148.10                         0 2607 i
*>i18.2x.90.0/25   18.2x.88.6                   200      0 i
*>i18.2x.90.128/25 18.2x.88.102                 200      0 i
*> 192.168.1.0      192.108.148.15                         0 12508 i
*> 192.168.2.0      192.108.148.15                         0 12508 i
*> 192.168.3.0      192.108.148.15                         0 12508 i
*> 192.168.4.0      192.108.148.15                         0 12508 i
*> 192.168.5.0      192.108.148.15                         0 12508 i

show ip route


Codes: C - connected, S - static, R - RIP, M - mobile, B - BGP
       D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
       N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
       E1 - OSPF external type 1, E2 - OSPF external type 2
       i - IS-IS, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2
       ia - IS-IS inter area, * - candidate default, U - per-user static route
       o - ODR, P - periodic downloaded static route

Gateway of last resort is not set

C    xxx.xxx.xxx.xxx is directly connected, GigabitEthernet0/1
B    192.168.4.0/24 [20/0] via xxx.xxx.xxx.xxx, 04:09:10
     18.2x.0.0/16 is variably subnetted, 4 subnets, 2 masks
B       18.2x.90.128/25 [200/0] via 18.2x.88.102, 00:06:19
C       18.2x.88.100/30 is directly connected, GigabitEthernet0/10
C       18.2x.88.4/30 is directly connected, GigabitEthernet0/3
B       18.2x.90.0/25 [200/0] via 18.2x.88.6, 00:06:05
B    192.168.5.0/24 [20/0] via xxx.xxx.xxx.xxx, 04:09:10
     10.0.0.0/24 is subnetted, 5 subnets
B       10.1.3.0 [20/0] via xxx.xxx.xxx.xxx, 04:09:10
B       10.1.2.0 [20/0] via xxx.xxx.xxx.xxx, 04:09:10
B       10.1.1.0 [20/0] via xxx.xxx.xxx.xxx, 04:09:10
B       10.1.5.0 [20/0] via xxx.xxx.xxx.xxx, 04:09:10
B       10.1.4.0 [20/0] via xxx.xxx.xxx.xxx, 04:09:10
B    192.168.1.0/24 [20/0] via xxx.xxx.xxx.xxx, 04:09:10
B    192.168.2.0/24 [20/0] via xxx.xxx.xxx.xxx, 04:09:10
B    192.168.3.0/24 [20/0] via xxx.xxx.xxx.xxx, 04:09:10

xxx.xxx.xxx.xxx is IP from eBGP neighbour

show ip bgp sum

Neighbor        V    AS MsgRcvd MsgSent   TblVer  InQ OutQ Up/Down  State/PfxRcd
78.2x.88.6     4 5xx3     440     337      144    0    0 00:22:32        1
78.2x.88.102   4 5xx3     501     397      144    0    0 00:22:36        1

if i trace from this router see what hapend

Tracing the route to 78.2x.90.2

  1 78.2x.88.6 4 msec 4 msec 0 msec
  2 78.2x.90.2 4 msec 0 msec 4 msec

Type escape sequence to abort.
Tracing the route to 78.2x.90.200

  1 78.2x.88.102 4 msec 0 msec 0 msec

  2 78.2x.90.200 4 msec 0 msec 4 msec

It works GREAT!!!

If i trart traceroute from another neighbour , from eBGP side , all trafic is going throught 78.2x.88.6

Review Cisco Networking for a $25 gift card