From mboxrd@z Thu Jan 1 00:00:00 1970 From: Ian Campbell Subject: Re: [PATCH v2 7/7] systemd: add support initial xen systemd service files Date: Mon, 24 Mar 2014 10:11:13 +0000 Message-ID: <1395655873.19365.17.camel@kazak.uk.xensource.com> References: <1395262733-11885-1-git-send-email-mcgrof@do-not-panic.com> <1395262733-11885-8-git-send-email-mcgrof@do-not-panic.com> <1395396494.27358.18.camel@kazak.uk.xensource.com> <20140322022621.GI5011@wotan.suse.de> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from mail6.bemta14.messagelabs.com ([193.109.254.103]) by lists.xen.org with esmtp (Exim 4.72) (envelope-from ) id 1WS1qi-0008LQ-IL for xen-devel@lists.xenproject.org; Mon, 24 Mar 2014 10:11:20 +0000 In-Reply-To: <20140322022621.GI5011@wotan.suse.de> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: "Luis R. Rodriguez" Cc: Stefano Stabellini , Jan =?UTF-8?Q?R=C4=99korajski?= , Ian Jackson , Jacek Konieczny , M A Young , xen-devel@lists.xenproject.org, "Luis R. Rodriguez" List-Id: xen-devel@lists.xenproject.org On Sat, 2014-03-22 at 03:26 +0100, Luis R. Rodriguez wrote: > On Fri, Mar 21, 2014 at 10:08:14AM +0000, Ian Campbell wrote: > > On Wed, 2014-03-19 at 13:58 -0700, Luis R. Rodriguez wrote: > > > [...] > > > diff --git a/tools/hotplug/Linux/systemd/oxenstored.service.in b/tools/hotplug/Linux/systemd/oxenstored.service.in > > > [...] > > > +ExecStartPost=-@BINDIR@/xenstore-write "/local/domain/0/name" "Domain-0" > > > diff --git a/tools/hotplug/Linux/systemd/xenstored.service.in b/tools/hotplug/Linux/systemd/xenstored.service.in > > [...] > > > +ExecStartPost=@BINDIR@/xenstore-write "/local/domain/0/name" "Domain-0" > > > > I accidentally deleted the subthread about writing domid here too, but I > > was wondering if it might be better to have a common xenstore service > > which depends on oxenstore.service || cxenstore.service and then does > > this kind of common implementation agnostic setup in one place where it > > can't get out of sync easily? > > That's what I was hoping for to achieve with the socket file but that > seems to not work as expected, even if you claim the socket explicitly > as part of both oxenstored and xenstored. To me this could likely be > an enhancement to systemd but not sure. > > systemd does not allow one to use || as part of the language for requirements, Does it not have some sort of "Provides: some-virtual-facility" which two things can provide and other things can depend on? > This means we either do some sort of meta @VARIABLE@ substitution or a common > init routine which will do the or checking for us. The only problem with this > is systemd will treat the Forking type service ExecStart as the process to care > for, and if we add a wrapper that'd be dead. I haven't tried to implement one > but I think this could confuse systemd or administrators. Yes, lets not go that route. Ian.