Avoid BGP link to get saturated

I,
How can I set up a policy map that automatically closes an interface if this BGP link is getting saturated?

Thanks

Hello Giovanni

There are various options to deal with saturated links, and what you can do about them can also vary. You can shut them down, or you can introducing shaping or policing to deal with congestion. Solutions can include may things such as QoS, or using an EEM script, or even SNMP.

Can you tell us a little more about what you want to achieve so that we can more specifically suggest solutions?

I hope this has been helpful!

Laz

In my company, time ago, i’ve experienced a saturation of a BGP link, and I saw that on grafana monitoring that notified me about the issue.

In this case we had shutdown BGP session to reroute the traffic over another carrier.

Can I automate this process? ( we had shutdown the BGP session, but I’m looking for a solution more soft, e.g. an ACL or a route-map)

Thanks

Hello Giovanni

Ah, I see, so whenever the link was saturated, you manually tore down the BGP neighborship, so that traffic will be rerouted. This of course works, but it is not ideal. Even if you automate this procedure it is still not an efficient use of available bandwidth and infrastructure. If you tear down a BGP neighborship, that means that the saturated link suddenly gets zero traffic, and it is a shame to let all that bandwidth be unused even for a short period of time, and you burden the rest of the network. Ideally, a more appropriate load sharing mechanism should be employed so that the link will not get saturated and additional infrastructure will be shared.

The whole thing should be redesigned to use BGP multipath and additional paths.

However, if you would like to automate this procedure, nothing readily available comes to mind using Cisco IOS commands other than an EEM script. You can create a script that will do something, such as shut down a BGP peering, when the interface load hits a certain value. An example of such a script can be found here:

In this script, the action is to simply print an informational message, but you can put in the appropriate commands to remove the BGP peering. You can then create another script that will reenable the BGP peering after a certain amount of time.

Other than using EEM, the only other way to do this is to use device programmability tools to automate the procedure.

I hope this has been helpful!

Laz