From owner-freebsd-bugs Thu Aug 30 19:29:32 2001 Delivered-To: freebsd-bugs@hub.freebsd.org Received: from freefall.freebsd.org (freefall.freebsd.org [216.136.204.21]) by hub.freebsd.org (Postfix) with ESMTP id A3FC937B406 for ; Thu, 30 Aug 2001 19:29:03 -0700 (PDT) (envelope-from gnats@FreeBSD.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.11.4/8.11.4) id f7V2K0T10103; Thu, 30 Aug 2001 19:20:00 -0700 (PDT) (envelope-from gnats) Received: from monsta.privatelabs.com (monsta.privatelabs.com [66.9.25.172]) by hub.freebsd.org (Postfix) with ESMTP id 0C85437B401; Thu, 30 Aug 2001 19:16:56 -0700 (PDT) (envelope-from mi@monsta.privatelabs.com) Received: (from mi@localhost) by monsta.privatelabs.com (8.11.3/8.11.3) id f7V26ct29666; Thu, 30 Aug 2001 22:06:38 -0400 (EDT) (envelope-from mi) Message-Id: <200108310206.f7V26ct29666@monsta.privatelabs.com> Date: Thu, 30 Aug 2001 22:06:38 -0400 (EDT) From: Mikhail Teterin Reply-To: mi@aldan.algebra.com To: FreeBSD-gnats-submit@freebsd.org Cc: jkh@freebsd.org X-Send-Pr-Version: 3.113 Subject: bin/30229: sysinstall ignores the network device name given on command line Sender: owner-freebsd-bugs@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.org >Number: 30229 >Category: bin >Synopsis: sysinstall ignores the network device name given on command line >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Thu Aug 30 19:20:00 PDT 2001 >Closed-Date: >Last-Modified: >Originator: Mikhail Teterin >Release: FreeBSD 4.3-BETA i386 >Organization: Private Labs, Inc. >Environment: System: FreeBSD monsta.privatelabs.com 4.3-BETA FreeBSD 4.3-BETA #0: Thu Mar 15 14:42:23 EST 2001 mi@minime.privatelabs.com:/raid/src/sys/compile/MONSTA i386 >Description: The sysinstall(8) allows to specify various parameters and invoke particular subparts of the program from command line. Unfortunately, when the tcpMenuSelect part is invoked, it will only honor the specified network interface (netDev), when non-interactivity is also requested. This prevents its use for interactively configuring a _specified_ interface -- the user first has to select it again from the menu. >How-To-Repeat: sysinstall netDev=dc0 tcpMenuSelect >Fix: The logic in the tcpDeviceSelect() can, probably, be redone -- it will look somewhat redundant after this patch. For that, it is very simple. It will cause the count of the eligible devices to be 1, if the correct device was already specified (through command or config file). If it was not, the variable_get() call will return NULL and the old behavior will take place: Index: tcpip.c =================================================================== RCS file: /net/raidbox/raid/ncvs/src/usr.sbin/sysinstall/tcpip.c,v retrieving revision 1.116 diff -U2 -r1.116 tcpip.c --- tcpip.c 2001/07/12 00:01:45 1.116 +++ tcpip.c 2001/08/31 01:10:38 @@ -601,5 +601,5 @@ int cnt; - devs = deviceFind(NULL, DEVICE_TYPE_NETWORK); + devs = deviceFind(variable_get(VAR_NETWORK_DEVICE), DEVICE_TYPE_NETWORK); cnt = deviceCount(devs); rval = NULL; >Release-Note: >Audit-Trail: >Unformatted: To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-bugs" in the body of the message