From owner-freebsd-questions Sat Feb 14 06:04:13 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id GAA22841 for freebsd-questions-outgoing; Sat, 14 Feb 1998 06:04:13 -0800 (PST) (envelope-from owner-freebsd-questions@FreeBSD.ORG) Received: from awfulhak.org (awfulhak.demon.co.uk [158.152.17.1]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id GAA22664 for ; Sat, 14 Feb 1998 06:03:59 -0800 (PST) (envelope-from brian@Awfulhak.org) Received: from gate.lan.awfulhak.org (localhost [127.0.0.1]) by awfulhak.org (8.8.7/8.8.7) with ESMTP id NAA03426; Sat, 14 Feb 1998 13:52:47 GMT (envelope-from brian@gate.lan.awfulhak.org) Message-Id: <199802141352.NAA03426@awfulhak.org> X-Mailer: exmh version 2.0.1 12/23/97 To: SysAdmin cc: Brian Somers , questions@FreeBSD.ORG Subject: Re: Dynamic gateway In-reply-to: Your message of "Thu, 12 Feb 1998 22:36:55 PST." Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Date: Sat, 14 Feb 1998 13:52:47 +0000 From: Brian Somers Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG > > > On Fri, 13 Feb 1998, Brian Somers wrote: > > > > > Just put a "/0" at the end of the second arg to `set ifaddr': > > > > set ifaddr 1.2.3.4/0 5.6.7.8/0 > > ^^ > > Let me try to rephrase your answer: the /0 part applied to any address, > even if it's not 5.6.7.8 (maybe possible gateway is 9.8.7.3 or something > like that). > > Please explain. >From the man page: set ifaddr 192.244.177.38/24 192.244.177.2/20 A number followed by a slash (/) represent the number of bits significant in the IP address. The above example signifies that: o I'd like to use 192.244.177.38 as my address if it is possible, but I'll also accept any IP address between 192.244.177.0 and 192.244.177.255. o I'd like to make him use 192.244.177.2 as his own address, but I'll also permit him to use any IP address between 192.244.176.0 and 192.244.191.255. o As you may have already noticed, 192.244.177.2 is equivalent to say- ing 192.244.177.2/32. o As an exception, 0 is equivalent to 0.0.0.0/0, meaning that I have no preferred IP address and will obey the remote peer's selection. When using zero, no routing table entries will be made until a connection is established. o 192.244.177.2/0 means that I'll accept/permit any IP address but I'll try to insist that 192.244.177.2 be used first. -- Brian , , Don't _EVER_ lose your sense of humour.... To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message