Specifying a list of networks to advertise – Brocade Virtual ADX Switch and Router Guide (Supporting ADX v03.1.00) User Manual

Page 251

Advertising
background image

Brocade Virtual ADX Switch and Router Guide

237

53-1003246-01

Specifying a list of networks to advertise

8

Specifying a list of networks to advertise

By default, the device sends BGP4 routes only for the networks you either identify with the network
command or are redistributed into BGP4 from OSPF or connected routes.

NOTE

The exact route must exist in the IP route table before the device can create a local BGP4 route.

To configure the device to advertise network 10.157.22.0/24, enter the following command.

Virtual ADX(config-bgp-router)# network 10.157.22.0 255.255.255.0

Syntax: [no] network ip-addr ip-mask [route-map map-name] | [weight num] | [backdoor]

The ip-addr is the network number and the ip-mask specifies the network mask.

The route-map map-name parameter specifies the name of the route map you want to use to set or
change BGP4 attributes for the network you are advertising. The route map must already be
configured. If it is not, the default action is to deny redistribution.

The weight num parameter specifies a weight to be added to routes to this network.

The backdoor parameter changes the administrative distance of the route to this network from the
EBGP administrative distance (20 by default) to the Local BGP4 weight (200 by default), tagging
the route as a backdoor route. Use this parameter when you want the device to prefer IGP routes
such OSPF routes over the EBGP route for the network.

Specifying a route map when configuring BGP4
network advertising

You can specify a route map when you configure a BGP4 network to be advertised. The device uses
the route map to set or change BGP4 attributes when creating a local BGP4 route.

NOTE

You must configure the route map before you can specify the route map name in a BGP4 network
configuration; otherwise, the route is not imported into BGP4.

To configure a route map, and use it to set or change route attributes for a network you define for
BGP4 to advertise, enter commands such as the following.

Virtual ADX(config)# route-map set_net permit 1

Virtual ADX(config-routemap set_net)# set community no-export

Virtual ADX(config-routemap set_net)# exit

Virtual ADX(config)# router bgp

Virtual ADX(config-bgp-router)# network 10.100.1.0/24 route-map set_net

The first two commands in this example create a route map named “set_net” that sets the
community attribute for routes that use the route map to “NO_EXPORT”. The next two commands
change the CLI to the BGP4 configuration level. The last command configures a network for
advertising from BGP4, and associates the “set_net” route map with the network. When BGP4
originates the 10.100.1.0/24 network, BGP4 also sets the community attribute for the network to
“NO_EXPORT”.

Syntax: [no] network ip-addr ip-mask [route-map map-name] | [weight num] | [backdoor]

Advertising