例图:
要求: 1.全网ip地址段为192.168.1.0 /24
2.所有pc通过dhcp获取IP地址
3.全网可达
分析:1.子网划分
2.配置g0/0/0,g0/0/1的网关
3.开启DHCP,创建地址池,并调用
4.全网可达
配置:
1.把192.168.1.0 /24划分为两个网段 为 192.168.1.0 /25 和192.168.1.128 /25
2.给g0/0/0和g0/0/1配置ip
[r1]interface g0/0/0
[r1-GigabitEthernet0/0/0]ip address 192.168.1.1 25
Aug 12 2022 17:02:29-08:00 r1 %%01IFNET/4/LINK_STATE(l)[2]:The line protocol IP
on the interface GigabitEthernet0/0/0 has entered the UP state.
[r1]interface g0/0/1
[r1-GigabitEthernet0/0/1]ip address 192.168.1.129 25
Aug 12 2022 17:03:41-08:00 r1 %%01IFNET/4/LINK_STATE(l)[3]:The line protocol IP
on the interface GigabitEthernet0/0/1 has entered the UP state. <