Writers' Community!
Home News Business Science & Technology Life
Front Page Page Two Columnists Submit an Article FAQs Contact Author Login
Article Submission
We Need YOUR Articles!
We'll Promote Them for FREE!

Author Login

New Authors
Register Here


Now Serving 5,538 Authors
48,399 Quality Articles
& 6,730 Current Users Online!
Featured Authors
Avis Ward (12,701)
Richard Nicastro (2,545)
Dianne Lehmann (3,016)
Mogama (12,129)
Mike Fak (7,094)
Robert Melaccio, Sr. (6,658)
David Pekrul (613)
Terry Mitchell (2,761)
Sara O'Rourke (392)
Joel Hendon (4,797)
Susan Thom (9,073)
Laura Trahan (32,764)
Abigail Richards (6,279)
Peggy Butler (3,497)

View All Featured Authors
Most Recent
Windows Vista Sidebar, Gadgets, Easy Wireless Networking and Improved Back Features

CompTIA A+, Security+, Network+ Tutorial Ethernet Card Troubleshooting

CCNA, CCENT, CCNP Tutorial on Routers and Routing

CompTIA Security+ Article on Firewall Security Advantages and Firewall Functions

Microsoft Training Certifications

CCNA Security Exam Tutorial: When It's Good To Add Salt

Why Switch to Windows Vista

Free Cisco CCNA, CCENT, CCNP Certification Tutorial

Why People should get Network+, CCNA, CCNP or CCIE Network Based Certifications

Cisco CCNA And CCNP Practice Exam Questions: Frame Relay, Uplinkfast, And More!

Home » Categories » Computers & Networking » Technical Certification » Cisco CCNP / BSCI Exam Tutorial: Filtering BGP Updates With Prefix Lists » Printer Friendly

Cisco CCNP / BSCI Exam Tutorial: Filtering BGP Updates With Prefix Lists

Rated 3.5 out of 5
No Reader Ratings Available ?
Rate It  /  View Comments  /  View All Articles submitted by Chris Bryant CCIE 12933
Submitted Thursday, April 06, 2006
Chris Bryant CCIE 12933 (13,682)
The Bryant Advantage
Log in to become a member of Chris Bryant CCIE 12933's Fan Club!


A major part of your BSCI and CCNP exam success is mastering BGP, and that includes filtering BGP routing updates. In this tutorial, we'll take a look at how to filter BGP updates with prefix lists.

R4 is advertising three networks via BGP. The downstream router R3 sees these routes and places them into its BGP table as shown below. R3 has two downstream BGP peers, R1 and R2, and is advertising itself as the next-hop IP address for all BGP routes sent to those two routers.

R4(config)#router bgp 4
R4(config-router)#network 21.0.0.0 mask 255.0.0.0
R4(config-router)#network 22.0.0.0 mask 255.0.0.0
R4(config-router)#network 23.0.0.0 mask 255.0.0.0

R3#show ip bgp
BGP table version is 4, local router ID is 3.3.3.3
Status codes: s suppressed, d damped, h history, * valid, > best, i - internal
Origin codes: i - IGP, e - EGP, ? - incomplete

Network Next Hop Metric LocPrf Weight Path
*> 21.0.0.0 10.2.2.4 0 0 4 i
*> 22.0.0.0 10.2.2.4 0 0 4 i
*> 23.0.0.0 10.2.2.4 0 0 4 i

R3(config)#router bgp 123
R3(config-router)#neighbor 172.12.123.1 next-hop-self
R3(config-router)#neighbor 172.12.123.2 next-hop-self

In turn, both R1 and R2 have these three routes in their respective BGP tables.

R2#show ip bgp
BGP table version is 4, local router ID is 2.2.2.2
Status codes: s suppressed, d damped, h history, * valid, > best, i - internal
Origin codes: i - IGP, e - EGP, ? - incomplete

Network Next Hop Metric LocPrf Weight Path
*>i21.0.0.0 172.12.123.3 0 100 0 4 i
*>i22.0.0.0 172.12.123.3 0 100 0 4 i
*>i23.0.0.0 172.12.123.3 0 100 0 4 i

R1#show ip bgp
BGP table version is 4, local router ID is 19.1.1.1
Status codes: s suppressed, d damped, h history, * valid, > best, i - internal
Origin codes: i - IGP, e - EGP, ? - incomplete

Network Next Hop Metric LocPrf Weight Path
*>i21.0.0.0 172.12.123.3 0 100 0 4 i
*>i22.0.0.0 172.12.123.3 0 100 0 4 i
*>i23.0.0.0 172.12.123.3 0 100 0 4 i

If we wanted R3 to receive all three of these routes from R4 but not advertise all of them to R2 and R1, we've got a couple of options on how to block these routes. Cisco's recommendation is the use of prefix-lists, and once you get used to the syntax (which you should do before taking and passing the BSCI), you'll see they are actually easier to use than access-lists.

In this case, we're going to configure R3 to send only the route to 21.0.0.0 to R1 and 23.0.0.0 to R2. However, we do want these two routers to get any future routes that R4 advertises into BGP.

Since R1 and R2 will learn about these routes from an iBGP neighbor, they will not advertise the routes to each other.

