From nobody Thu Sep 26 14:29:39 2024 X-Original-To: questions@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4XDwwQ55mJz5XMmf for ; Thu, 26 Sep 2024 14:29:42 +0000 (UTC) (envelope-from freebsd-doc@fjl.co.uk) Received: from bs2.fjl.org.uk (bs2.fjl.org.uk [84.45.41.208]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "bs2.fjl.org.uk", Issuer "bs2.fjl.org.uk" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4XDwwP37VNz4Ytl for ; Thu, 26 Sep 2024 14:29:41 +0000 (UTC) (envelope-from freebsd-doc@fjl.co.uk) Authentication-Results: mx1.freebsd.org; dkim=none; spf=pass (mx1.freebsd.org: domain of freebsd-doc@fjl.co.uk designates 84.45.41.208 as permitted sender) smtp.mailfrom=freebsd-doc@fjl.co.uk; dmarc=none Received: from roundcube.fjl.uk ([192.168.0.2]) by bs2.fjl.org.uk (8.16.1/8.16.1) with ESMTP id 48QETdU3097198 for ; Thu, 26 Sep 2024 14:29:39 GMT (envelope-from freebsd-doc@fjl.co.uk) List-Id: User questions List-Archive: https://lists.freebsd.org/archives/freebsd-questions List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: freebsd-questions@freebsd.org Sender: owner-freebsd-questions@FreeBSD.org MIME-Version: 1.0 Date: Thu, 26 Sep 2024 15:29:39 +0100 From: Frank Leonhardt To: questions Subject: Re: Why does dhcpd have a routers (plural) option for a subnet? In-Reply-To: References: Message-ID: <292574df4e30929138035c55f6d69185@fjl.co.uk> X-Sender: freebsd-doc@fjl.co.uk Content-Type: text/plain; charset=US-ASCII; format=flowed Content-Transfer-Encoding: 7bit X-Spamd-Result: default: False [-0.37 / 15.00]; SUBJECT_ENDS_QUESTION(1.00)[]; NEURAL_HAM_LONG(-0.96)[-0.965]; NEURAL_HAM_SHORT(-0.74)[-0.738]; NEURAL_SPAM_MEDIUM(0.54)[0.537]; R_SPF_ALLOW(-0.20)[+ip4:84.45.41.208:c]; ONCE_RECEIVED(0.10)[]; MIME_GOOD(-0.10)[text/plain]; ARC_NA(0.00)[]; ASN(0.00)[asn:25577, ipnet:84.45.0.0/17, country:GB]; MIME_TRACE(0.00)[0:+]; RCVD_COUNT_ONE(0.00)[1]; MISSING_XM_UA(0.00)[]; RCVD_TLS_LAST(0.00)[]; MID_RHS_MATCH_FROM(0.00)[]; R_DKIM_NA(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; FROM_EQ_ENVFROM(0.00)[]; RCPT_COUNT_ONE(0.00)[1]; PREVIOUSLY_DELIVERED(0.00)[questions@freebsd.org]; DMARC_NA(0.00)[fjl.co.uk]; TO_DN_ALL(0.00)[]; MLMMJ_DEST(0.00)[questions@freebsd.org]; FROM_HAS_DN(0.00)[] X-Rspamd-Queue-Id: 4XDwwP37VNz4Ytl X-Spamd-Bar: / On 2024-09-25 21:04, Steve Rikli wrote: > On Wed, Sep 25, 2024 at 08:39:39PM +0100, Frank Leonhardt wrote: >> Ever wondered why there's a "routers" option in dhcpd.conf? I have. >> Why >> isn't in just "router", as surely you can only have one default >> gateway? >> Except that's been muddied a bit by MSFT. >> >> Rather than adding a second just to see what happens I thought I'd >> ask? >> >> I expect it's a mistake in the early days of dhcpd that was too late >> to fix, >> or left for further expansion. > > Fwiw, dhcp-options(5) says: > > option routers ip-address [, ip-address ...]; > The routers option specifies a list of IP addresses for > routers > on the client's subnet. Routers should be listed in order of > preference. > > That said, I've never really tried multiple address there either. :-) That's interesting! I was looking in man dhcpd.conf and elsewhere, but not this man page (which appeared in FreeBSD 4.0 - I've just checked). This would require the host to rotate on failed gateways. I've always thought this was a sensible and simple idea but networking geeks said it was a really bad one and router standby protocols were the way to go. So the next interesting question would be which host stacks would accept multiple gateways and what would they do with them?