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

CLI-based Configuration Guide - Basic Configuration

AR500, AR510, AR531, AR550, AR1500, and AR2500 V200R010

This document provides the basic concepts, configuration procedures, and configuration examples in different application scenarios of the Basic configuration supported by the device.
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 Auto-Config on Different Network Segments

Example for Configuring Auto-Config on Different Network Segments

Networking Requirements

As shown in Figure 2-6, in the network deployment for branches of an enterprise, the newly delivered RouterA, RouterB, and RouterC need to be deployed in branches 1, 2, 3 of an enterprise. The three routers connect to GE0/0/2 of RouterD across the transmission network through their GE0/0/1 interfaces respectively. RouterD functions as the egress gateway of the enterprise and is connected to the headquarters across the Layer 3 network through their GE0/0/1 interfaces.

Users want to load same system software and patch files, and different configuration files on RouterA, RouterB, and RouterC. Besides, to save manpower costs, users want the Routers to be automatically configured with different configurations.

Information about RouterA, RouterB, RouterC, and files to be loaded is as follows:
  • RouterA: MAC address: 0018-82C5-AA89; ESN: 2102310CXK10B6000183; system software: auto_V200R010.cc; system software version: V200R010, patch file: auto_V200R010.pat; configuration file: auto_RouterA.cfg
  • RouterB: MAC address: 0018-82C5-AA90; ESN: 2102310CXK10B6000184; system software: auto_V200R010.cc; system software version: V200R010; patch file: auto_V200R010.pat; configuration file: auto_RouterB.cfg
  • RouterC: MAC address: 0018-82C5-AA91; ESN: 2102310CXK10B6000185; system software: auto_V200R010.cc; system software version: V200R010; patch file: auto_V200R010.pat; configuration file: auto_RouterC.cfg.
Figure 2-6  Configuring Auto-Config on Different Network Segments

Configuration Roadmap

The configuration roadmap is as follows:
  1. Directly connect RouterF to RouterE and configure RouterF as the SFTP server. Configure an default route on RouterF so that RouterF can communicate with other device.
  2. Configure an intermediate file so that RouterA, RouterB, and RouterC can obtain configuration files, system software, and patch files through the intermediate file.
  3. Place the intermediate file, configuration files, system software, and patch files to be loaded to the working directory of the SFTP server to ensure that Routers to be configured can obtain files to be loaded.
  4. Configure the enterprise gateway RouterD as the DHCP relay agent and configure RouterE in the headquarters as the DHCP server so that the DHCP server can deliver network configurations to Routers to be configured on different network segments.
  5. Power on RouterA, RouterB, and RouterC so that configuration files, system software, and patch files are automatically loaded using auto-config.
NOTE:
  • By default, auto-config is enabled on a Router.

Procedure

  1. Configuring RouterF as the SFTP server

    # Set SFTP server parameters.

    <Huawei> system-view
    [Huawei] sysname SFTP Server
    [SFTP Server] rsa local-key-pair create
    The key name will be: Host
    RSA keys defined for Host already exist.
    Confirm to replace them? (y/n)[n]:y
    The range of public key size is (512 ~ 2048).
    NOTES: If the key modulus is less than 2048,
           It will introduce potential security risks.
    Input the bits in the modulus[default = 2048]:2048
    Generating keys...
    ......................................................................................+++
    ....+++
    .......................................++++++++
    ..............++++++++
    
    [SFTP Server] sftp server enable

    # Configuring the VTY user interface for SSH users to log in to the device.

    [SFTP Server] user-interface vty 0 4
    [SFTP Server-ui-vty0-4] authentication-mode aaa
    [SFTP Server-ui-vty0-4] protocol inbound all
    [SFTP Server-ui-vty0-4] user privilege level 15
    [SFTP Server-ui-vty0-4] quit

    # Configuring SSH user information.

    [SFTP Server] aaa
    [SFTP Server-aaa] local-user user password
    Please configure the login password (8-128)                                     
    It is recommended that the password consist of at least 2 types of characters, i
    ncluding lowercase letters, uppercase letters, numerals and special characters. 
    Please enter password:                                                          
    Please confirm password:
    [SFTP Server-aaa] local-user user privilege level 15
    [SFTP Server-aaa] local-user user service-type ssh
    [SFTP Server-aaa] local-user user ftp-directory flash:\autoconfig
    [SFTP Server-aaa] quit
    [SFTP Server] ssh user user authentication-type password

    # Configuring the IP address of the SFTP server.

    [SFTP Server] interface gigabitethernet 0/0/1
    [SFTP Server-GigabitEthernet0/0/1] undo portswitch
    [SFTP Server-GigabitEthernet0/0/1] ip address 192.168.4.6 24
    [SFTP Server-GigabitEthernet0/0/1] quit

    # Configuring an default route on SFTP server.

    [SFTP Server] ip route-static 0.0.0.0 0.0.0.0 192.168.4.1

  2. Configuring an intermediate file arnet.ini

    # Create a file and name the file arnet.ini. The contents and format of the intermediate file are as follows:

    MAC=0018-82C5-AA89;ESN=2102310CXK10B6000183;vrpfile=auto_V200R010.cc;vrpver=V200R010;patchfile=auto_V200R010.pat;cfgfile=auto_RouterA.cfg;
    MAC=0018-82C5-AA90;ESN=2102310CXK10B6000184;vrpfile=auto_V200R010.cc;vrpver=V200R010;patchfile=auto_V200R010.pat;cfgfile=auto_RouterB.cfg;
    MAC=0018-82C5-AA91;ESN=2102310CXK10B6000185;vrpfile=auto_V200R010.cc;vrpver=V200R010;patchfile=auto_V200R010.pat;cfgfile=auto_RouterC.cfg;

  3. Uploading the intermediate file, system software, configuration file, and patch file to the SFTP server working directory flash:\autoconfig. Procedures for upload the files are not mentioned here
  4. Configuring RouterD

    # Configure RouterD as the DHCP relay agent.

    <Huawei> system-view
    [Huawei] sysname DHCP Relay
    [DHCP Relay] dhcp enable
    [DHCP Relay] interface gigabitethernet 0/0/2
    [DHCP Relay-Gigabitethernet0/0/2] undo portswitch
    [DHCP Relay-Gigabitethernet0/0/2] ip address 192.168.1.6 255.255.255.0
    [DHCP Relay-Gigabitethernet0/0/2] dhcp select relay
    [DHCP Relay-Gigabitethernet0/0/2] dhcp relay server-ip 192.168.2.6
    [DHCP Relay-Gigabitethernet0/0/2] quit
    [DHCP Relay] interface gigabitethernet 0/0/1
    [DHCP Relay-Gigabitethernet0/0/1] undo portswitch
    [DHCP Relay-Gigabitethernet0/0/1] ip address 192.168.2.1 255.255.255.0
    [DHCP Relay-Gigabitethernet0/0/1] quit
    [DHCP Relay] ip route-static 192.168.4.0 255.255.255.0 192.168.2.6
    

  5. Configuring RouterE

    # Configure RouterE as the DHCP server.

    <Huawei> system-view
    [Huawei] sysname DHCP Server
    [DHCP Server] dhcp enable
    [DHCP Server] interface GigabitEthernet 0/0/1
    [DHCP Relay-Gigabitethernet0/0/1] undo portswitch
    [DHCP Server-GigabitEthernet0/0/1] ip address 192.168.2.6 255.255.255.0
    [DHCP Server-GigabitEthernet0/0/1] dhcp select global
    [DHCP Server-GigabitEthernet0/0/1] quit
    [DHCP Server] interface GigabitEthernet 0/0/2
    [DHCP Relay-Gigabitethernet0/0/2] undo portswitch
    [DHCP Server-GigabitEthernet0/0/2] ip address 192.168.4.1 255.255.255.0
    [DHCP Server-GigabitEthernet0/0/2] quit
    [DHCP Server] ip pool auto-config
    [DHCP Server-ip-pool-auto-config] network 192.168.1.0 mask 255.255.255.0
    [DHCP Server-ip-pool-auto-config] gateway-list 192.168.1.6
    [DHCP Server-ip-pool-auto-config] option 141 ascii user
    [DHCP Server-ip-pool-auto-config] option 142 cipher huawei@123
    [DHCP Server-ip-pool-auto-config] option 143 ip-address 192.168.4.6
    [DHCP Server-ip-pool-auto-config] option 146 ascii opervalue=1;delaytime=0;netfile=arnet.ini;
    [DHCP Server-ip-pool-auto-config] quit
    [DHCP Server] ip route-static 192.168.1.0 255.255.255.0 192.168.2.1

  6. Powering on RouterA, RouterB, and RouterC, and run the Auto-config process
  7. Verifying the configuration

    # After auto-config is finished, log in to the Router to be configured and run the display startup command to view the system software, configuration file, and patch file for the startup of the Router. RouterC is used as an example.
    <Huawei> display startup
    MainBoard:
      Startup system software:                   flash:/auto_V200R010.cc
      Next startup system software:              flash:/auto_V200R010.cc
      Backup system software for next startup:   null
      Startup saved-configuration file:          flash:/auto_RouterC.cfg
      Next startup saved-configuration file:     flash:/auto_RouterC.cfg
      Startup license file:                      null
      Next startup license file:                 null
      Startup patch package:                     flash:/auto_V200R010.pat
      Next startup patch package:                flash:/auto_V200R010.pat
      Startup voice-files:                       null
      Next startup voice-files:                  null        

