300
peer
{
group-name
|
ip-address
}
route-policy
route-policy-name
{
export
|
import
}
undo peer
{
group-name
|
ip-address
}
route-policy
route-policy-name
{
export
|
import
}
In BGP IPv6 unicast instance view:
peer
{
group-name
|
ipv6-address
}
route-policy
route-policy-name
{
export
|
import
}
undo peer
{
group-name
|
ipv6-address
}
route-policy
route-policy-name
{
export
|
import
}
In BGP-VPN IPv6 unicast instance view:
peer
{
group-name
|
ipv6-address
}
route-policy
route-policy-name
{
export
|
import
}
undo peer
{
group-name
|
ipv6-address
}
route-policy
route-policy-name
{
export
|
import
}
Default
No routing policy is applied to routes from/to the peer or peer group.
Views
BGP IPv4 unicast instance view, BGP-VPN IPv4 unicast instance view, BGP IPv6 unicast instance view,
BGP-VPN IPv6 unicast 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.
route-policy-name
: Specifies a routing policy by its name, a case-sensitive string of 1 to 63 characters.
export
: Applies the routing policy to routes outgoing to the peer or peer group.
import
: Applies the routing policy to routes incoming from the peer or peer group.
Usage guidelines
The specified routing policy must have been configured with the
route-policy
command in system view.
Otherwise, all routes can pass the routing policy.
The
if-match interface
command, if configured for the referenced routing policy, does not take effect for
routes.
Examples
# In BGP IPv4 unicast instance view, apply routing policy
test-policy
to routes outgoing to the peer group
test
.
<Sysname> system-view
[Sysname] bgp 100
[Sysname-bgp] ipv4-family unicast
[Sysname-bgp-ipv4] peer test route-policy test-policy export
# In BGP-VPN IPv6 unicast instance view, apply the routing policy
test-policy
to routes outgoing to the
peer group
test
.
<Sysname> system-view
[Sysname] bgp 100
[Sysname-bgp] ip vpn-instance vpn1