Problems with masks

--

--

Layer 3 switch without routing function enabled

Set up two vlans

Some setup commands:

  #vlan 10 //Add vlan 10

  #vlan 20 //Add vlan 20

  #interface vlan 10 //Configure vlan 10

  #ip add 10.0.0.255 255.255.255.0

  #no shut

  #exit

  #interface vlan 20 //Configure vlan 20

  #ip add 10.0.1.255 255.255.255.0

  #no shut

  #exit

  #exit

  #write

Set IP addresses and corresponding masks on the six hosts. As a result, hosts in vlan 10 can ping each other, hosts in vlan 20 can ping each other, and hosts in vlan 10 and vlan 20 cannot ping each other.

---------------------------------------------

If the masks of hosts ③ and ⑥ are modified to 255.255.0.0

Then the communicable conditions of the six hosts are:

Analyze the situation of host ⑥ ping host ①:

The host ⑥ local ARP cache is empty, the host ⑥ sends ARP to broadcast its own MAC, and the host ⑥ sends an ARP packet to query the MAC of ①, ① reply, ⑥ send ICMP packet

------------------------------------------------

Why can host ⑥ ping hosts ① and ③?

Because the switch is not configured with route forwarding, the switch forwards the ARP broadcast query to all hosts on the second layer.

Then why does it fail when the host ⑥ pings the host ②?

 -----------------------------------------------

Software bug?

Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=325833363&siteId=291194637