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

NE20E-S2 V800R010C10SPC500 Configuration Guide - IP Services 01

This is NE20E-S2 V800R010C10SPC500 Configuration Guide - IP Services

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 Address Overlapping

Example for Configuring Address Overlapping

This section provides an example for configuring IP address overlapping on a device.

Networking Requirements

As shown in Figure 9-7, Network A and Network B are independent of each other. They access the Internet through different paths. Network A and Network B access each other through the same Layer 2 network provided by ISP1.

To allow Network A and Network B to connect to the Layer 2 network provided by ISP1 through Device B by using IP addresses 192.168.1.11/24 and 192.168.1.12/24 respectively on the same network segment, configure address overlapping on Device B.

Figure 9-7 Configuring address overlapping on a device
NOTE:

Interfaces 1 through 4 in this example are GE 0/1/0, GE 0/2/0, GE0/3/0, GE0/1/8, respectively.



Precautions

None

Procedure

  1. Configure a VPN instance.

    # On Device B, create a VPN instance for Network A, and bind the VPN instance to the upstream interface GE 0/1/0 and the downstream interface GE 0/2/0.

    <HUAWEI> system-view
    [~HUAWEI] sysname DeviceB
    [*HUAWEI] commit
    [~DeviceB] ip vpn-instance r1
    [*DeviceB-vpn-instance-r1] route-distinguisher 100:1
    [*DeviceB-vpn-instance-r1] quit
    [*DeviceB] interface gigabitethernet 0/1/0
    [*DeviceB-GigabitEthernet0/1/0] ip binding vpn-instance r1
    [*DeviceB-GigabitEthernet0/1/0] ip address 192.168.1.11 24
    [*DeviceB-GigabitEthernet0/1/0] undo shutdown
    [*DeviceB-GigabitEthernet0/1/0] quit
    [*DeviceB] interface GigabitEthernet 0/2/0
    [*DeviceB-GigabitEthernet0/2/0] ip binding vpn-instance r1
    [*DeviceB-GigabitEthernet0/2/0] ip address 10.1.1.1 24
    [*DeviceB-GigabitEthernet0/2/0] undo shutdown
    [*DeviceB-GigabitEthernet0/2/0] quit

    # On Device B, create a VPN instance for Network B, and bind the VPN instance to the upstream interface GE 0/3/0 and the downstream interface GE 0/1/8.

    [*DeviceB] ip vpn-instance r2
    [*DeviceB-vpn-instance-r2] route-distinguisher 100:2
    [*DeviceB-vpn-instance-r2] quit
    [*DeviceB] interface gigabitethernet 0/3/0
    [*DeviceB-GigabitEthernet0/3/0] ip binding vpn-instance r2
    [*DeviceB-GigabitEthernet0/3/0] ip address 192.168.1.12 24
    [*DeviceB-GigabitEthernet0/3/0] undo shutdown
    [*DeviceB-GigabitEthernet0/3/0] quit
    [*DeviceB] interface GigabitEthernet 0/1/8
    [*DeviceB-GigabitEthernet0/1/8] ip binding vpn-instance r2
    [*DeviceB-GigabitEthernet0/1/8] ip address 10.2.1.1 24
    [*DeviceB-GigabitEthernet0/1/8] undo shutdown
    [*DeviceB-GigabitEthernet0/1/8] quit

    # On Device B, configure static routes for the two VPN instances.

    [*DeviceB] ip route-static vpn-instance r1 0.0.0.0 0 192.168.1.1
    [*DeviceB] ip route-static vpn-instance r2 0.0.0.0 0 192.168.1.1
    [*DeviceB] commit

  2. Establish EBGP neighbor relationships between Device A and the two upstream interfaces on Device B.

    # Configure Device B.

    [~DeviceB] bgp 200
    [*DeviceB-bgp] router-id 100.1.1.1
    [*DeviceB-bgp] ipv4-family vpn-instance r1
    [*DeviceB-bgp-r1] peer 192.168.1.1 as-number 100
    [*DeviceB-bgp-r1] import-route direct
    [*DeviceB-bgp-r1] quit
    [*DeviceB-bgp] ipv4-family vpn-instance r2
    [*DeviceB-bgp-r2] peer 192.168.1.1 as-number 100
    [*DeviceB-bgp-r2] import-route direct
    [*DeviceB-bgp-r2] commit
    [~DeviceB-bgp-r2] quit

    # Configure Device A.

    <HUAWEI> system-view
    [~HUAWEI] sysname DeviceA
    [*HUAWEI] commit
    [~DeviceA] interface gigabitethernet 0/1/0
    [~DeviceA-GigabitEthernet0/1/0] ip address 192.168.1.1 24
    [*DeviceA-GigabitEthernet0/1/0] undo shutdown
    [*DeviceA-GigabitEthernet0/1/0] quit
    [*DeviceA] bgp 100
    [*DeviceA-bgp] peer 192.168.1.11 as-number 200
    [*DeviceA-bgp] peer 192.168.1.12 as-number 200
    [*DeviceA-bgp] commit
    [~DeviceA-bgp] quit

  3. Configure IP addresses and static routes for Device C and Device D on the local network.

    # Configure an IP address and a static route for Device C.

    <HUAWEI> system-view
    [~HUAWEI] sysname DeviceC
    [*HUAWEI] commit
    [~DeviceC] interface GigabitEthernet 0/2/0
    [~DeviceC-GigabitEthernet0/2/0] ip address 10.1.1.2 24
    [*DeviceC-GigabitEthernet0/2/0] undo shutdown
    [*DeviceC-GigabitEthernet0/2/0] quit
    [*DeviceC] ip route-static 0.0.0.0 0 10.1.1.1
    [*DeviceC] commit

    # Configure an IP address and a static route for Device D.

    <HUAWEI> system-view
    [~HUAWEI] sysname DeviceD
    [*HUAWEI] commit
    [~DeviceD] interface GigabitEthernet 0/1/8
    [~DeviceD-GigabitEthernet0/1/8] ip address 10.2.1.2 24
    [*DeviceD-GigabitEthernet0/1/8] undo shutdown
    [*DeviceD-GigabitEthernet0/1/8] quit
    [*DeviceD] ip route-static 0.0.0.0 0 10.2.1.1
    [*DeviceD] commit

  4. Verify the configuration.

    # After the configuration is complete, check the VPN routing table on Device B. The command output shows that the routes of the two local networks connected to Device B belong to two VPN instances r1 and r2, respectively. The routes are isolated.

    [~DeviceB] display ip routing-table vpn-instance r1
    Route Flags: R - relay, D - download
    to fib, T - to vpn-instance, B - black hole route
    ------------------------------------------------------------------------------
    Routing Tables: r1
             Destinations : 6        Routes : 6
    
    Destination/Mask   Proto    Pre  Cost  Flags  NextHop       Interface
    
    0.0.0.0/0          Static  60     0     RD     192.168.1.1   GigabitEthernet0/1/0
    10.1.1.0/24        Direct   0     0     D      10.1.1.1      GigabitEthernet0/2/0
    10.1.1.1/32        Direct   0     0     D      127.0.0.1     GigabitEthernet0/2/0
    10.1.1.2/32        Direct   0     0     D      10.1.1.2      GigabitEthernet0/2/0
    192.168.1.0/24     Direct   0     0     D      192.168.1.11  GigabitEthernet0/1/0
    192.168.1.11/32    Direct   0     0     D      127.0.0.1     GigabitEthernet0/1/0
    [~DeviceB] display ip routing-table vpn-instance r2
    Route Flags: R - relay, D - download
    to fib, T - to vpn-instance, B - black hole route
    ------------------------------------------------------------------------------
    Routing Tables: r2
             Destinations : 6        Routes : 6
    
    Destination/Mask   Proto    Pre  Cost  Flags  NextHop       Interface
    
    0.0.0.0/0           Static  60     0    RD     192.168.1.1    GigabitEthernet0/3/0
    10.2.1.0/24         Direct   0     0    D      10.2.1.1       GigabitEthernet0/1/8
    10.2.1.1/32         Direct   0     0    D      127.0.0.1      GigabitEthernet0/1/8
    10.2.1.2/32         Direct   0     0    D      10.2.1.2       GigabitEthernet0/1/8
    192.168.1.0/24      Direct   0     0    D      192.168.1.12   GigabitEthernet0/3/0
    192.168.1.12/32     Direct   0     0    D      127.0.0.1      GigabitEthernet0/3/0
    
    

    # Run the display ip routing-table command on Device A. The command output shows that the IP routing table on Device A contains the routes to the two local networks.

    [~DeviceA] display ip routing-table
    Route Flags: R - relay, D - download
    to fib, T - to vpn-instance, B - black hole route
    ------------------------------------------------------------------------------
    Routing Tables: Public
             Destinations : 8        Routes : 8
    
    Destination/Mask  Proto  Pre   Cost   Flags   NextHop         Interface
    
    10.1.1.0/24       BGP    255    0       D     192.168.1.11    GigabitEthernet0/1/0
    10.1.1.2/32       BGP    255    0       D     192.168.1.11    GigabitEthernet0/1/0
    10.2.1.0/24       BGP    255    0       D     192.168.1.12    GigabitEthernet0/1/0
    10.2.1.2/32       BGP    255    0       D     192.168.1.12    GigabitEthernet0/1/0
    127.0.0.0/8       Direct   0    0       D     127.0.0.1       InLoopBack0
    127.0.0.1/32      Direct   0    0       D     127.0.0.1       InLoopBack0
    192.168.1.0/24    Direct   0    0       D     192.168.1.1     GigabitEthernet0/1/0
    192.168.1.1/32    Direct   0    0       D     127.0.0.1       GigabitEthernet0/1/0
    

    Devices on the two local networks, Network A and Network B, can ping each other.

