Path: utzoo!utgpu!water!watmath!clyde!ima!spdcc!kaos!romkey From: romkey@kaos.UUCP (John Romkey) Newsgroups: comp.dcom.lans Subject: Re: Latest news on our ether errors Message-ID: <678@kaos.UUCP> Date: 23 Feb 88 17:51:20 GMT References: <8403@g.ms.uky.edu> <4097@lll-winken.llnl.gov> Reply-To: romkey@kaos.UUCP (John Romkey) Organization: Chaos; Somerville, MA Lines: 26 In article <4097@lll-winken.llnl.gov> casey@lll-crg.llnl.gov.UUCP (Casey Leedom) writes: >For my own and others' edification would someone explain exactly why >4.2BSD based networking responds with gratuitous ARPs for packets >addressed to xxx.xxx.255.255, etc.? Thanks in advance. When 4.2BSD was released there was no defined standard telling how to broadcast IP datagrams. Berkeley followed an informal standard that said to set the host part (the part that's not net and not subnet) of the IP address to all 0's. So you might see 128.127.0.0 as a broadcast IP address from 4.2, and the 4.2 drivers would know not to bother ARP'ing this packet but to just send it to the ethernet broadcast address instead. Now...later on, in an RFC whose number escapes me at the moment, it was specified that a broadcast datagram should have the host part of its address set to all 1's (128.127.255.255). Since that RFC was made a part of the TCP/IP specification, this is the correct way to do things now. And most systems released since then support that properly. But if you have an application that uses broadcast and follows that standard of using all 1's and you backport it to 4.2BSD, then it will tell the 4.2 kernel to send packets to 128.127.255.255 and 4.2 won't know that's the IP broadcast address and will ARP it. That's why 4.2 might ARP 128.127.255.255 on its own. 4.2BSD might ARP in response to correctly formatted broadcast packets because tries very hard to be an IP router, even if it has only one network interface. When it receives a packet that's not for it (and it won't recognize 128.127.255.255 as an IP broadcast that it should process itself) it tries to forward it. The IP routing code says "Yes, this is for my local net", so the kernel then tries to ARP 128.127.255.255... That should only happen if you have a mix of 4.2 machines and later systems which broadcast according to spec on the same ethernet. There's a variable in the kernel which controls IP forwarding and you can use adb to turn it off, but I don't remember the name of the variable. -- - john romkey ...harvard!spdcc!kaos!romkey romkey@kaos.uucp romkey@xx.lcs.mit.edu