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 the Same Network Segment

Example for Configuring Auto-Config on the Same Network Segment

Networking Requirements

As shown in Figure 2-5, in the network deployment for a residential community, the aggregation device RouterD is connected to new Routers (such as RouterA, RouterB, and RouterC) on each layer of buildings in the residential community.

Users want to load the same system software, patch file, and configuration file on all the Routers on layers. Besides, to save manpower costs and deployment time of many Routers, the Routers are required to be automatically configured with the same configuration.

Figure 2-5  Configuring Auto-Config on the Same Network Segment

Configuration Roadmap

The configuration roadmap is as follows:
  1. Directly connect RouterF to RouterD and configure RouterF as the SFTP server. Configure an default route on RouterF so that RouterF can communicate with other device.
  2. Place the configuration file, system software, and patch file to be loaded to the working directory of the SFTP server to ensure that RouterA, RouterB, and RouterC can obtain files to be loaded.
  3. Configure RouterD as the DHCP server to provide network configurations to RouterA, RouterB, and RouterC. Configure information about the system software, patch file, and configuration file in Option 67 and Option 145 because the same files are to be loaded on all the Routers.
  4. Power on RouterA, RouterB, and RouterC, so that the configuration file, system software, and patch file 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.1.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.1.1

  2. Upload the system software, configuration file, and patch file to the SFTP server working directory flash:/autoconfig. Procedures for uploading the files are not mentioned here
  3. Configuring the DHCP server

    <Huawei> system-view
    [Huawei] sysname DHCP Server
    [DHCP Server] dhcp enable
    [DHCP Server] vlan 10
    [DHCP Server-vlan10] quit
    [DHCP Server] interface ethernet 5/0/1
    [DHCP Server-Ethernet5/0/1] port link-type hybrid 
    [DHCP Server-Ethernet5/0/1] port hybrid untagged vlan 10
    [DHCP Server-Ethernet5/0/1] port hybrid pvid vlan 10
    [DHCP Server-Ethernet5/0/1] quit
    [DHCP Server] interface ethernet 5/0/2
    [DHCP Server-Ethernet5/0/2] port link-type hybrid 
    [DHCP Server-Ethernet5/0/2] port hybrid untagged vlan 10
    [DHCP Server-Ethernet5/0/2] port hybrid pvid vlan 10
    [DHCP Server-Ethernet5/0/2] quit
    [DHCP Server] interface ethernet 5/0/3
    [DHCP Server-Ethernet5/0/3] port link-type hybrid 
    [DHCP Server-Ethernet5/0/3] port hybrid untagged vlan 10
    [DHCP Server-Ethernet5/0/3] port hybrid pvid vlan 10
    [DHCP Server-Ethernet5/0/3] quit
    [DHCP Server] interface gigabitEthernet 0/0/1
    [DHCP Server-GigabitEthernet0/0/1] undo portswitch
    [DHCP Server-GigabitEthernet0/0/1] ip address 192.168.1.1 255.255.255.0 
    [DHCP Server-GigabitEthernet0/0/1] quit
    [DHCP Server] interface vlanif 10
    [DHCP Server-Vlanif10] ip address 192.168.2.6 255.255.255.0
    [DHCP Server-Vlanif10] dhcp select global
    [DHCP Server-Vlanif10] quit
    [DHCP Server] ip pool auto-config
    [DHCP Server-ip-pool-auto-config] network 192.168.2.0 mask 255.255.255.0
    [DHCP Server-ip-pool-auto-config] gateway-list 192.168.2.6
    [DHCP Server-ip-pool-auto-config] option 67 ascii ar_V200R010.cfg
    [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.1.6
    [DHCP Server-ip-pool-auto-config] option 145 ascii vrpfile=auto_V200R010.cc;vrpver=V200R010;patchfile=ar_V200R010.pat;
    [DHCP Server-ip-pool-auto-config] option 149 ascii ipaddr=192.168.1.6;port=22;
    
    [DHCP Server-ip-pool-auto-config] quit
    

  4. Power on RouterA, RouterB, and RouterC, and run the Auto-config process
  5. Verify 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. RouterA is used as an example.
    <Huawei> display startup
    MainBoard:                                                                      
      Startup system software:                   flash:/ar_V200R010.cc      
      Next startup system software:              flash:/ar_V200R010.cc     
      Backup system software for next startup:   null                               
      Startup saved-configuration file:          flash:/ar_V200R010.cfg          
      Next startup saved-configuration file:     flash:/ar_V200R010.cfg          
      Startup license file:                      null                               
      Next startup license file:                 null                               
      Startup patch package:                     flash:/ar_V200R010.pat         
      Next startup patch package:                flash:/ar_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.1.6 255.255.255.0 
    #
     sftp server enable
    #
    ip route-static 0.0.0.0 0.0.0.0 192.168.1.1 
    #
    user-interface vty 0 4
     authentication-mode aaa
     protocol inbound ssh
     user privilege level 15
    #
    return
  • Configuration file of the DHCP server

    #
     sysname DHCP Server
    #
    vlan batch 10
    #
     dhcp enable
    #
    ip pool auto-config
     gateway-list 192.168.2.6
     network 192.168.2.0 mask 255.255.255.0
     option 67 ascii ar_V200R003C00.cfg
     option 141 ascii user
     option 142 cipher %@%@djZ=#=yW^UB}YAMrrT;ItpY@%@%@
     option 143 ip-address 192.168.1.6
     option 145 ascii vrpfile=auto_V200R010.cc;vrpver=V200R010;patchfile=ar_V200R010.pat;
     option 149 ascii ipaddr=192.168.1.6;port=22;
    #
    interface Vlanif10
     ip address 192.168.2.6 255.255.255.0
     dhcp select global
    #
    interface Ethernet5/0/1
     port hybrid pvid vlan 10                               
     port hybrid untagged vlan 10
    #
    interface Ethernet5/0/2
     port hybrid pvid vlan 10                           
     port hybrid untagged vlan 10
    #
    interface Ethernet5/0/3
     port hybrid pvid vlan 10                         
     port hybrid untagged vlan 10
    #
    interface GigabitEthernet0/0/1                      
     undo portswitch
     ip address 192.168.1.1 255.255.255.0 
    #
    return
Translation
Download
Updated: 2019-05-20

Document ID: EDOC1100034225

Views: 44953

Downloads: 100

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