|
BGP configuration commands appear on the
surface to mirror the syntax of familiar IGP (for example, RIP and
OSPF) commands. Although the syntax is similar, the function of
these commands is significantly different.
To begin configuring a BGP process,
issue the following familiar command:
Router(config)#router bgp AS-number
Note that the Cisco IOS permits only
one BGP process to run at a time. Thus, a router cannot belong to
more than one AS.
The network
command is used with IGPs,
such as RIP, to determine the interfaces on which to send and
receive updates, as well as which directly connected networks to
advertise. However, when configuring BGP, the network
command does not affect what
interfaces BGP runs on. Thus, configuring just a network
statement will not establish
a BGP neighbor relationship. This is a major difference between BGP
and IGPs. The network statement follows this syntax:
Router(config-router)#network network-number
[mask network-mask]
In BGP, the network
command tells the BGP process what locally learned networks to
advertise. The networks can be connected routes, static routes, or
routes learned via a dynamic routing protocol, such as RIP. These
networks must also exist in the local router's routing table or
they will not be sent out in updates. The mask
keyword can be used with the network
command to specify individual subnets. Routes learned by the BGP
process are propagated by default but are often filtered by a
routing policy.
For a BGP router to establish a
neighbor relationship with another BGP router, issue the this
configuration command:
Router(config-router)#neighbor
ip-address remote-as AS-number
This command serves to identify a
peer router with which the local router will establish a session.
The ip-address argument is the neighbor interface's IP
address.
The AS-number argument determines whether the neighbor router is an
EBGP or an IBGP neighbor.
|