R0106-HP MSR Router Series Layer 3 - IP Routing Command Reference(V7)

394
peer connect-interface
Use peer connect-interface to specify a source interface (IP address/IPv6 address) for establishing TCP
connections to a peer or peer group.
Use undo peer connect-interface to restore the default.
Syntax
peer { group-name | ip-address | ipv6-address } connect-interface interface-type interface-number
undo peer { group-name | ip-address | ipv6-address } connect-interface
Default
BGP uses the primary IP or IPv6 address of the egress interface in the optimal route destined for the BGP
peer or peer group as the source address. The address is used to establish a TCP connection to the peer
or peer group.
Views
BGP view, BGP-VPN instance view
Predefined user roles
network-admin
Parameters
group-name: Specifies a peer group by its name, a case-sensitive string of 1 to 47 characters. The peer
group must have been created.
ip-address: Specifies a peer by its IP address. The peer must have been created.
ipv6-address: Specifies a peer by its IPv6 address. The peer must have been created.
interface-type interface-number: Specifies an interface by its type and number.
Usage guidelines
The peer connect-interface command and the peer source-address command can both change the
source address for establishing TCP connections. If you execute both commands, the most recent
configuration takes effect.
You can change the source address in the following scenarios:
If the peer's IP/IPv6 address belongs to an interface indirectly connected to the local router, you
must specify that interface as the source interface for TCP connections on the peer. For example,
interface A on the local end is directly connected to interface B on the peer. If you use the peer
x.x.x.x as-number as-number command and x.x.x.x is not the IP address of interface B on the local
end, you must use the peer connect-interface command on the peer to specify the interface whose
IP address is x.x.x.x as the source interface. This interface is used to establish a TCP connection.
On a BGP router that has multiple links to a peer, if the source interface fails, BGP must reestablish
TCP connections. To avoid this problem, use a loopback interface as the source interface or use the
IP address of a loopback interface as the source address.
To establish multiple BGP sessions to a router, specify a source address or source interface for each
peer if the BGP sessions use the IP addresses of different interfaces. Specify a source address for
each peer if the BGP sessions use the different addresses of the same interface. Otherwise, the local
BGP router might fail to establish a TCP connection to a peer when it uses the optimal route to
determine the source address.
The source interfaces on the local router and the peer must be reachable to each other.