RE: Advertising subnets of existing networks ?

From: Brian McGahan <bmcgahan_at_ine.com>
Date: Wed, 29 Jun 2011 12:07:21 -0500

The same way, just point the routes towards an interface instead of towards Null0. Here's an example, where R2 has a LAN interface 10.0.0.0/24, but advertises it to R1 as two /25s

R2#sh 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

O 200.0.16.0/24 [110/65] via 200.0.12.1, 21:37:06, Serial0/0.201
C 200.0.12.0/24 is directly connected, Serial0/0.201
O 200.0.13.0/24 [110/128] via 200.0.12.1, 21:37:16, Serial0/0.201
     10.0.0.0/24 is subnetted, 1 subnets
C 10.0.0.0 is directly connected, FastEthernet0/0

R2#conf t
Enter configuration commands, one per line. End with CNTL/Z.
R2(config)#ip route 10.0.0.0 255.255.255.128 f0/0
R2(config)#ip route 10.0.0.128 255.255.255.128 f0/0
R2(config)#end
R2#sh 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

O 200.0.16.0/24 [110/65] via 200.0.12.1, 21:37:20, Serial0/0.201
C 200.0.12.0/24 is directly connected, Serial0/0.201
O 200.0.13.0/24 [110/128] via 200.0.12.1, 21:37:30, Serial0/0.201
     10.0.0.0/8 is variably subnetted, 3 subnets, 2 masks
S 10.0.0.0/25 is directly connected, FastEthernet0/0
C 10.0.0.0/24 is directly connected, FastEthernet0/0
S 10.0.0.128/25 is directly connected, FastEthernet0/0

R2#conf t
Enter configuration commands, one per line. End with CNTL/Z.
R2(config)#router ospf 1
R2(config-router)#redistribute static subnets
R2(config-router)#end
R2#

R1#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 200.0.16.0/24 is directly connected, FastEthernet0/0
C 200.0.12.0/24 is directly connected, Serial0/0.102
C 200.0.13.0/24 is directly connected, Serial0/0.103
     10.0.0.0/25 is subnetted, 2 subnets
O E2 10.0.0.0 [110/20] via 200.0.12.2, 00:00:07, Serial0/0.102
O E2 10.0.0.128 [110/20] via 200.0.12.2, 00:00:07, Serial0/0.102

HTH,

Brian McGahan, CCIE #8593 (R&S/SP/Security)
bmcgahan_at_INE.com
 
Internetwork Expert, Inc.
http://www.INE.com

From: Jacek [mailto:q.192.168.1.0_at_gmail.com]
Sent: Wednesday, June 29, 2011 10:06 AM
To: Brian McGahan
Cc: Cisco certification
Subject: Re: Advertising subnets of existing networks ?

Thanks for your answer. I think that you are referring to what Pakinstani ISP did wrong. I am interested how You Tube reacted to the problem.
As axplained in RIPEs case study Pakistani ISP started advertising 208.65.153.0/24.
To fix the problem YouTube started announcing 208.65.153.0/25 and 208.65.153.128/25, Because of the longest match rule the /25 are preferred over /24 and routers that received 2 x /25 routes sent traffic to YouTube.

My question is how can you quickly advertise 2 smaller subnets, in this case 2 x /25 instead of one /24 ? I can only suppose that 208.65.153.0/24 is redistributed from an IGP where servers reside. How can you then take a /24 route from for example OSPF and adverise it via BGP as two /25 routes ?

RIPE case study is here:
http://www.ripe.net/internet-coordination/news/industry-developments/youtube-hijacking-a-ripe-ncc-ris-case-study

On Tue, Jun 28, 2011 at 5:36 PM, Brian McGahan <bmcgahan_at_ine.com> wrote:
They were trying to Null route it. All you have to do is say:

208.65.153.128 255.255.255.128 null0
208.65.153.0 255.255.255.128 null0
!
router bgp 1
 network 208.65.153.128 mask 255.255.255.128
 network 208.65.153.0 mask 255.255.255.128

Blackholes like this are support to be community no-export, but they screwed up their config and they leaked the advertisements to their EBGP peers.

Brian McGahan, CCIE #8593 (R&S/SP/Security)
bmcgahan_at_INE.com
 
Internetwork Expert, Inc.
http://www.INE.com

Blogs and organic groups at http://www.ccie.net
Received on Wed Jun 29 2011 - 12:07:21 ART

This archive was generated by hypermail 2.2.0 : Fri Jul 01 2011 - 06:24:28 ART