Configuration Files

  • Device A configuration file

    #
     sysname DeviceA
    #
    interface GigabitEthernet0/1/0
     undo shutdown
     ip address 192.168.1.1 255.255.255.0
    #
    bgp 100
     peer 192.168.1.11 as-number 200
     peer 192.168.1.12 as-number 200
     #
     ipv4-family unicast
      undo synchronization
      peer 192.168.1.11 enable
      peer 192.168.1.12 enable
    #
    return
  • Device B configuration file

    #
     sysname DeviceB
    #
    ip vpn-instance r1
     ipv4-family
      route-distinguisher 100:1
    #
    ip vpn-instance r2
     ipv4-family
      route-distinguisher 100:2
    #
    interface GigabitEthernet0/1/0
     undo shutdown
     ip binding vpn-instance r1
     ip address 192.168.1.11 255.255.255.0
    #
    interface GigabitEthernet0/3/0
     undo shutdown
     ip binding vpn-instance r2
     ip address 192.168.1.12 255.255.255.0
    #
    interface GigabitEthernet0/2/0
     undo shutdown
     ip binding vpn-instance r1
     ip address 10.1.1.1 255.255.255.0
    #
    interface GigabitEthernet0/1/8
     undo shutdown
     ip binding vpn-instance r2
     ip address 10.2.1.1 255.255.255.0
    #
    bgp 200
     router-id 100.1.1.1
     #
     ipv4-family unicast
      undo synchronization
     #
     ipv4-family vpn-instance r1
      import-route direct
      peer 192.168.1.1 as-number 100
     #
     ipv4-family vpn-instance r2
      import-route direct
      peer 192.168.1.1 as-number 100
    #
     ip route-static vpn-instance r1 0.0.0.0 0.0.0.0 192.168.1.1
     ip route-static vpn-instance r2 0.0.0.0 0.0.0.0 192.168.1.1
    #
    return
  • Device C configuration file

    #
     sysname DeviceC
    #
    interface GigabitEthernet 0/2/0
     undo shutdown
     ip address 10.1.1.2 255.255.255.0
    #
    ip route-static 0.0.0.0 0.0.0.0 10.1.1.1
    #
    return
  • Device D configuration file

    #
     sysname DeviceD
    #
    interface GigabitEthernet 0/1/8
     undo shutdown
     ip address 10.2.1.2 255.255.255.0
    #
    ip route-static 0.0.0.0 0.0.0.0 10.2.1.1
    #
    Return
Translation
Download
Updated: 2019-01-02

Document ID: EDOC1100055376

Views: 21928

Downloads: 48

Average rating:
This Document Applies to these Products

Related Version

Related Documents

Share
Previous Next