HP (Hewlett-Packard) 6308M-SX Switch User Manual


 
Advanced Configuration and Management Guide
HP9300(config)# router bgp
HP9300(config-bgp-router)# network 100.100.1.0/24 route-map set_net
The first two commands in this example create a route map named set_netthat 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 100.100.1.0/24 network, BGP4 also sets the
community attribute for the network to NO_EXPORT.
Syntax: network <ip-addr> <ip-mask> [route-map <map-name>] | [weight <num>] | [backdoor]
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.
For information about the other parameters, see Defining Route Maps on page 10-59.
USING THE WEB MANAGEMENT INTERFACE
You cannot add a route map to a BGP4 network definition using the Web management interface.
Changing the Default Local Preference
When the routing switch uses the BGP4 algorithm to select a route to send to the IP route table, one of the
parameters the algorithm uses is the local preference. Local preference is an attribute that indicates a degree of
preference for a route relative to other routes. BGP4 neighbors can send the local preference value as an
attribute of a route in an UPDATE message.
Local preference applies only to routes within the local AS. BGP4 routers can exchange local preference
information with neighbors who also are in the local AS, but BGP4 routers do not exchange local preference
information with neighbors in remote ASs.
The default local preference is 100. For routes learned from EBGP neighbors, the default local preference is
assigned to learned routes. For routes learned from IBGP neighbors, the local preference value is not changed
for the route.
When the BGP4 algorithm compares routes on the basis of local preferences, the route with the higher local
preference is chosen.
NOTE: To set the local preference for individual routes, use route maps. See Defining Route Maps on
page 10-59. See How BGP4 Selects a Path for a Routeon page 10-3 for information about the BGP4 algorithm.
To change the default local preference used by the routing switch, use either of the following methods.
USING THE CLI
To change the default local preference to 200, enter the following command:
HP9300(config-bgp-router)# default-local-preference 200
Syntax: default-local-preference <num>
The <num> parameter indicates the preference and can be a value from 0 4294967295.
USING THE WEB MANAGEMENT INTERFACE
1. Log on to the device using a valid user name and password for read-write access. The System configuration
panel is displayed.
2. Click on the plus sign next to Configure in the tree view to expand the list of configuration options.
3. Click on the plus sign next to BGP in the tree view to expand the list of BGP option links.
4. Click on the General
link to display the BGP configuration panel, shown in Figure 10.2 on page 10-8.
5. Change the number in the Default Local Preference field. You can enter a number from 0 4294967295.
6. Click the Apply button to apply the changes to the devices running-config file.
10 - 28