On R3, we'll write a prefix-list that denies 22.0.0.0/8 and 23.0.0.0/8, but permits all other routes. After applying the prefix list as shown, R1 sees only the 21.0.0.0 /8 route.

R3(config)#ip prefix-list FILTER_R1 deny 22.0.0.0/8
R3(config)#ip prefix-list FILTER_R1 deny 23.0.0.0/8
R3(config)#ip prefix-list FILTER_R1 permit 0.0.0.0/0 le 32

R3(config)#router bgp 123
R3(config-router)#neighbor 172.12.123.1 prefix-list FILTER_R1 out

R3#clear ip bgp * soft

R1#show ip bgp
BGP table version is 6, local router ID is 19.1.1.1
Status codes: s suppressed, d damped, h history, * valid, > best, i - internal
Origin codes: i - IGP, e - EGP, ? - incomplete

Network Next Hop Metric LocPrf Weight Path
*>i21.0.0.0 172.12.123.3 0 100 0 4 i

The paths to 22.0.0.0/8 and 23.0.0.0/8 have been successfully filtered.

We'll do the same for R2, except the route not being expressly blocked is 23.0.0.0/8. The line "ip prefix-list permit 0.0.0.0/0 le 32" is the prefix list equivalent of a "permit any" statement in an ACL.

R3(config)#ip prefix-list FILTER_R2 deny 21.0.0.0/8
R3(config)#ip prefix-list FILTER_R2 deny 22.0.0.0/8
R3(config)#ip prefix-list FILTER_R2 permit 0.0.0.0/0 le 32
R3(config)#router bgp 123
R3(config-router)#neighbor 172.12.123.2 prefix-list FILTER_R2 out

R3#clear ip bgp * soft

R2#show ip bgp
BGP table version is 6, local router ID is 2.2.2.2
Status codes: s suppressed, d damped, h history, * valid, > best, i - internal
Origin codes: i - IGP, e - EGP, ? - incomplete

Network Next Hop Metric LocPrf Weight Path
*>i23.0.0.0 172.12.123.3 0 100 0 4 i

The paths to 21.0.0.0/8 and 22.0.0.0/8 have been successfully filtered.

To see the prefix lists configured on a route as well as the order of the statements in each list, run show ip prefix-list.

R3#show ip prefix-list
ip prefix-list FILTER_R1: 3 entries
seq 5 deny 22.0.0.0/8
seq 10 deny 23.0.0.0/8
seq 15 permit 0.0.0.0/0 le 32
ip prefix-list FILTER_R2: 3 entries
seq 5 deny 21.0.0.0/8
seq 10 deny 22.0.0.0/8
seq 15 permit 0.0.0.0/0 le 32

Get some hands-on practice with prefix lists and you'll quickly master them. Prefix lists are an important part of working with BGP in the exam room and production networks, so it's vital that you are comfortable working with them.

Chris Bryant, CCIE #12933, is the owner of The Bryant Advantage, home of free CCNP and CCNA tutorials, The Ultimate CCNA Study Package, and Ultimate CCNP Study Packages.

You can also join his RSS feed and visit his blog, which is updated several times daily with new Cisco certification articles, free tutorials, and daily CCNA / CCNP exam questions! Details are on the website.

For a FREE copy of his latest e-books, “How To Pass The CCNA" and “How To Pass The CCNP", just visit the website! You can also get FREE CCNA and CCNP exam questions every day! Pass the CCNP exam with The Bryant Advantage!






Reprint Rights

Log in to become a member of Chris Bryant CCIE 12933's Fan Club!

Comments on this article:
No comments yet.


Was this article helpful to you? Leave a Public Comment or Question:

 

This Article has been viewed 158 times.
Article added to SearchWarp.com on Thursday, April 06, 2006
View other articles written by Chris Bryant CCIE 12933 (13,682)


If you found this article interesting, you may want to check out:

Disclaimer:  All information on this site is provided for informational purposes only! By no means is any information presented herein intended to substitute for the advice provided to you by any health care or other professional or organization.


Today's Most Popular
Cisco Certification: The Definitive Guide To ARP, RARP, IARP, and Proxy ARP

Cisco CCNA Exam Tutorial: What's A Collision Domain?

Cisco CCNA Exam Tutorial: Five OSPF Details You Must Know!

Cisco CCNA Certification: Showdown At The Transport Layer... TCP vs. UDP !

Cisco CCNA Certification Exam Tutorial: Route Summarization

Cisco CCENT / CCNA Certification Exam Tutorial: Logging Synchronous And Exec-Timeout Commands

Cisco CCNA / CCNP Certification: Deciphering PING Returns

How To Become A CCNA (Cisco Certified Network Associate)

CCNA / CCNP / BCMSN Exam Tutorial: VLAN Trunking Basics

Cisco CCNA Certification: Static And Default Static Routes

Home  |  Page Two  |  FAQ's  |  Contact  |  Terms of Service  |  Article Submission Guidelines  |  Writers' Contests  |  Privacy  |  Mission / About
Copyright © 1999-2008 SearchWarp.com, All Rights Reserved - SearchWarp.com is an IcoLogic, Inc. Company