08-29-2012 06:39 PM - edited 03-04-2019 05:25 PM
Hello, I am having a bit of a BGP prefix issue for my 2 external ISPs with a couple of class C ranges. When I do a show ip bgp neighbor (carrier router IP) advertised I get the following:
*> xxx.xxx.255.0 0.0.0.0 0 32768 i
*> xxx.xxx.142.0 0.0.0.0 0 32768 i
*> xxx.xxx.104.0 0.0.0.0 0 32768 i
For some reason, it is not showing the /24 at the end of each of these subnets. As a result, I am pretty sure that the routes are being learned as single host routes instead of routes for the entire /24 of these 3 networks. My relevant config is listed below. Help would be greatly appreciated at this point since whenever I have an outage with my primary carrier, Im not failing over to the backup carrier right now.
router bgp 12345
no synchronization
bgp router-id xxx.x.133.154
bgp log-neighbor-changes
network xxx.xxx.255.0
network xxx.xxx.142.0
network xxx.xxx.104.0
neighbor xxx.xxx.142.119 remote-as 30587
neighbor xxx.xxx.142.119 next-hop-self
neighbor xxx.xxx.13.153 remote-as 13776
neighbor xxx.xxx.13.153 description qx-neighbor
neighbor xxx.xxx.153 update-source GigabitEthernet0/1
neighbor xxx.xxx.133.153 version 4
neighbor xxx.xxx.133.153 soft-reconfiguration inbound
neighbor xxx.xxx.153 route-map rfc1918-in in
neighbor xxx.xxx.133.153 route-map comp-out out
no auto-summary
ip prefix-list comp-out seq 10 permit xxx.xxx.142.0/24
ip prefix-list comp-out seq 15 permit xxx.xxx.104.0/24
ip prefix-list comp-out seq 20 permit xxx.xxx.255.0/24
route-map comp-out permit 5
match ip address prefix-list comp-out
set as-path prepend 12345 12345 12345
08-29-2012 09:33 PM
Hi,
Looking at your config it seems you are orginating this networks from your AS.0.0.0.0 in your next-hop that these prefixes are originated from your AS.
Apart the above prefixes i dont see any routes being learned from your provider.
Thanks
08-30-2012 12:02 AM
Hi,
you've got a classful netmask so it's normal it is not displayed and these are prefixes originated by you( next-hop of 0.0.0.0) and they will be advertised as /24.
We need more info to solve the primary/backup problem.
Regards.
Alain
Don't forget to rate helpful posts.
08-30-2012 05:54 AM
OK, thanks. I thought the reason may be that the /24 was assumed... So now Im stuck. The only 2 things I can think of are:
2 of these subnets 142.0 and 104.0 are on sub interfaces of the ethernet router.
and
I have static routes for the 255.0 network that are hosts so possibly a match issue that is injecting a route??
I.E. I have a static route on this router that says xxx.xxx.255.10 goes to a specific IP address??
Here is the full config plus a show IP route
interface Loopback0
description management address
ip address 24.56.104.3 255.255.255.0
!
interface GigabitEthernet0/0
no ip address
ip flow ingress
duplex auto
speed auto
media-type rj45
!
interface GigabitEthernet0/0.2
encapsulation dot1Q 2
ip address 65.86.142.254 255.255.255.0
ip flow ingress
standby 206 ip 65.86.142.1
standby 206 priority 110
standby 206 preempt
!
interface GigabitEthernet0/0.166
encapsulation dot1Q 166
ip address 96.96.255.3 255.255.255.0
ip flow ingress
standby 205 ip 96.96.255.1
standby 205 priority 110
standby 205 preempt
!
interface GigabitEthernet0/1
description ISP.net INET Connection
ip address 157.157.133.154 255.255.255.252
ip flow ingress
duplex auto
speed auto
media-type rj45
no cdp enable
!
router bgp 12345
no synchronization
bgp router-id 157.157.133.154
bgp log-neighbor-changes
network 96.96.255.0
network 65.86.142.0
network 24.56.104.0
neighbor 65.86.142.119 remote-as 12345
neighbor 65.86.142.119 next-hop-self
neighbor 157.157.133.153 remote-as 20201
neighbor 157.157.133.153 description ISP-neighbor
neighbor 157.157.133.153 update-source GigabitEthernet0/1
neighbor 157.157.133.153 version 4
neighbor 157.157.133.153 soft-reconfiguration inbound
neighbor 157.157.133.153 route-map rfc1918-in in
neighbor 157.157.133.153 route-map company-out out
no auto-summary
!
ip forward-protocol nd
!
!
no ip http server
ip route 96.96.255.10 255.255.255.255 65.86.142.9
ip route 96.96.255.11 255.255.255.255 65.86.142.9
ip route 96.96.255.12 255.255.255.255 65.86.142.2
ip route 96.96.255.40 255.255.255.255 65.86.142.9
ip route 24.56.104.4 255.255.255.255 65.86.142.9
ip route 24.56.104.26 255.255.255.255 65.86.142.9
ip route 24.56.104.27 255.255.255.255 65.86.142.9
ip route 24.56.104.35 255.255.255.255 65.86.142.9
ip route 24.56.104.45 255.255.255.255 65.86.142.9
!
!
ip prefix-list rfc1918-in seq 5 deny 10.0.0.0/8
ip prefix-list rfc1918-in seq 10 deny 172.16.0.0/12
ip prefix-list rfc1918-in seq 15 deny 192.168.0.0/16
ip prefix-list rfc1918-in seq 20 deny 169.254.0.0/16
ip prefix-list rfc1918-in seq 25 deny 0.0.0.0/8
ip prefix-list rfc1918-in seq 30 deny 127.0.0.0/8
ip prefix-list rfc1918-in seq 35 deny 198.18.0.0/15
ip prefix-list rfc1918-in seq 40 deny 192.0.2.0/24
ip prefix-list rfc1918-in seq 45 deny 198.51.100.0/24
ip prefix-list rfc1918-in seq 50 deny 203.0.113.0/24
ip prefix-list rfc1918-in seq 55 permit 0.0.0.0/0
!
ip prefix-list company-out seq 10 permit 65.86.142.0/24
ip prefix-list company-out seq 15 permit 24.56.104.0/24
ip prefix-list company-out seq 20 permit 96.96.255.0/24
route-map company-out permit 5
match ip address prefix-list company-out
set as-path prepend 12345 12345 12345
!
route-map rfc1918-in permit 5
match ip address prefix-list rfc1918-in
set local-preference 200
gt-r-3825b-noc#show ip route
Codes: L - local, 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, + - replicated route
Gateway of last resort is 65.86.142.119 to network 0.0.0.0
B* 0.0.0.0/0 [200/0] via 65.86.142.119, 5d16h
96.96.255.0/24 is variably subnetted, 6 subnets, 2 masks
C 96.96.255.0/24 is directly connected, GigabitEthernet0/0.166
L 96.96.255.3/32 is directly connected, GigabitEthernet0/0.166
S 96.96.255.10/32 [1/0] via 65.86.142.9
S 96.96.255.11/32 [1/0] via 65.86.142.9
S 96.96.255.12/32 [1/0] via 65.86.142.2
S 96.96.255.40/32 [1/0] via 65.86.142.9
65.86.142.0/24 is variably subnetted, 2 subnets, 2 masks
C 65.86.142.0/24 is directly connected, GigabitEthernet0/0.2
L 65.86.142.254/32 is directly connected, GigabitEthernet0/0.2
24.56.104.0/24 is variably subnetted, 7 subnets, 2 masks
C 24.56.104.0/24 is directly connected, Loopback0
L 24.56.104.3/32 is directly connected, Loopback0
S 24.56.104.4/32 [1/0] via 65.86.142.9
S 24.56.104.26/32 [1/0] via 65.86.142.9
S 24.56.104.27/32 [1/0] via 65.86.142.9
S 24.56.104.35/32 [1/0] via 65.86.142.9
S 24.56.104.45/32 [1/0] via 65.86.142.9
157.157.133.0/24 is variably subnetted, 2 subnets, 2 masks
C 157.157.133.152/30 is directly connected, GigabitEthernet0/1
L 157.157.133.154/32 is directly connected, GigabitEthernet0/1
08-30-2012 07:14 AM
Hi,
I only see one ISP neighbour here, where's the other? I suppose it is connected to the iBGP neighbour 65.86.142.119
Can you provide a topology diagram as well.
Regards.
Alain
Don't forget to rate helpful posts.
08-30-2012 07:27 AM
Alain,
You are correct. The other ISP neighbor is connected to the IBGP neighbor and that is the route we prefer our traffic to go. Our primary provider had some issues within their network that caused degraded internet services. As a result, we shut down that router to force the path out the router in question with config listed above. That went horribly. We could get traffic to flow when sourcing from the serial interface but when we tried sourcing trafffic from any of our class sub interfaces, it failed.
08-30-2012 11:44 AM
Hi,
can you do sh ip bgp nei x.x.x.x routes for the backup path.
Regards.
Alain
Don't forget to rate helpful posts.
08-30-2012 12:50 PM
Here are the outputs
Show ip bgp neighbor 157.157.133.153 advertised
*> xxx.xxx.255.0 0.0.0.0 0 32768 i
*> xxx.xxx.142.0 0.0.0.0 0 32768 i
*> xxx.xxx.104.0 0.0.0.0 0 32768 i
Show up bgp neighbor routes
gt-r-3825b-noc#show ip bgp neighbor 157.157.133.153 routes
BGP table version is 39, local router ID is 157.157.133.154
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
* 0.0.0.0 157.157.133.153 0 200 0 13776 i
08-30-2012 01:24 PM
From what I can see - there is some questions I would like to ask. Do you have your own AS number i.e. did you get this from RIR? I suspect not as you would be using iBGP to connect to one of your ISPs. If this is the case your addresses are probably PA. Of course these requirement assume you are dual feeds to different providers?
If the these facts are true it's unlikely that you going to be able to advertise these prefixes properly.
Sent from Cisco Technical Support iPad App
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide