From owner-freebsd-bugs@freebsd.org Wed Nov 13 18:51:30 2019 Return-Path: Delivered-To: freebsd-bugs@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 48CA31B880A for ; Wed, 13 Nov 2019 18:51:30 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from mailman.nyi.freebsd.org (mailman.nyi.freebsd.org [IPv6:2610:1c1:1:606c::50:13]) by mx1.freebsd.org (Postfix) with ESMTP id 47CtxZ0rW2z4Qdl for ; Wed, 13 Nov 2019 18:51:30 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: by mailman.nyi.freebsd.org (Postfix) id 1CB421B8808; Wed, 13 Nov 2019 18:51:30 +0000 (UTC) Delivered-To: bugs@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 1C6AB1B8807 for ; Wed, 13 Nov 2019 18:51:30 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) server-signature RSA-PSS (4096 bits) client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 47CtxY66swz4Qdf for ; Wed, 13 Nov 2019 18:51:29 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org (kenobi.freebsd.org [IPv6:2610:1c1:1:606c::50:1d]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id B6DA71C55F for ; Wed, 13 Nov 2019 18:51:29 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org ([127.0.1.5]) by kenobi.freebsd.org (8.15.2/8.15.2) with ESMTP id xADIpT0V045458 for ; Wed, 13 Nov 2019 18:51:29 GMT (envelope-from bugzilla-noreply@freebsd.org) Received: (from www@localhost) by kenobi.freebsd.org (8.15.2/8.15.2/Submit) id xADIpTIk045457 for bugs@FreeBSD.org; Wed, 13 Nov 2019 18:51:29 GMT (envelope-from bugzilla-noreply@freebsd.org) X-Authentication-Warning: kenobi.freebsd.org: www set sender to bugzilla-noreply@freebsd.org using -f From: bugzilla-noreply@freebsd.org To: bugs@FreeBSD.org Subject: [Bug 241954] netgraph fails on concurrent node rename Date: Wed, 13 Nov 2019 18:51:29 +0000 X-Bugzilla-Reason: AssignedTo X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: Base System X-Bugzilla-Component: kern X-Bugzilla-Version: 12.1-RELEASE X-Bugzilla-Keywords: X-Bugzilla-Severity: Affects Many People X-Bugzilla-Who: freebsd@otoh.org X-Bugzilla-Status: New X-Bugzilla-Resolution: X-Bugzilla-Priority: --- X-Bugzilla-Assigned-To: bugs@FreeBSD.org X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: bug_id short_desc product version rep_platform op_sys bug_status bug_severity priority component assigned_to reporter Message-ID: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: https://bugs.freebsd.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-BeenThere: freebsd-bugs@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 13 Nov 2019 18:51:30 -0000 https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D241954 Bug ID: 241954 Summary: netgraph fails on concurrent node rename Product: Base System Version: 12.1-RELEASE Hardware: Any OS: Any Status: New Severity: Affects Many People Priority: --- Component: kern Assignee: bugs@FreeBSD.org Reporter: freebsd@otoh.org I have a FreeBSD 12.1 host on which I'm using jng to create netgraph nodes = for host interfaces. If I start the jails in series, it works fine. If I start = them in parallel netgraph fails to rename the nodes and those jails fail to initialize. jail.conf: exec.prestart =3D ""; exec.start =3D "/bin/sh /etc/rc"; exec.stop =3D "/bin/sh /etc/rc.shutdown"; exec.poststop =3D ""; exec.clean; mount.devfs; mount.fdescfs; mount.procfs; persist; vnet =3D new; devfs_ruleset =3D 10; # random, log, null, fd/* and other critical items # Dynamic wildcard parameter: # Base the path off the jail name. path =3D "/jail/${host.hostname}/root"; exec.consolelog =3D "/var/log/jail_${host.hostname}_console.log"; ###########################################################################= ##### # External Jails ###########################################################################= ##### ext { host.hostname =3D "ext.example.com"; exec.prestart +=3D "jng bridge ext bridge0 bridge1"; exec.poststop +=3D "jng shutdown ext"; vnet.interface =3D ng0_ext,ng1_ext; } ###########################################################################= ##### # Internal Jails ###########################################################################= ##### ns0 { host.hostname =3D "ns0.example.com"; exec.prestart +=3D "jng bridge ns0 bridge0 bridge1"; exec.poststop +=3D "jng shutdown ns0"; vnet.interface =3D ng0_ns0,ng1_ns0; } ns1 { host.hostname =3D "ns1.example.com"; exec.prestart +=3D "jng bridge ns1 bridge0 bridge1"; exec.poststop +=3D "jng shutdown ns1"; vnet.interface =3D ng0_ns1,ng1_ns1; } wg { host.hostname =3D "wg.example.com"; exec.prestart +=3D "jng bridge wg bridge0 bridge1"; exec.poststop +=3D "jng shutdown wg"; vnet.interface =3D ng0_wg,ng1_wg; devfs_ruleset =3D 11; # include tun } www { host.hostname =3D "www.example.com"; exec.prestart +=3D "jng bridge www bridge0 bridge1"; exec.poststop +=3D "jng shutdown www"; vnet.interface =3D ng0_www,ng1_www; sysvshm; # postgresql } vault { host.hostname =3D "vault.example.com"; exec.prestart +=3D "jng bridge vault bridge0 bridge1"; exec.poststop +=3D "jng shutdown vault"; vnet.interface =3D ng0_vault,ng1_vault; } dmesg: WARNING: attempt to domain_add(netgraph) after domainfinalize() bridge0: promiscuous mode enabled ngeth0: link state changed to UP ngeth0: changing name to 'ng0_www' bridge1: promiscuous mode enabled ngeth1: link state changed to UP ngeth1: changing name to 'ng1_www' ng_ether_ifnet_arrival_event: can't re-name node ng0_www ng_ether_ifnet_arrival_event: can't re-name node ng1_www lo0: link state changed to UP Jail start (clean after boot with jails disabled): [root@ext]# service jail start Starting jails:ngctl: send msg: File exists ngctl: send msg: File exists ngctl: send msg: File exists ngctl: jail: send msgns0: jng bridge ns0 bridge0 bridge1: failed: jail: ngctl: wg: jng bridge wg bridge0 bridge1: failedFile exists send msgjail: : ns1: jng bridge ns1 bridge0 bridge1: failed File exists jail: vault: jng bridge vault bridge0 bridge1: failed jail: numbat: jng bridge numbat bridge0 bridge1: failed ng0_www ng1_www www: created --=20 You are receiving this mail because: You are the assignee for the bug.=