No relevant resource is found in the selected language.

This site uses cookies. By continuing to browse the site you are agreeing to our use of cookies. Read our privacy policy>Search

Reminder

To have a better experience, please upgrade your IE browser.

upgrade

Configuration Guide - IP Unicast Routing

S7700 and S9700 V200R011C10

This document describes IP Unicast Routing configurations supported by the switch, including the principle and configuration procedures of IP Routing Overview, Static Route, RIP, RIPng, OSPF, OSPFv3, IS-IS(IPv4), IS-IS(IPv6), BGP, Routing Policy ,and PBR, and provides configuration examples.
Rate and give feedback :
Huawei uses machine translation combined with human proofreading to translate this document to different languages in order to help you better understand the content of this document. Note: Even the most advanced machine translation cannot match the quality of professional translators. Huawei shall not bear any responsibility for translation accuracy and it is recommended that you refer to the English document (a link for which has been provided).
Example for Configuring a BGP Confederation

Example for Configuring a BGP Confederation

Networking Requirements

In Figure 9-51, there are multiple BGP switches in AS 200. It is required that the number of IBGP connections be reduced.

NOTE:

In this scenario, ensure that all connected interfaces have STP disabled. If STP is enabled and VLANIF interfaces of switches are used to construct a Layer 3 ring network, an interface on the network will be blocked. As a result, Layer 3 services on the network cannot run normally.

Figure 9-51  Networking diagram of configuring a BGP confederation

Configuration Roadmap

The configuration roadmap is as follows:

  1. Configure a BGP confederation on each switch in AS 200 to divide AS 200 into three sub-ASs: AS 65001, AS 65002, and AS 65003. Three switches in AS 65001 establish full-mesh IBGP connections to reduce the number of IBGP connections.

Procedure

  1. Create VLANs and add interfaces to the corresponding VLANs.

    <HUAWEI> system-view
    [HUAWEI] sysname SwitchA
    [SwitchA] vlan batch 10 20 30 40 60
    [SwitchA] interface gigabitethernet 1/0/1
    [SwitchA-GigabitEthernet1/0/1] port link-type trunk
    [SwitchA-GigabitEthernet1/0/1] port trunk allow-pass vlan 10
    [SwitchA-GigabitEthernet1/0/1] quit
    [SwitchA] interface gigabitethernet 1/0/2
    [SwitchA-GigabitEthernet1/0/2] port link-type trunk
    [SwitchA-GigabitEthernet1/0/2] port trunk allow-pass vlan 20
    [SwitchA-GigabitEthernet1/0/2] quit
    [SwitchA] interface gigabitethernet 1/0/3
    [SwitchA-GigabitEthernet1/0/3] port link-type trunk
    [SwitchA-GigabitEthernet1/0/3] port trunk allow-pass vlan 30
    [SwitchA-GigabitEthernet1/0/3] quit
    [SwitchA] interface gigabitethernet 1/0/4
    [SwitchA-GigabitEthernet1/0/4] port link-type trunk
    [SwitchA-GigabitEthernet1/0/4] port trunk allow-pass vlan 40
    [SwitchA-GigabitEthernet1/0/4] quit
    [SwitchA] interface gigabitethernet 2/0/1
    [SwitchA-GigabitEthernet2/0/1] port link-type trunk
    [SwitchA-GigabitEthernet2/0/1] port trunk allow-pass vlan 60
    [SwitchA-GigabitEthernet2/0/1] quit
    

    The configurations of SwitchB, SwitchC, SwitchD, SwitchE, and SwitchF are similar to the configuration of SwitchA, and are not mentioned here.

  2. Assign an IP address to each VLANIF interface.

    [SwitchA] interface vlanif 10
    [SwitchA-Vlanif10] ip address 10.1.1.1 24
    [SwitchA-Vlanif10] quit
    [SwitchA] interface vlanif 20
    [SwitchA-Vlanif20] ip address 10.1.2.1 24
    [SwitchA-Vlanif20] quit
    [SwitchA] interface vlanif 30
    [SwitchA-Vlanif30] ip address 10.1.3.1 24
    [SwitchA-Vlanif30] quit
    [SwitchA] interface vlanif 40
    [SwitchA-Vlanif40] ip address 10.1.4.1 24
    [SwitchA-Vlanif40] quit
    [SwitchA] interface vlanif 60
    [SwitchA-Vlanif60] ip address 192.168.1.1 24
    [SwitchA-Vlanif60] quit

    The configurations of SwitchB, SwitchC, SwitchD, SwitchE, and SwitchF are similar to the configuration of SwitchA, and are not mentioned here.

  3. Configure the BGP confederation.

    # Configure SwitchA.

    [SwitchA] bgp 65001
    [SwitchA-bgp] router-id 172.16.1.1
    [SwitchA-bgp] confederation id 200
    [SwitchA-bgp] confederation peer-as 65002 65003
    [SwitchA-bgp] peer 10.1.1.2 as-number 65002 
    [SwitchA-bgp] peer 10.1.2.2 as-number 65003
    [SwitchA-bgp] ipv4-family unicast 
    [SwitchA-bgp-af-ipv4] peer 10.1.1.2 next-hop-local
    [SwitchA-bgp-af-ipv4] peer 10.1.2.2 next-hop-local 
    [SwitchA-bgp-af-ipv4] quit
    [SwitchA-bgp] quit

    # Configure SwitchB.

    [SwitchB] bgp 65002
    [SwitchB-bgp] router-id 172.16.2.2
    [SwitchB-bgp] confederation id 200
    [SwitchB-bgp] confederation peer-as 65001 65003
    [SwitchB-bgp] peer 10.1.1.1 as-number 65001
    [SwitchB-bgp] quit

    # Configure SwitchC.

    [SwitchC] bgp 65003
    [SwitchC-bgp] router-id 172.16.3.3
    [SwitchC-bgp] confederation id 200
    [SwitchC-bgp] confederation peer-as 65001 65002
    [SwitchC-bgp] peer 10.1.2.1 as-number 65001
    [SwitchC-bgp] quit

  4. Establish IBGP connection in AS 65001.

    # Configure SwitchA.

    [SwitchA] bgp 65001
    [SwitchA-bgp] peer 10.1.3.2 as-number 65001
    [SwitchA-bgp] peer 10.1.4.2 as-number 65001
    [SwitchA-bgp] ipv4-family unicast
    [SwitchA-bgp-af-ipv4] peer 10.1.3.2 next-hop-local
    [SwitchA-bgp-af-ipv4] peer 10.1.4.2 next-hop-local
    [SwitchA-bgp-af-ipv4] quit 

    # Configure SwitchD.

    [SwitchD] bgp 65001
    [SwitchD-bgp] router-id 172.16.4.4
    [SwitchD-bgp] peer 10.1.3.1 as-number 65001
    [SwitchD-bgp] peer 10.1.5.2 as-number 65001 
    [SwitchD-bgp] quit

    # Configure SwitchE.

    [SwitchE] bgp 65001
    [SwitchE-bgp] router-id 172.16.5.5
    [SwitchE-bgp] peer 10.1.4.1 as-number 65001
    [SwitchE-bgp] peer 10.1.5.1 as-number 65001 
    [SwitchE-bgp] quit

  5. Establish an EBGP connection between AS 100 and AS 200.

    # Configure SwitchA.

    [SwitchA] bgp 65001
    [SwitchA-bgp] peer 192.168.1.2 as-number 100 
    [SwitchA-bgp] quit

    # Configure SwitchF.

    [SwitchF] bgp 100
    [SwitchF-bgp] router-id 172.16.6.6 
    [SwitchF-bgp] peer 192.168.1.1 as-number 200 
    [SwitchF-bgp] ipv4-family unicast 
    [SwitchF-bgp-af-ipv4] network 10.0.1.0 255.255.255.0
    [SwitchF-bgp-af-ipv4] quit
    [SwitchF-bgp] quit

  6. Verify the configuration.

    # Check the BGP routing table of SwitchB.

    [SwitchB] display bgp routing-table
     
     BGP Local router ID is 172.16.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: 1
     
         Network            NextHop        MED        LocPrf    PrefVal Path/Ogn
     
     *>i  10.0.1.0/24        10.1.1.1        0          100        0      (65001) 100i
    [SwitchB] display bgp routing-table 10.0.1.0
    
    BGP local router ID : 172.16.2.2
     Local AS number : 65002
     Paths:   1 available, 1 best, 1 select
     BGP routing table entry information of 10.0.1.0/24:
     From: 10.1.1.1 (172.16.1.1)
     Route Duration: 00h01m22s
     Relay IP Nexthop: 0.0.0.0
     Relay IP Out-Interface: Vlanif10
     Original nexthop: 10.1.1.1
     Qos information : 0x0
     AS-path (65001) 100, origin igp, MED 0, localpref 100, pref-val 0, valid, external-confed, best,select, active, pre 255
     Not advertised to any peer yet
     

    # Check the BGP routing table of SwitchD.

    [SwitchD] display bgp routing-table
     
     BGP Local router ID is 172.16.4.4
     Status codes: * - valid, > - best, d - damped,
                   h - history,  i - internal, s - suppressed, S - Stale
                   Origin : i - IGP, e - EGP, ? - incomplete
     
     Total Number of Routes: 1
         Network            NextHop        MED        LocPrf    PrefVal Path/Ogn
     
     *>i  10.0.1.0/24        10.1.3.1        0          100        0      100i
    [SwitchD] display bgp routing-table 10.0.1.0
     
     BGP local router ID : 172.16.4.4
     Local AS number : 65001
     Paths:   1 available, 1 best, 1 select
     BGP routing table entry information of 10.0.1.0/24:
     From: 10.1.3.1 (172.16.1.1)
     Route Duration: 00h18m34s
     Relay IP Nexthop: 0.0.0.0
     Relay IP Out-Interface: Vlanif30
     Original nexthop: 10.1.3.1
     Qos information : 0x0
     AS-path 100, origin igp, MED 0, localpref 100, pref-val 0, valid, internal, best,select, active, pre 255
     Not advertised to any peer yet
    

