HCIA实验(2):IP地址配置

实验配置是网工的必备技能,今天为大家主讲华为数通HCIA配置实验:IP地址的配置

(全套实验拓扑)

(需要HCIA实验拓扑的小伙伴(如上图所示),直接关注+点赞后留下你的邮箱)

实验:IP地址配置

    • 实验目的

掌握接口IPv4地址的配置方法

    • 实验拓扑

IP地址配置的实验拓扑如图所示:

图 IP地址配置

3、实验步骤

(1)R1的配置

        <Huawei>system-view           //进入到系统视图
        [Huawei]undo info-center enable  //关闭路由器输出信息
        [Huawei]sysname R1            //修改设备名为R1
        [R1]interface g0/0/0            //进入到接口g0/0/0
        [R1-GigabitEthernet0/0/0]ip address 192.168.12.1 24 //配置IP地址和子网掩码
        [R1-GigabitEthernet0/0/0]undo shutdown //打开接口
        [R1-GigabitEthernet0/0/0]quit //退出

(2) 查看R1接口的ip地址

        [R1] display  ip interface brief //查看接口的ip地址
        *down: administratively down //“*”表示该接口被管理员手动关闭,例如在接口执行命令“shutdown”
        ^down: standby //“^”表示该接口是备份接口
        (l): loopback //(l)代表环回
        (s): spoofing //(s)代表欺骗
        The number of interface that is UP in Physical is 2 //表示物理状态up的接口数量为2
        The number of interface that is DOWN in Physical is 2 //表示物理状态down的接口数量为2
        The number of interface that is UP in Protocol is 2 //表示协议状态up的接口数量为2
        The number of interface that is DOWN in Protocol is 2 //表示协议状态down的接口数量为2
         
        Interface                         IP Address/Mask      Physical   Protocol  
        GigabitEthernet0/0/0              192.168.12.1/24      up         up        
        GigabitEthernet0/0/1              unassigned           down       down      
        GigabitEthernet0/0/2              unassigned           down       down      
        NULL0                                     unassigned           up         up(s)

【技术要点】

华为设备上支持两种配置子网掩码的方式:

①点分十进制:[R1-GigabitEthernet0/0/0]ip address 192.168.12.1 255.255.255.0//配置IP地址和子网掩码
②前缀长度:[R1-GigabitEthernet0/0/0]ip address 192.168.12.1 24  //配置IP地址和子网掩码

(3)R2的配置

<Huawei>system-view 
[Huawei]undo info-center enable 
[Huawei]sysname R2
[R2]interface g0/0/1
[R2-GigabitEthernet0/0/1]ip address 192.168.12.2 24
[R2-GigabitEthernet0/0/1]undo shutdown 
[R2-GigabitEthernet0/0/1]quit

4、实验调试

R1访问R2,使用ping命令进行测试

<R1>ping 192.168.12.2 //ping测试192.168.12.2的连通性
 PING 192.168.12.2: 56  data bytes, press CTRL_C to break  //使用CTRL_C可以终止测试
 Reply from 192.168.12.2: bytes=56 Sequence=1 ttl=255 time=70 ms
 Reply from 192.168.12.2: bytes=56 Sequence=2 ttl=255 time=40 ms
Reply from 192.168.12.2: bytes=56 Sequence=3 ttl=255 time=90 ms
Reply from 192.168.12.2: bytes=56 Sequence=4 ttl=255 time=30 ms
Reply from 192.168.12.2: bytes=56 Sequence=5 ttl=255 time=30 ms

--- 192.168.12.2 ping statistics ---
5 packet(s) transmitted //发送五个包
5 packet(s) received //接收到五个包
0.00% packet loss //0%的丢包率
round-trip min/avg/max = 30/52/90 ms //来回旅程延迟分别为最小30ms、最大90ms、平均52ms

【技术要点】

ping命令是最常见的用于检测网络设备可访问性的调试工具,它使用ICMP报文信息可以来检测:

远程设备是否可用。

与远程主机通信的来回旅程(round-trip)的延迟(delay)。

包(packet)的丢失情况。

(全套实验拓扑)

(需要HCIA实验拓扑的小伙伴(如上图所示),直接关注+点赞后留下你的邮箱)

猜你喜欢

转载自blog.csdn.net/yuyeconglong/article/details/128845291