BGP prefix-lists and network statement
Are the below bolded network statements necessary if I am using prefix-lists to announce my networks?
router bgp 65000
network 1.1.1.0 mask 255.255.255.0
network 2.2.2.0 mask 255.255.255.0
network 3.3.3.0 mask 255.255.255.0
neighbor 10.0.0.2 remote-as 100
neighbor 10.0.0.2 prefix-list ISP_A out
neighbor 20.0.0.2 remote-as 200
neighbor 20.0.0.2 prefix-list ISP_B out
ip prefix-list ISP_A seq 10 permit 1.1.1.0/24
ip prefix-list ISP_A seq 20 permit 3.3.3.0/24
ip prefix-list ISP_B seq 10 permit 2.2.2.0/24
ip prefix-list ISP_B seq 20 permit 3.3.3.0/24
ip route 1.1.1.0 255.255.255.0 Null0
ip route 2.2.2.0 255.255.255.0 Null0
ip route 3.3.3.0 255.255.255.0 Null0
router bgp 65000
network 1.1.1.0 mask 255.255.255.0
network 2.2.2.0 mask 255.255.255.0
network 3.3.3.0 mask 255.255.255.0
neighbor 10.0.0.2 remote-as 100
neighbor 10.0.0.2 prefix-list ISP_A out
neighbor 20.0.0.2 remote-as 200
neighbor 20.0.0.2 prefix-list ISP_B out
ip prefix-list ISP_A seq 10 permit 1.1.1.0/24
ip prefix-list ISP_A seq 20 permit 3.3.3.0/24
ip prefix-list ISP_B seq 10 permit 2.2.2.0/24
ip prefix-list ISP_B seq 20 permit 3.3.3.0/24
ip route 1.1.1.0 255.255.255.0 Null0
ip route 2.2.2.0 255.255.255.0 Null0
ip route 3.3.3.0 255.255.255.0 Null0
Comments
-
networker050184 Mod Posts: 11,962 ModThe prefix-list doesn't announce anything, its just for applying policy to existing advertisements. So yes, you still need the network command if that is how you are getting those prefixes into BGP.An expert is a man who has made all the mistakes which can be made.
-
kryolla Member Posts: 785then you dont need the network statementStudying for CCIE and drinking Home Brew
-
networker050184 Mod Posts: 11,962 ModI think you need to understand exactly what each of those commands is making the router do. Grab a book, turn on your debugs and watch it all go. That's how I learn anyway.An expert is a man who has made all the mistakes which can be made.
-
cisco_trooper Member Posts: 1,441 ■■■■□□□□□□Agree with networker. This is the only way to learn. Otherwise you are just memorizing stuff, and eventually your memory will fail. You MUST seek understanding or you will severely limit your capacity to learn, and a major undesired consequence of this will be an extreme inability to troubleshoot problems when they occur, or to administer a network you didn't design. Just my two cents.
-
kryolla Member Posts: 785the network statement for bgp is different than igp and there is alot of good info on what redistribution is. Also check out route filtering which includes filtering with prefix listsStudying for CCIE and drinking Home Brew
-
Panzer919 Member Posts: 462Read this book, it is well worth the time and money!Cisco Brat Blog
I think “very senior” gets stuck in there because the last six yahoos that applied for the position couldn’t tell a packet from a Snickers bar.
Luck is where opportunity and proper planning meet
I have not failed. I've just found 10,000 ways that won't work.
Thomas A. Edison