![Huawei S6700 Series Скачать руководство пользователя страница 471](http://html.mh-extra.com/html/huawei/s6700-series/s6700-series_configuration-manual_169517471.webp)
*> 200.1.3.0 200.1.3.1 0 0 20?
*> 200.1.4.0 200.1.3.1 0 20 10?
Check the routing table of Switch C. You can find that Switch C learns the advertised by Switch
B.
<SwitchC>
display bgp routing-table
BGP Local router ID is 3.3.3.3
Status codes: * - valid, > - best, d - damped,
h - history, i - internal, s - suppressed, S - Stale
Origin : i - IGP, e - EGP, ? - incomplete
Total Number of Routes: 8
Network NextHop MED LocPrf PrefVal Path/Ogn
*> 200.1.2.0 200.1.4.1 0 0 10?
* 200.1.3.1 0 0 20?
*> 200.1.3.0 0.0.0.0 0 0 ?
* 200.1.4.1 0 10 20?
200.1.3.1 0 0 20?
*> 200.1.3.2/32 0.0.0.0 0 0 ?
*> 200.1.4.0 0.0.0.0 0 0 ?
* 200.1.3.1 0 20 10?
200.1.4.1 0 0 10?
*> 200.1.4.2/32 0.0.0.0 0 0 ?
Step 4
Configure the AS-Path filter on Switch B and apply the filter on the outbound interface of Switch
B.
# Create AS-Path filter 1, denying the passing of routes carrying AS 30. The regular expression
"_30_" indicates any AS list that contains AS 30 and ".*" matches any character.
[SwitchB]
ip as-path-filter 1 deny _30_
[SwitchB]
ip as-path-filter 1 permit .*
# Create AS-Path filter 2, denying the passing of routes carrying AS 10.
[SwitchB]
ip as-path-filter 2 deny _10_
[SwitchB]
ip as-path-filter 2 permit .*
# Apply the AS-Path filter on two outbound interfaces of Switch B.
[SwitchB]
bgp 20
[SwitchB-bgp]
peer 200.1.2.1 as-path-filter 1 export
[SwitchB-bgp]
peer 200.1.3.2 as-path-filter 2 export
[SwitchB-bgp]
quit
Step 5
Check the routing table advertised by Switch B, and you can find that the advertised routes to
the network segment between Switch A and Switch C do not exist. Take the route advertised by
Switch B to Switch C as an example.
<SwitchB>
display bgp routing-table peer 200.1.3.2 advertised-routes
BGP Local router ID is 2.2.2.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
*> 200.1.2.0 200.1.3.1 0 0 20?
*> 200.1.3.0 200.1.3.1 0 0 20?
*> 200.1.4.0 200.1.3.1 0 20 10?
Similarly, the BGP routing table of Switch C does not have the two routes.
<SwitchC>
display bgp routing-table
S6700 Series Ethernet Switches
Configuration Guide - IP Routing
7 BGP Configuration
Issue 01 (2012-03-15)
Huawei Proprietary and Confidential
Copyright © Huawei Technologies Co., Ltd.
452