MIT course, CS144, Week 1, LPM
On each hop of each packet, a router decides which link to forward the packet over.
x表示任意一个number, wildcards(百搭牌)。dash(/)后面的数字代表block size,为子网掩码,32-掩码为主机位数。因为子网掩码表示从前往后多少位为1.
Longest prefix match
Now, 因为A可以走通either the default or link 3,而link 3 has longer prefix length (30) than default (0),所以走了link 3.
ARP
不同的层需要不同的地址。IP地址只适用于IP layer,而link layer就需要mac地址了, which represents a unique network card. E.g. Eternet card, 出厂时就设置了48bit的Mac地址- 6 octets,separated by colon “:”.
网关需要两个不同的IP地址,分配在两个网卡上。
ARP是广播的,是cache缓存的。一段时间timeout后就不保留这个映射关系。
ARP的packet field, Opocode什么的还有些不懂,之后看ARP补习。