HCIA: ICMP, Telnet, DHCP

ICMP belongs to the network layer—-IP and ARP also belong to the network layer

Transport layer: TCP, UDP

Huawei common basic commands

<huawei>system-view----Switch user view to system view
[huawei]undo----delete
[huawei]quit----Exit to the previous view
[huawei]display----View
<huawei>reboot----Restart the device
[huawei]sysname----Modify the system name
display version----View system version

Telnet

PC side—-use router to represent PC side

[PC]interface GigabitEthernet 0/0/0----Enter the interface
[PC-GigabitEthernet0/0/0]ip address 192.168.1.1 24----Add interface ip and mask information

Server

[Telnet Server]interface GigabitEthernet 0/0/0
[Telnet Server-GigabitEthernet0/0/0]ip address 192.168.1.2 255.255.255.0----The second way to add interface ip and mask

Way

[Telnet Server-GigabitEthernet0/0/0]quit----Exit to the previous view
[Telnet Server]telnet server enable----Already enabled by default, no need to configure this command
[Telnet Server]user-interface vty 04----Enable user interface space
[Telnet Server-ui-vty0-4]authentication-mode aaa----Set to use aaa as the authentication mode of Huawei user interface, that is, the login method
[Telnet Server-ui-vty0-4]quit
[Telnet Server]aaa----Enter AAA view
[Telnet Server-aaa]local-user huawei password cipher 123456----Create username and password
[Telnet Server-aaa]local-user huawei privilege level 15----Set user privilege level
[Teinet Server-aaa]local-user huawei service-type telnet----Set the protocol used by huawei users to log in to the device
[Telnet Server---aaa]display this----View the configuration of the current view

test

DHCP Protocol—-Dynamic Host Configuration Protocol

Problems with manually configuring network parameters

  • For regular users
  • For network administrators
  • IPAddress Waste

DHCP message type

  • discover—-Discovery message—-is used for clients to findDHCP< /strong>Server
  • offer—-The server replies to the client (carryingIPaddress information)— —Also includes network parameters such as gateway, mask,DNS
  • request—-Client formal requestIPInformation
  • ack—-The server confirms the client’s request information
  • nak—-The server rejects the client’s request for information
  • release—-The client sends it to the server to request the release address
  • decline—-After the client detects the conflict, it reports the error to the server
  • inform—-The server sends some configuration information

DHCPLease Period

  • Lease renewal timer—-24H(huawei)
  • When the lease period reaches50%, thePCwill renew the lease. PCwill be sent using requestmessages and are unicast, if the service If the client replies with an ACK message, the lease renewal is successful.
  • Lease rebinding timer—-21H
    • Time exceeded87.5%of the lease period,PCbroadcast sentdiscover Themessage is resent to theDHCPserver in the network. If a server agrees to renew the leasePC
      • If the renewedIP is the firstIPaddress obtained, then >PCRefresh lease update timer time
      • If the renewed IPIPis not theIPaddress obtained for the first time, then strong>PCwill reset the lease renewal timer to 0 and send release The message announces the release of the firstIPaddress, and then replies with the secondofferreport Text to obtain the secondIPaddress
    • If no server replies, the client will give up theIPaddress when the lease expires.
  • Lease expiration timer
    • PCvoluntarily gives up using thisIP
    • PCLease renewal failed

If a rejection message is received during the lease period, the PC must immediately stop using the existing IP address and then apply for an IP address again.

Configuration Process

[DHCP Server]interface GigabitEthernet 0/0/0
[DHCP Server GigabitEthernet0/0/0]ip address 192.168.1.100 24
[DHCP Server]dhcp enable----Start DHCP protocol
[DHCP Serverlip pool aa----Create an address pool named aa
[DHCP Server-ip-pool-aa]network 192.168.1.0 mask 24----Configure the assignable IP address range
[DHCP Server-ip-pool-aalgateway-list 192.168.1.100----Configure gateway information
[DHCP Server-ip-pool-aajdns-list 8.8.8.8----Configure DNS information
[DHCP Server-ip-pool-aajquit
[DHCP Serverjinterface GigabitE thernet 0/0/0
[DHCP Server GigabitEthernet0/0/0Jdhcp select global----Call the global address pool on the interface
[DHCP Server-GigatitEtherrnet0/0/0]quit
[DHCP Server]display ip intertace brief----View the corresponding relationship between IP and interface
[DHCP Server]display ip pool----Zhichun address pool content
[DHCP Server-ip-pool-aa]excluded ip-address 192.168.1.254 192,168.1.254----Excluded address, allocation is not allowed
[DHCP Server-ip-pool-aa]lease day 0 hour 0 minute 10----Set lease time

syntaxbug.com © 2021 All Rights Reserved.