From owner-freebsd-bugs Thu Aug 5 5:50:21 1999 Delivered-To: freebsd-bugs@freebsd.org Received: from freefall.freebsd.org (freefall.FreeBSD.ORG [204.216.27.21]) by hub.freebsd.org (Postfix) with ESMTP id 24DBB154D1 for ; Thu, 5 Aug 1999 05:50:18 -0700 (PDT) (envelope-from gnats@FreeBSD.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.9.3/8.9.2) id FAA21782; Thu, 5 Aug 1999 05:50:01 -0700 (PDT) (envelope-from gnats@FreeBSD.org) Received: from soleil.uvsq.fr (soleil.uvsq.fr [193.51.24.1]) by hub.freebsd.org (Postfix) with ESMTP id C3052151DA for ; Thu, 5 Aug 1999 05:43:39 -0700 (PDT) (envelope-from card@ens.uvsq.fr) Received: from atlas.ens.uvsq.fr (atlas.ens.uvsq.fr [193.51.26.1]) by soleil.uvsq.fr (8.9.3/jtpda-5.3.2) with ESMTP id OAA50794 for ; Thu, 5 Aug 1999 14:43:29 +0200 (CEST) Received: from alsace.ens.uvsq.fr (alsace.ens.uvsq.fr [193.51.26.20]) by atlas.ens.uvsq.fr (8.9.3/jtpda-5.2) with ESMTP id OAA40059 for ; Thu, 5 Aug 1999 14:43:29 +0200 (CEST) Received: from (card@localhost) by alsace.ens.uvsq.fr (8.9.3/jtpda-5.2) id OAA00777 ; Thu, 5 Aug 1999 14:43:29 +0200 (CEST) Message-Id: <199908051243.OAA00777@alsace.ens.uvsq.fr> Date: Thu, 5 Aug 1999 14:43:29 +0200 (CEST) From: card@ens.uvsq.fr (Remy Card) Reply-To: card@csi.uvsq.fr To: FreeBSD-gnats-submit@freebsd.org X-Send-Pr-Version: 3.2 Subject: conf/12984: No dhclient support in /etc/rc* Sender: owner-freebsd-bugs@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org >Number: 12984 >Category: conf >Synopsis: /etc/rc* does not contain any support for dhclient >Confidential: no >Severity: serious >Priority: medium >Responsible: freebsd-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Thu Aug 5 05:50:01 PDT 1999 >Closed-Date: >Last-Modified: >Originator: Remy Card >Release: FreeBSD 3.2-RELEASE i386 >Organization: CSI - UVSQ >Environment: 3.2-RELEASE and 3.2-STABLE >Description: 3.2-RELEASE contains dhclient but the startup scripts (/etc/rc*) do not include any support for it. Thus, it is not possible to use DHCP to set the IP address without modifying these scripts. >How-To-Repeat: >Fix: Apply the following patch that adds dhclient support in /etc/rc.network and /etc/defaults/rc.conf. This patch includes the changes made in the current version of /etc/rc*. --- usr/src/etc/defaults/rc.conf Tue May 11 14:21:22 1999 +++ etc/defaults/rc.conf Thu Aug 5 14:20:28 1999 @@ -31,6 +31,8 @@ ### Basic network options: ### hostname="myname.my.domain" # Set this! nisdomainname="NO" # Set to NIS domain if using NIS (or NO). +dhcp_program="/sbin/dhclient" # Path to dhcp client program. +dhcp_flags="" # Additional flags to pass to dhcp client. firewall_enable="NO" # Set to YES to enable firewall functionality firewall_script="/etc/rc.firewall" # Which script to run to set up the firewall firewall_type="UNKNOWN" # Firewall type (see /etc/rc.firewall) --- usr/src/etc/rc.network Mon Apr 12 17:29:11 1999 +++ etc/rc.network Wed Aug 4 18:53:35 1999 @@ -58,7 +58,12 @@ # Do the primary ifconfig if specified eval ifconfig_args=\$ifconfig_${ifn} if [ -n "${ifconfig_args}" ] ; then - ifconfig ${ifn} ${ifconfig_args} + # See if we are using DHCP + if [ X"${ifconfig_args}" = X"DHCP" ]; then + ${dhcp_program} ${dhcp_flags} ${ifn} + else + ifconfig ${ifn} ${ifconfig_args} + fi fi # Check to see if aliases need to be added alias=0 >Release-Note: >Audit-Trail: >Unformatted: To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-bugs" in the body of the message