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 V200R013C00

This document describes the configurations of IP Unicast Routing, including IP Routing, Static Route, RIP, RIPng, OSPF, OSPFv3, IPv4 IS-IS, IPv6 IS-IS, BGP, Routing Policy, IP Routing Table Management, and PBR.
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 OSPFv3 Areas

Example for Configuring OSPFv3 Areas

Networking Requirements

In Figure 6-12, OSPFv3 is enabled on all Switches, and the AS is divided into three areas. SwitchB and SwitchC serve as ABRs to forward inter-area routes.

To reduce the LSAs advertised to Area 2 without affecting the reachability of routes, Area 2 must be configured as a stub area.

Figure 6-12  Networking diagram for configuring an OSPFv3 area

Configuration Roadmap

The configuration roadmap is as follows:

  1. Configure IPv6 addresses for interfaces.

  2. Enable basic OSPFv3 functions on each switch.

  3. Configure Area 2 as a stub area. Then check the OSPFv3 routing table of SwitchD to verify this configuration.

  4. Configure Area 2 as a totally stub area. Then check the OSPFv3 routing table of SwitchD to verify this configuration.

Procedure

  1. Add interfaces to VLANs.

    # Configure SwitchA. Ensure that the configurations of SwitchB, SwitchC, and SwitchD are the same as that of SwitchA.

    <HUAWEI> system-view
    [HUAWEI] sysname SwitchA
    [SwitchA] vlan 10
    [SwitchA-vlan10] quit
    [SwitchA] interface gigabitethernet 3/0/0
    [SwitchA-GigabitEthernet3/0/0] port link-type trunk
    [SwitchA-GigabitEthernet3/0/0] port trunk allow-pass vlan 10
    [SwitchA-GigabitEthernet3/0/0] quit
    [SwitchA] vlan 20
    [SwitchA-vlan20] quit
    [SwitchA] interface gigabitethernet 1/0/0
    [SwitchA-GigabitEthernet1/0/0] port link-type trunk
    [SwitchA-GigabitEthernet1/0/0] port trunk allow-pass vlan 20
    [SwitchA-GigabitEthernet1/0/0] quit

  2. Assign IPv6 addresses to the VLANIF interfaces.

    # Configure SwitchA. Ensure that the configurations of SwitchB, SwitchC, and SwitchD are the same as that of SwitchA.

    [SwitchA] ipv6
    [SwitchA] interface vlanif 10
    [SwitchA-Vlanif10] ipv6 enable
    [SwitchA-Vlanif10] ipv6 address fc00:0:0:2000::1/64
    [SwitchA-Vlanif10] quit
    [SwitchA] interface vlanif 20
    [SwitchA-Vlanif20] ipv6 enable
    [SwitchA-Vlanif20] ipv6 address fc00:0:0:1001::2/64
    [SwitchA-Vlanif20] quit

  3. Configure basic OSPFv3 functions.

    # Configure SwitchA.

    [SwitchA] ospfv3
    [SwitchA-ospfv3-1] router-id 10.1.1.1
    [SwitchA-ospfv3-1] quit
    [SwitchA] interface vlanif 10
    [SwitchA-Vlanif10] ospfv3 1 area 1
    [SwitchA-Vlanif10] quit
    [SwitchA] interface vlanif 20
    [SwitchA-Vlanif20] ospfv3 1 area 1
    [SwitchA-Vlanif20] quit

    # Configure SwitchB.

    [SwitchB] ospfv3
    [SwitchB-ospfv3-1] router-id 10.2.2.2
    [SwitchB-ospfv3-1] quit
    [SwitchB] interface vlanif 20
    [SwitchB-Vlanif20] ospfv3 1 area 1
    [SwitchB-Vlanif20] quit
    [SwitchB] interface vlanif 30
    [SwitchB-Vlanif30] ospfv3 1 area 0
    [SwitchB-Vlanif30] quit

    # Configure SwitchC.

    [SwitchC] ospfv3
    [SwitchC-ospfv3-1] router-id 10.3.3.3
    [SwitchC-ospfv3-1] quit
    [SwitchC] interface vlanif 30
    [SwitchC-Vlanif30] ospfv3 1 area 0
    [SwitchC-Vlanif30] quit
    [SwitchC] interface vlanif 40
    [SwitchC-Vlanif40] ospfv3 1 area 2
    [SwitchC-Vlanif40] quit

    # Configure SwitchD.

    [SwitchD] ospfv3
    [SwitchD-ospfv3-1] router-id 10.4.4.4
    [SwitchD-ospfv3-1] quit
    [SwitchD] interface vlanif 40
    [SwitchD-Vlanif40] ospfv3 1 area 2
    [SwitchD-Vlanif40] quit

    # Check the status of the OSPFv3 neighbors of SwitchB.

    [SwitchB] display ospfv3 peer
    OSPFv3 Process (1)
    OSPFv3 Area (0.0.0.0)
    Neighbor ID     Pri   State            Dead Time   Interface  Instance ID
    10.3.3.3          1   Full/DR          00:00:32    Vlanif30           0
    OSPFv3 Area (0.0.0.1)
    Neighbor ID     Pri   State            Dead Time   Interface  Instance ID  
    10.1.1.1          1   Full/Backup      00:00:34    Vlanif20           0
    

    # Check the status of the OSPFv3 neighbors of SwitchC.

    [SwitchC] display ospfv3 peer
    OSPFv3 Process (1)
    OSPFv3 Area (0.0.0.0)
    Neighbor ID     Pri   State            Dead Time   Interface  Instance ID
    10.2.2.2          1   Full/DR          00:00:37    Vlanif30           0
    OSPFv3 Area (0.0.0.2)
    Neighbor ID     Pri   State            Dead Time   Interface  Instance ID
    10.4.4.4          1   Full/Backup      00:00:33    Vlanif40           0
    

    # Check the OSPFv3 routing table of SwitchD.

    [SwitchD] display ospfv3 routing
    
    Codes : E2 - Type 2 External, E1 - Type 1 External, IA - Inter-Area,
            N - NSSA, U - Uninstalled, D - Denied by Import Policy
    
    OSPFv3 Process (1)
       Destination                                   Metric
         Next-hop
      IA FC00:0:0:1000::/64                                     2
               via FE80::1572:0:5EF4:1, Vlanif40
      IA FC00:0:0:1001::/64                                     3
               via FE80::1572:0:5EF4:1, Vlanif40
         FC00:0:0:1002::/64                                     1
               directly connected, Vlanif40
      IA FC00:0:0:2000::/64                                     4
               via FE80::1572:0:5EF4:1, Vlanif40

  4. Configure stub attributes.

    # Configure stub attributes on SwitchD.

    [SwitchD] ospfv3
    [SwitchD-ospfv3-1] area 2
    [SwitchD-ospfv3-1-area-0.0.0.2] stub
    [SwitchD-ospfv3-1-area-0.0.0.2] quit
    [SwitchD-ospfv3-1] quit

    # Configure stub attributes on SwitchC, and set the cost of the default route advertised to the stub area to 10.

    [SwitchC] ospfv3
    [SwitchC-ospfv3-1] area 2
    [SwitchC-ospfv3-1-area-0.0.0.2] stub
    [SwitchC-ospfv3-1-area-0.0.0.2] default-cost 10

    # Check the OSPFv3 routing table of SwitchD.

    [SwitchD] display ospfv3 routing
    
    Codes : E2 - Type 2 External, E1 - Type 1 External, IA - Inter-Area,
            N - NSSA, U - Uninstalled, D - Denied by Import Policy
    
    OSPFv3 Process (1)
       Destination                                   Metric
         Next-hop
      IA ::/0                                          2
               via FE80::1572:0:5EF4:1, Vlanif40
      IA FC00:0:0:1000::/64                                     2
               via FE80::1572:0:5EF4:1, Vlanif40
      IA FC00:0:0:1001::/64                                     3
               via FE80::1572:0:5EF4:1, Vlanif40
         FC00:0:0:1002::/64                                     1
               directly connected, Vlanif40
      IA FC00:0:0:2000::/64                                     4
               via FE80::1572:0:5EF4:1, Vlanif40

    There is a new default route in the routing table. The cost of the default route is the sum of the cost of the directly connected routes and the configured cost.

  5. Configure the totally stub area.

    # On SwitchC, configure Area 2 as the totally stub area.

    [SwitchC-ospfv3-1-area-0.0.0.2] stub no-summary

  6. Verify the configuration.

    # Check the OSPFv3 routing table of SwitchD.

    [SwitchD] display ospfv3 routing
    
    Codes : E2 - Type 2 External, E1 - Type 1 External, IA - Inter-Area,
            N - NSSA, U - Uninstalled, D - Denied by Import Policy
    
    OSPFv3 Process (1)
       Destination                                               Metric
         Next-hop
      IA ::/0                                                          2
               via FE80::1572:0:5EF4:1, Vlanif40
         FC00:0:0:1002::/64                                            1
               directly connected, Vlanif40

    The entries in the routing table are reduced, other non-directly connected routes are suppressed, and only the default route is reserved.

