From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from outbound.soverin.net (outbound.soverin.net [116.202.65.218]) by mx.groups.io with SMTP id smtpd.web09.3491.1606770146994959131 for ; Mon, 30 Nov 2020 13:02:27 -0800 Authentication-Results: mx.groups.io; dkim=missing; spf=pass (domain: embed.me.uk, ip: 116.202.65.218, mailfrom: ml@embed.me.uk) Received: from smtp.soverin.net (unknown [10.10.3.24]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) (No client certificate requested) by outbound.soverin.net (Postfix) with ESMTPS id 32FBA6008F for ; Mon, 30 Nov 2020 21:02:24 +0000 (UTC) Received: from smtp.soverin.net (smtp.soverin.net [159.69.232.138]) by soverin.net Subject: Re: [OE-core] [PATCH 2/2] connman: set service to conflict with systemd-networkd To: openembedded-core@lists.openembedded.org References: <20201102092012.15968-1-yi.zhao@windriver.com> <20201102092012.15968-2-yi.zhao@windriver.com> From: "Jack Mitchell" Message-ID: Date: Mon, 30 Nov 2020 21:02:22 +0000 MIME-Version: 1.0 In-Reply-To: <20201102092012.15968-2-yi.zhao@windriver.com> Content-Type: text/plain; charset=utf-8 Content-Language: en-US-large Content-Transfer-Encoding: 7bit On 02/11/2020 09:20, Yi Zhao wrote: > Do not run systemd-networkd and connman simultaneously. These two > network managers may conflict with each other. > > Signed-off-by: Yi Zhao > --- > ...stop-systemd-networkd-when-using-con.patch | 29 +++++++++++++++++++ > .../connman/connman_1.38.bb | 1 + > 2 files changed, 30 insertions(+) > create mode 100644 meta/recipes-connectivity/connman/connman/0001-connman.service-stop-systemd-networkd-when-using-con.patch > > diff --git a/meta/recipes-connectivity/connman/connman/0001-connman.service-stop-systemd-networkd-when-using-con.patch b/meta/recipes-connectivity/connman/connman/0001-connman.service-stop-systemd-networkd-when-using-con.patch > new file mode 100644 > index 0000000000..dd012750a4 > --- /dev/null > +++ b/meta/recipes-connectivity/connman/connman/0001-connman.service-stop-systemd-networkd-when-using-con.patch > @@ -0,0 +1,29 @@ > +From 9fea099d0a3ece37d80ad70d32ebb8a93f8f3280 Mon Sep 17 00:00:00 2001 > +From: Yi Zhao > +Date: Fri, 30 Oct 2020 13:48:45 +0800 > +Subject: [PATCH] connman.service: stop systemd-networkd when using connman > + > +Stop systemd-networkd service when we use connman as network manager. > + > +Upstream-Status: Inappropriate [configuration] > + > +Signed-off-by: Yi Zhao > +--- > + src/connman.service.in | 1 + > + 1 file changed, 1 insertion(+) > + > +diff --git a/src/connman.service.in b/src/connman.service.in > +index 79e75d6..014eafe 100644 > +--- a/src/connman.service.in > ++++ b/src/connman.service.in > +@@ -6,6 +6,7 @@ RequiresMountsFor=@localstatedir@/lib/connman > + After=dbus.service network-pre.target systemd-sysusers.service > + Before=network.target multi-user.target shutdown.target > + Wants=network.target > ++Conflicts=systemd-networkd.service systemd-networkd.socket > + Conflicts=systemd-resolved.service > + > + [Service] > +-- > +2.17.1 > + > diff --git a/meta/recipes-connectivity/connman/connman_1.38.bb b/meta/recipes-connectivity/connman/connman_1.38.bb > index 027c41e9af..45c2934dec 100644 > --- a/meta/recipes-connectivity/connman/connman_1.38.bb > +++ b/meta/recipes-connectivity/connman/connman_1.38.bb > @@ -3,6 +3,7 @@ require connman.inc > SRC_URI = "${KERNELORG_MIRROR}/linux/network/${BPN}/${BP}.tar.xz \ > file://0001-plugin.h-Change-visibility-to-default-for-debug-symb.patch \ > file://0001-connman.service-stop-systemd-resolved-when-we-use-co.patch \ > + file://0001-connman.service-stop-systemd-networkd-when-using-con.patch \ > file://connman \ > file://no-version-scripts.patch \ > " > Hi Yi, This breaks our usecase where we have been using connman and systemd-networkd in tandem for a long time. IMO this should be reverted as if the two applications are conflicting then the correct fix is that they should be configured so that they don't both try to configure the same interfaces. As systemd-networkd doesn't ship with any rules by default it shouldn't be doing anything to interfere? With this patch I can no-longer run both services as it's a hard conflict with no option to either revert locally, or bbappend this patch out. Regards, Jack.