楼主:
quasi (嘉嘉有本难念的经)
2016-06-28 01:07:13想再请教一下关于arp 跟 switch learning的观念
请各位大大指点指点
如图
http://imgur.com/4oPWfPi
请问在最干净的情况下
h1 ping h4会内部会发生什么事情?
h1 会先看自己的 Arp Table 中是否有目的IP的实体位址,
如果有则直接使用此位址来传送封包,否则会送出Arp Request的广播封包。
当 sw1 接收到此广播封包后,
会将来源端 ( h1 ) 的 Mac Address 及 Port Number(h1 - sw1) 记下,
并进行广播,
sw2 会接到此广播封包并记下来源端 ( h1 ) 的 Mac Address及Port Number(sw1 - sw2)
,而 h4 会将此封包收下,并送出Arp Reply封包(目的为h1),
sw2收到Arp Reply会将来源端 ( h4 ) 的 Mac Address 及 Port Number(h4 - sw2) 记下
,之后因为sw2的CAM Table已经有此目的(h1)的纪录了,所以往Port(sw2 - sw1)送出,
sw1收到后,因为sw1的CAM Table中已经有此纪录,所以会传送至 Port (sw1 - h1),
h1即能接收到Arp Reply,之后两端会传送Icmp封包(Echo Request、Echo Reply)。
这是我所想的