Configuration Files

  • SwitchA configuration file

    #
    sysname SwitchA
    #
    ipv6
    #
    vlan batch 10 20
    #
    ospfv3 1
     router-id 10.1.1.1
    #
    interface Vlanif10
     ipv6 enable
     ipv6 address FC00:0:0:2000::1/64
     ospfv3 1 area 0.0.0.1
    #
    interface Vlanif20
     ipv6 enable
     ipv6 address FC00:0:0:1001::2/64
     ospfv3 1 area 0.0.0.1
    #
    interface GigabitEthernet1/0/0
     port link-type trunk
     port trunk allow-pass vlan 20
    #  
    interface GigabitEthernet3/0/0
     port link-type trunk
     port trunk allow-pass vlan 10
    #
    return
  • SwitchB configuration file

    #
    sysname SwitchB
    #
    ipv6
    #
    vlan batch 20 30
    #
    ospfv3 1
     router-id 10.2.2.2
    #
    interface Vlanif20
     ipv6 enable
     ipv6 address FC00:0:0:1001::1/64
     ospfv3 1 area 0.0.0.1
    #
    interface Vlanif30
     ipv6 enable
     ipv6 address FC00:0:0:1000::1/64
     ospfv3 1 area 0.0.0.0
    #
    interface GigabitEthernet1/0/0
     port link-type trunk
     port trunk allow-pass vlan 20
    #  
    interface GigabitEthernet2/0/0
     port link-type trunk
     port trunk allow-pass vlan 30
    #
    return
  • SwitchC configuration file

    #
    sysname SwitchC
    #
    ipv6
    #
    vlan batch 30 40
    #
    ospfv3 1
     router-id 10.3.3.3
     area 0.0.0.2
      stub no-summary
    #
    interface Vlanif30
     ipv6 enable
     ipv6 address FC00:0:0:1000::2/64
     ospfv3 1 area 0.0.0.0
    #
    interface Vlanif40
     ipv6 enable
     ipv6 address FC00:0:0:1002::1/64
     ospfv3 1 area 0.0.0.2
    #
    interface GigabitEthernet1/0/0
     port link-type trunk
     port trunk allow-pass vlan 40
    #  
    interface GigabitEthernet2/0/0
     port link-type trunk
     port trunk allow-pass vlan 30
    #
    return
  • SwitchD configuration file

    #
    sysname SwitchD
    #
    ipv6
    #
    vlan batch 40
    #
    ospfv3 1
     router-id 10.4.4.4
     area 0.0.0.2
      stub
    #
    interface Vlanif40
     ipv6 enable
     ipv6 address FC00:0:0:1002::2/64
     ospfv3 1 area 0.0.0.2
    #
    interface GigabitEthernet2/0/0
     port link-type trunk
     port trunk allow-pass vlan 40
    #
    return
Translation
Download
Updated: 2019-04-08

Document ID: EDOC1100065744

Views: 64514

Downloads: 50

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