From mboxrd@z Thu Jan 1 00:00:00 1970 From: Christoph Egger Subject: Re: [PATCH 9/9] init/NetBSD: move xenbackendd to xend init script Date: Wed, 18 Jul 2012 11:02:47 +0200 Message-ID: <50067BB7.4030605@amd.com> References: <1342002232-75531-1-git-send-email-roger.pau@citrix.com> <1342002232-75531-10-git-send-email-roger.pau@citrix.com> <20485.36379.841767.872741@mariner.uk.xensource.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <20485.36379.841767.872741@mariner.uk.xensource.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: Ian Jackson Cc: "xen-devel@lists.xen.org" , Roger Pau Monne List-Id: xen-devel@lists.xenproject.org On 07/17/12 18:08, Ian Jackson wrote: > > Roger Pau Monne writes ("[PATCH 9/9] init/NetBSD: move xenbackendd to xend init script"): >> xenbackendd is not needed by the xl toolstack, so move it's launch to >> the xend script. > > Acked-by: Ian Jackson > > on the basis that it doesn't touch non-BSD code. But: > >> + printf "Stopping xenbackendd, xend\n" >> + xb_pid=$(check_pidfile ${XENBACKENDD_PIDFILE} ${SBINDIR}/xenbackendd) >> + xend_pid=`ps x -o pid,command|grep ${SBINDIR}/xend|awk '{ print $1 }'` >> + if test -n "$xb_pid"; >> + then >> + kill -${sig_stop:-TERM} $xb_pid > > This is pretty horrid. Does BSD not have better ways to manage > daemons ? Does a xend_pid=`pgrep xend` work ? Christoph -- ---to satisfy European Law for business letters: Advanced Micro Devices GmbH Einsteinring 24, 85689 Dornach b. Muenchen Geschaeftsfuehrer: Alberto Bozzo, Andrew Bowd Sitz: Dornach, Gemeinde Aschheim, Landkreis Muenchen Registergericht Muenchen, HRB Nr. 43632