Cisco Support Community
cancel
Showing results for 
Search instead for 
Did you mean: 
Announcements

Attention: The Community will be in read-only mode on 12/14/2017 from 12:00 am pacific to 11:30 am.

During this time you will only be able to see content. Other interactions such as posting, replying to questions, or marking content as helpful will be disabled for few hours.

We apologize for the inconvenience while we perform important updates to the Community.

New Member

BGP | Questions

Hi Experts

I Have 2 question in BGP

1)what is the difference between the below

router bgp yy

network 172.16.16.0 mask 255.255.255.0

and the below as well

ip prefix-list test permit 172.16.16.0/24

which of the above advertise the the 172.16.16.0/24 to the neighbor ISP ? what is the difference

router bgp yy

neighbor Z.Z.Z.Z Prefix-list test out

2)why we need the below command even the same network advertised via bgp pr prefix network commands

ip route 172.16.16.0  255.255.255.0 null 0

thanks for your precious time

thanks

6 REPLIES

Re: BGP | Questions

To answer your questions

First one network command will advertise the network

The prefix list like acl

Using it with neighbor and filter command will be use for route filtering inbound or outbound

2 second question's answer is

If you do nit have a network ir a route in your routing table and you want to advertise it for any reason

You add a dummy static route to null0 interface to present it in your routing table

And then use the network command to advertise it to the bgp neighbor

Hope this help

if helpful rate

Sent from Cisco Technical Support iPhone App

BGP | Questions

I'm not sure I understand all of your questions, so I'll try to answer what I can.

The ip route statement is so bgp has a route to pull from and advertise. BGP can't advertise a network that it doesn't know about. The route to null0 just allows for bgp to advertise the route and allow this router to be it's next hop for that subnet. The prefix-list test out is advertising the 172.16.16.0/24 subnet to the neighbor. There are 3 ways to advertise in bgp: with a route-map (usually used to set options though), distribute-list, and prefix-list.

John

HTH, John *** Please rate all useful posts ***

BGP | Questions

Hi John

you mentioned above:

"The prefix-list test out is advertising the 172.16.16.0/24 subnet to the neighbor. There are 3 ways to advertise in bgp: with a route-map (usually used to set options though), distribute-list, and prefix-list."

however the ways to advertise a route/network in BGP is either to use network command or redistribute a route

while those prefix-list, route-map and access-list they used for route filtering and bgp policies inbound or outbount

HTH

BGP | Questions

I meant filter...

HTH, John *** Please rate all useful posts ***
New Member

BGP | Questions

Hi and many thanks for reply

so  the only method to advertise in bgp  is through the  Network command,am i right?

thanks

BGP | Questions

You can also advertise routes to the BGP protocol from any other protocol (and local subnets) by using the redistibution command under the BGP. For instance to advertise (redistribute) the local subnets to BGP you can use the next command

router bgp XXXXX

redistibute connected

306
Views
12
Helpful
6
Replies
CreatePlease to create content