Configuration Files

  • Configuration file of the SFTP server

    #
     sysname SFTP Server
    #
    aaa
     local-user user ftp-directory flash:\autoconfig
     local-user user password cipher %$%$c|-D8KO4/,B[(FR.r!LHg]TK%$%$
     local-user user privilege level 15
     local-user user service-type ssh
    #
    interface GigabitEthernet0/0/1                      
     undo portswitch
     ip address 192.168.4.6 255.255.255.0 
    #
     sftp server enable
    #
    ip route-static 0.0.0.0 0.0.0.0 192.168.4.1 
    #
    user-interface vty 0 4
     authentication-mode aaa
     protocol inbound ssh
     user privilege level 15
    #
    return
  • Configuration file of the DHCP relay agent

    #                                                                               
     sysname DHCP Relay   
    #                                                                               
     dhcp enable                                                                    
    #                                                                               
    interface GigabitEthernet0/0/1                                                  
     undo portswitch
     ip address 192.168.2.1 255.255.255.0                                           
    #                                        
    interface GigabitEthernet0/0/2                                                  
     undo portswitch
     ip address 192.168.1.6 255.255.255.0                                           
     dhcp select relay                                                              
     dhcp relay server-ip 192.168.2.6 
    #                                                                               
    ip route-static 192.168.4.0 255.255.255.0 192.168.2.6
    #                                                                               
    return 
  • Configuration file of the DHCP server

    #
     sysname DHCP Server
    #
     dhcp enable
    #
    ip pool auto-config
     gateway-list 192.168.1.6
     network 192.168.1.0 mask 255.255.255.0
     option 141 ascii user
     option 142 cipher %@%@djZ=#=yW^UB}YAMrrT;ItpY@%@%@
     option 143 ip-address 192.168.4.6
     option 146 ascii opervalue=1;delaytime=0;netfile=arnet.ini;
    #
    interface GigabitEthernet0/0/1
     undo portswitch
     ip address 192.168.2.6 255.255.255.0
     dhcp select global
    #
    interface GigabitEthernet0/0/2
     undo portswitch
     ip address 192.168.4.1 255.255.255.0
    #
    ip route-static 192.168.1.0 255.255.255.0 192.168.2.1
    #
    return 
Translation
Download
Updated: 2019-05-20

Document ID: EDOC1100034225

Views: 44709

Downloads: 100

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