Configuration Files

  • SwitchA configuration file

    #
    sysname SwitchA
    #
    vlan batch 10 20 30 40 60
    #
    interface Vlanif10
     ip address 10.1.1.1 255.255.255.0
    #
    interface Vlanif20
     ip address 10.1.2.1 255.255.255.0
    #
    interface Vlanif30
     ip address 10.1.3.1 255.255.255.0
    #
    interface Vlanif40
     ip address 10.1.4.1 255.255.255.0
    #
    interface Vlanif60
     ip address 192.168.1.1 255.255.255.0
    #
    interface GigabitEthernet1/0/1
     port link-type trunk
     port trunk allow-pass vlan 10
    #
    interface GigabitEthernet1/0/2
     port link-type trunk
     port trunk allow-pass vlan 20
    #
    interface GigabitEthernet1/0/3
     port link-type trunk
     port trunk allow-pass vlan 30
    #
    interface GigabitEthernet1/0/4
     port link-type trunk
     port trunk allow-pass vlan 40
    #
    interface GigabitEthernet2/0/1
     port link-type trunk
     port trunk allow-pass vlan 60
    #
    bgp 65001
     router-id 172.16.1.1
     confederation id 200
     confederation peer-as 65002 65003
     peer 10.1.1.2 as-number 65002
     peer 10.1.2.2 as-number 65003
     peer 10.1.3.2 as-number 65001
     peer 10.1.4.2 as-number 65001
     peer 192.168.1.2 as-number 100
     #
     ipv4-family unicast
      undo synchronization
      peer 10.1.1.2 enable
      peer 10.1.1.2 next-hop-local
      peer 10.1.2.2 enable
      peer 10.1.2.2 next-hop-local
      peer 10.1.3.2 enable
      peer 10.1.3.2 next-hop-local
      peer 10.1.4.2 enable
      peer 10.1.4.2 next-hop-local
      peer 192.168.1.2 enable
    #
    return
  • SwitchB configuration file

    #
    sysname SwitchB
    #
    vlan batch 10
    #
    interface Vlanif10
     ip address 10.1.1.2 255.255.255.0
    #
    interface GigabitEthernet1/0/1
     port link-type trunk
     port trunk allow-pass vlan 10
    #
    bgp 65002
     router-id 172.16.2.2
     confederation id 200
     confederation peer-as 65001 65003
     peer 10.1.1.1 as-number 65001
     #
     ipv4-family unicast
      undo synchronization
      peer 10.1.1.1 enable
    #
    return
  • SwitchC configuration file

    #
    sysname SwitchC
    #
    vlan batch 20
    #
    interface Vlanif20
     ip address 10.1.2.2 255.255.255.0
    #
    interface GigabitEthernet1/0/1
     port link-type trunk
     port trunk allow-pass vlan 20
    #
    bgp 65003
     router-id 172.16.3.3
     confederation id 200
     confederation peer-as 65001 65002
     peer 10.1.2.1 as-number 65001
     #
     ipv4-family unicast
      undo synchronization
      peer 10.1.2.1 enable
    #
    return
  • SwitchD configuration file

    #
    sysname SwitchD
    #
    vlan batch 30 50
    #
    interface Vlanif30
     ip address 10.1.3.2 255.255.255.0
    #
    interface Vlanif50
     ip address 10.1.5.1 255.255.255.0
    #
    interface GigabitEthernet1/0/1
     port link-type trunk
     port trunk allow-pass vlan 30
    #
    interface GigabitEthernet1/0/2
     port link-type trunk
     port trunk allow-pass vlan 50
    #
    bgp 65001
     router-id 172.16.4.4
     peer 10.1.3.1 as-number 65001
     peer 10.1.5.2 as-number 65001
     #
     ipv4-family unicast
      undo synchronization
      peer 10.1.3.1 enable
      peer 10.1.5.2 enable
    #
    return
  • SwitchE configuration file

    #
    sysname SwitchE
    #
    vlan batch 40 50
    #
    interface Vlanif40
     ip address 10.1.4.2 255.255.255.0
    #
    interface Vlanif50
     ip address 10.1.5.2 255.255.255.0
    #
    interface GigabitEthernet1/0/1
     port link-type trunk
     port trunk allow-pass vlan 40
    #
    interface GigabitEthernet1/0/2
     port link-type trunk
     port trunk allow-pass vlan 50
    #
    bgp 65001
     router-id 172.16.5.5
     peer 10.1.4.1 as-number 65001
     peer 10.1.5.1 as-number 65001
     #
     ipv4-family unicast
      undo synchronization
      peer 10.1.4.1 enable
      peer 10.1.5.1 enable
    #
    return
  • SwitchF configuration file

    #
    sysname SwitchF
    #
    vlan batch 60 70
    #
    interface Vlanif60
     ip address 192.168.1.2 255.255.255.0
    #
    interface Vlanif70
     ip address 10.0.1.1 255.255.255.0
    #
    interface GigabitEthernet1/0/1
     port link-type trunk
     port trunk allow-pass vlan 60
    #
    interface GigabitEthernet1/0/2
     port link-type trunk
     port trunk allow-pass vlan 70
    #
    bgp 100
     router-id 172.16.6.6
     peer 192.168.1.1 as-number 200
     #
     ipv4-family unicast
      undo synchronization  
      network 10.0.1.0 255.255.255.0
      peer 192.168.1.1 enable
    #          
    return
Translation
Download
Updated: 2019-04-01

Document ID: EDOC1000178324

Views: 204688

Downloads: 178

Average rating:
This Document Applies to these Products
Related Documents
Related Version
Share
Previous Next