From owner-freebsd-i386@FreeBSD.ORG Fri Jul 8 12:40:04 2011 Return-Path: Delivered-To: freebsd-i386@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 37962106564A for ; Fri, 8 Jul 2011 12:40:04 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:4f8:fff6::28]) by mx1.freebsd.org (Postfix) with ESMTP id 130BA8FC19 for ; Fri, 8 Jul 2011 12:40:04 +0000 (UTC) Received: from freefall.freebsd.org (localhost [127.0.0.1]) by freefall.freebsd.org (8.14.4/8.14.4) with ESMTP id p68Ce3a0092467 for ; Fri, 8 Jul 2011 12:40:03 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.4/8.14.4/Submit) id p68Ce35D092466; Fri, 8 Jul 2011 12:40:03 GMT (envelope-from gnats) Resent-Date: Fri, 8 Jul 2011 12:40:03 GMT Resent-Message-Id: <201107081240.p68Ce35D092466@freefall.freebsd.org> Resent-From: FreeBSD-gnats-submit@FreeBSD.org (GNATS Filer) Resent-To: freebsd-i386@FreeBSD.org Resent-Reply-To: FreeBSD-gnats-submit@FreeBSD.org, Antonio Huete Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 017A41065672 for ; Fri, 8 Jul 2011 12:37:46 +0000 (UTC) (envelope-from nobody@FreeBSD.org) Received: from red.freebsd.org (red.freebsd.org [IPv6:2001:4f8:fff6::22]) by mx1.freebsd.org (Postfix) with ESMTP id CCBEF8FC0C for ; Fri, 8 Jul 2011 12:37:45 +0000 (UTC) Received: from red.freebsd.org (localhost [127.0.0.1]) by red.freebsd.org (8.14.4/8.14.4) with ESMTP id p68CbjK9075084 for ; Fri, 8 Jul 2011 12:37:45 GMT (envelope-from nobody@red.freebsd.org) Received: (from nobody@localhost) by red.freebsd.org (8.14.4/8.14.4/Submit) id p68Cbj6g075083; Fri, 8 Jul 2011 12:37:45 GMT (envelope-from nobody) Message-Id: <201107081237.p68Cbj6g075083@red.freebsd.org> Date: Fri, 8 Jul 2011 12:37:45 GMT From: Antonio Huete To: freebsd-gnats-submit@FreeBSD.org X-Send-Pr-Version: www-3.1 Cc: Subject: i386/158734: netif stop don't destroy cloned_interfaces X-BeenThere: freebsd-i386@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: I386-specific issues for FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 08 Jul 2011 12:40:04 -0000 >Number: 158734 >Category: i386 >Synopsis: netif stop don't destroy cloned_interfaces >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-i386 >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Fri Jul 08 12:40:03 UTC 2011 >Closed-Date: >Last-Modified: >Originator: Antonio Huete >Release: 8.2-RELEASE >Organization: >Environment: FreeBSD fbsd.localdomain 8.2-RELEASE FreeBSD 8.2-RELEASE #0: Fri Feb 18 02:24:46 UTC 2011 root@almeida.cse.buffalo.edu:/usr/obj/usr/src/sys/GENERIC i386 >Description: Hi, I'm not sure if this is a bug or it is intentional, but when you try to restart netif service, it spits an error because cloned_interfaces are not destroyed upon netif stop. fbsd# grep cloned /etc/rc.conf cloned_interfaces="bridge0" fbsd# /etc/rc.d/netif restart Stopping Network: lo0 em0 plip0 bridge0. lo0: flags=8048 metric 0 mtu 16384 options=3 inet6 fe80::1%lo0 prefixlen 64 scopeid 0x3 inet6 ::1 prefixlen 128 nd6 options=3 em0: flags=8802 metric 0 mtu 1500 options=9b ether 00:0c:29:69:54:73 media: Ethernet autoselect (1000baseT ) status: active plip0: flags=8810 metric 0 mtu 1500 bridge0: flags=8802 metric 0 mtu 1500 ether 3a:51:06:6b:4d:87 id 00:00:00:00:00:00 priority 32768 hellotime 2 fwddelay 15 maxage 20 holdcnt 6 proto rstp maxaddr 100 timeout 1200 root id 00:00:00:00:00:00 priority 0 ifcost 0 port 0 ifconfig: create: bad value Starting Network: lo0 em0. lo0: flags=8049 metric 0 mtu 16384 options=3 inet6 fe80::1%lo0 prefixlen 64 scopeid 0x3 inet6 ::1 prefixlen 128 inet 127.0.0.1 netmask 0xff000000 nd6 options=3 em0: flags=8843 metric 0 mtu 1500 options=9b ether 00:0c:29:69:54:73 media: Ethernet autoselect (1000baseT ) status: active It spits "ifconfig: create: bad value" because in /etc/network.subr in clone_up function line 502, it tries to create the clone without checking if it exist first. I wonder also if it would be fine just to send stderr to /dev/null or if it would be worthy to create a function to check the existence of the clone and skip its creation in that case. Cheers, Antonio Huete >How-To-Repeat: >Fix: >Release-Note: >Audit-Trail: >Unformatted: