cancel
Showing results for 
Search instead for 
Did you mean: 

Export direct and static to one bgp neighbor

Export direct and static to one bgp neighbor

andreas1
New Contributor II
Is there any way to only export direct and/or static to a specific neighboor ? I can't figure out if I can do it in a route-policy or not ? I do not want to do it for the general bgp process. ( I would have to rewrite alot of export policys then ) But if that is the only way I have to do it I guess ? Or could I do a seperate network statement under bgp for that subnet specific ? One example 10.0.0.0/24 I want to send 10.0.0.0/30 to a specific neighboor that I is direclty connected to the router that runs BGP. // Andreas
7 REPLIES 7

andreas1
New Contributor II
Understood  It would be nice to be able to specify per neighboor behaviour though. I solved it the way you suggested but it will make the polices more complex.

Alex24
Extreme Employee
Hello Andreas,

Route-Policies would be the way to go to filter advertisements to a specific peer. These two articles How to filter routes in BGP on EXOS Router and How to selectively advertise static routes via BGP show two different implementations of this. The first filters routes out using a deny policy while the second specifies only certain routes that should be advertised.

In your case adding routes to BGP is not a per neighbor thing. However by using route-policies for each peer you can control which routes go to which peer from the overall BGP route table.

- Alex

andreas1
New Contributor II
Yes I understand all of that. My question still remains can I do this per "neighboor" ? I do not want to add a static network to my other neighboor only to a specific neigh. // Andreas

Tripathy__Priya
Extreme Employee
Hello Andreas,

Actually When exporting BGP routes, static routes we need to configure with the configure bgp add network command. This takes precedence over BGP discovered routes.

To create a static BGP network, use the following command:
configure bgp add network {address-family [ipv4-unicast | ipv4-multicast | ipv6-
unicast | ipv6-multicast]} {network-policy }

NOTE:
This command adds the route to BGP only if the route is present in the routing table.

Hope this is useful for you.

GTM-P2G8KFN