Route Attribute
Route Learned
from Router C
Route Learned
from Router D
Comparison
Origin
Incomplete
IGP
The route learned
from Router D is
optimal.
The Origin attribute can be modified using a route-policy. In the following example, a route-
policy is configured on Router B to modify the Origin attribute, and the detailed configurations
are as follows:
#
bgp 65001
#
ipv4-family unicast
peer 10.1.3.2 route-policy for_d import //Apply import policy named
for_d to the routes learned from 10.1.3.2 and use for_d to modify the Origin
value.
#
route-policy for_d permit node 10 //Define the route-policy
named for_d.
apply origin incomplete //Set the Origin type to
Incomplete.
Run the
display bgp routing-table
[
ip-address
] command to check the configurations.
# Display the routing table of Router B.
[RouterB]
display bgp routing-table
BGP Local router ID is 10.1.1.2
Status codes: * - valid, > - best, d - damped,
h - history, i - internal, s - suppressed, S - Stale
Origin : i - IGP, e - EGP, ? - incomplete
Total Number of Routes: 3
Network NextHop MED LocPrf PrefVal Path/Ogn
i 10.1.2.0/30 10.1.2.2 0 100 0 ?
*>i 10.1.4.0/30 10.1.2.2 0 100 0 ?
* i 10.1.3.2 0 100 0 ?
The preceding command output shows that the route learned from Router C becomes the optimal
route.
[RouterB]
display bgp routing-table 10.1.4.0
BGP local router ID : 10.1.1.2
Local AS number : 65001
Paths: 2 available, 1 best, 1 select
BGP routing table entry information of 10.1.4.0/30:
From: 10.1.2.2 (
10.1.2.2
)
Route Duration: 01h28m19s
Relay IP Nexthop: 0.0.0.0
Relay IP Out-Interface: GigabitEthernet0/0/0
Original nexthop: 10.1.2.2
Qos information : 0x0
AS-path Nil, origin incomplete, MED 0, localpref 100, pref-val 0, valid, internal,
best
, select, active, pre 255
Advertised to such 1 peers:
10.1.1.1
HUAWEI NetEngine80E/40E Router
Configuration Guide - IP Routing
8 BGP Configuration
Issue 02 (2014-09-30)
Huawei Proprietary and Confidential
Copyright © Huawei Technologies Co., Ltd.
938