Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!mnetor!seismo!mimsy!oddjob!hao!boulder!forys From: forys@sigi.Colorado.EDU (Jeff Forys) Newsgroups: comp.unix.wizards Subject: Re: rwho problems between 4.2 and 4.3 hosts Message-ID: <1171@sigi.Colorado.EDU> Date: Wed, 27-May-87 19:41:08 EDT Article-I.D.: sigi.1171 Posted: Wed May 27 19:41:08 1987 Date-Received: Sat, 30-May-87 05:22:06 EDT References: <7523@brl-adm.ARPA> <12249@topaz.rutgers.edu> <1158@sigi.Colorado.EDU> <427@quacky.UUCP> Reply-To: forys@boulder.Colorado.EDU (Jeff Forys) Distribution: world Organization: University of Colorado, Boulder Lines: 40 Keywords: subnets, netmask, broadcast In article <427@quacky.UUCP> dce@quacky.UUCP (David Elliott) writes: > The netmask is a mask of 32 bits that says what part of an address > is the "network" (1s in the mask) and what part is the "host" (0s). For a more complete understanding of why `netmask' is necessary, it might be helpful to mention subnets. Netmask allows installations to partition a large network into smaller, manageable subnets. This is done this by `stealing' bits from the host part of an address to create a "subnet field". For example, given a 32-bit Class B address (below left), a specific site *may* choose to allocate 8 bits (up to 15 bits) from the *host* part as a `subnet field' (below right): 1 2 3 1 2 3 01234567 89012345 67890123 45678901 01234567 89012345 67890123 45678901 +--------+--------+--------+--------+ +--------+--------+--------+--------+ |10 network | host | |10 network | subnet | host | +-----------------+-----------------+ +--------+--------+--------+--------+ The netmask on the left would be 0xffff0000, and on the right, 0xffffff00. You are correct in saying that the 0's part of the mask is for the host. > the broadcast address must be an address of the form 97.x.y.z, but > it CAN be any address except for the ones already assigned to the > machines listed. RFC-943 defines an address of all 1's to mean "all hosts". As a result, to reach "all hosts" on your fictitious "97." net, you must use the addr "97.255.255.255" (assuming no IP multicasting). In the same way, an "all 1's" subnet field should send the packet to all subnets (however, 4.3BSD doesnt implement broadcasting across subnet boundaries). 4.2BSD predates the RFC and uses the wrong broadcast address (all 0's). > I believe that the default netmask in all BSD systems is 0xffff0000. Netmask was *not* implemented in stock 4.2BSD. It was hacked in, and then later became part of 4.3 as the need for subnets arose. You might wanna check out RFC-950 for information on subnets. --- Jeff Forys @ UC/Boulder Engineering Research Comp Cntr (303-492-6096) forys@Boulder.Colorado.EDU -or- ..!{hao|nbires}!boulder!forys