From owner-freebsd-ports@FreeBSD.ORG Sun Dec 11 07:43:41 2011 Return-Path: Delivered-To: freebsd-ports@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 73B951065670 for ; Sun, 11 Dec 2011 07:43:41 +0000 (UTC) (envelope-from jhellenthal@gmail.com) Received: from mail-iy0-f182.google.com (mail-iy0-f182.google.com [209.85.210.182]) by mx1.freebsd.org (Postfix) with ESMTP id 2F6FF8FC08 for ; Sun, 11 Dec 2011 07:43:40 +0000 (UTC) Received: by iakl21 with SMTP id l21so1475914iak.13 for ; Sat, 10 Dec 2011 23:43:40 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=sender:date:from:to:cc:subject:message-id:references:mime-version :content-type:content-disposition:in-reply-to; bh=289YxJ0EJLdADUBO7S+f5ctvAyW6/cQ3Zr+ngnQxQl8=; b=NDvkKiucprxBEcRKFPrhQgNyoN84qEiZzNDPi+VlrW0D3f4+kbVoMK3foKE1ty5zvg ItvAuAw9TV672of0Ld1MEp2MelNiAa93MbSmvShewmMejPxHHU5EoygFE5aaUFMD89kg SBhq1c1dZFstLVBpAbXelNonEVl5ILtY1V18c= Received: by 10.50.183.133 with SMTP id em5mr9899525igc.73.1323587998906; Sat, 10 Dec 2011 23:19:58 -0800 (PST) Received: from DataIX.net (24-247-9-230.dhcp.aldl.mi.charter.com. [24.247.9.230]) by mx.google.com with ESMTPS id g34sm33747706ibk.10.2011.12.10.23.19.55 (version=TLSv1/SSLv3 cipher=OTHER); Sat, 10 Dec 2011 23:19:56 -0800 (PST) Sender: Jason Hellenthal Received: from DataIX.net (localhost [127.0.0.1]) by DataIX.net (8.14.5/8.14.5) with ESMTP id pBB7Jrjj060652 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Sun, 11 Dec 2011 02:19:53 -0500 (EST) (envelope-from jhell@DataIX.net) Received: (from jhell@localhost) by DataIX.net (8.14.5/8.14.5/Submit) id pBB7JmW6060651; Sun, 11 Dec 2011 02:19:48 -0500 (EST) (envelope-from jhell@DataIX.net) Date: Sun, 11 Dec 2011 02:19:47 -0500 From: Jason Hellenthal To: Doug Barton Message-ID: <20111211071947.GA57995@DataIX.net> References: <4ED8C0F1.807@FreeBSD.org> <20111202195555.GD1913@azathoth.lan> <4ED95A95.9040805@FreeBSD.org> <20111209211848.GF59666@azathoth.lan> <4EE27CC5.4010006@FreeBSD.org> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="W/nzBZO5zC0uMSeA" Content-Disposition: inline In-Reply-To: <4EE27CC5.4010006@FreeBSD.org> Cc: Baptiste Daroussin , Andriy Gapon , FreeBSD Ports ML Subject: Re: again, ports that stop daemons X-BeenThere: freebsd-ports@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Porting software to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 11 Dec 2011 07:43:41 -0000 --W/nzBZO5zC0uMSeA Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Fri, Dec 09, 2011 at 01:25:25PM -0800, Doug Barton wrote: > On 12/09/2011 13:18, Baptiste Daroussin wrote: > > On Sat, Dec 03, 2011 at 01:09:09AM +0200, Andriy Gapon wrote: > >> on 02/12/2011 21:55 Baptiste Daroussin said the following: > >>> On Fri, Dec 02, 2011 at 08:38:05PM +0100, Torfinn Ingolfsen wrote: > >>>> On Fri, Dec 2, 2011 at 1:13 PM, Andriy Gapon wrote: > >>>>> > >>>>> Or that they simply quit doing that and instead print a message lik= e "Port X is > >>>>> deinstalled but it may have some processes running, please do Y and= /or Z to find > >>>>> them and/or stop them". > >>>> > >>>> I prefer this suggestion. > >>> > >>> I also would prefer this. > >> > >> > >> BTW, this part of my suggestion was inspired by the following: > >> http://en.opensuse.org/SDB:Zypper_usage_11.3#Check_processes > >> > >> Not sure how that feature is implemented though. > >> > > FYI, since a few minutes, pkgng handle rc scripts, disabled by default = because I > > still consider this feature dangerous. > > to activate it is: > > HANDLE_RC_SCRIPTS=3Dyes in pkg.conf >=20 > I previously described what I thought was a pretty good way to handle > this question that addressed the needs expressed by all of the posters > on the previous thread, but my suggestion didn't get any responses. > Since this has come up again, it would be helpful (to me at least) if > people would think about my idea, and if nothing else tell me why I'm > wrong. :) >=20 > Quoting: >=20 > Speaking only for myself I hate the idea of stopping/starting services > automatically. However this feature is often requested, and is something > that is provided by many other package systems. If we have people who > are willing to do the work I think it's worth discussing how to do it > properly. >=20 > The way that I envision it working > would be a 3-knob system. One knob to always restart the services, one > to never do it; and then asking on a per-port basis, which should be the > default. I can imagine portmaster detecting this option in the pre-build > phase similarly to how it detects and warns about IS_INTERACTIVE now, > and giving the user a menu of options for how to handle it. I'm happy to > add more details if people are interested. >=20 > Where this actually becomes interesting is not in the ports > build/install process, which is pretty easy to deal with, but with > package installs/deinstalls. I definitely think it's doable, what we > probably want to do is put a knob for this in the port's Makefile, and > handle the stop/start for both the port and the package with a little > script that can be included in the package, and run with @exec and @unexe= c. >=20 >=20 Personally I think this is a little overboard... not your idea but the fact= of trying to determine a function of restarting services for the user. If = end-user is upgrading a package they should be prepared to take any neccesa= ry action to start the services again after final actions are complete. Des= perate services could have a periodic script that could handle the checks f= or these services and I strongly advise against taking any action whatsoeve= r on starting or restarting or reloading. Stop the service if need be but n= ever "assume" anything about starting a service without strict user interac= tion. If at all likelyness that this happens then I have one request... One simpl= e knob that defaults to ``NO'' for restarting or starting or reloading. I t= hink this is at least reasonable. --W/nzBZO5zC0uMSeA Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- iQEcBAEBAgAGBQJO5FmTAAoJEJBXh4mJ2FR+JngH/2CEXjCCogd3XMkAk0VBcI5E ORjwPG99VAod+tYf29H2l0QAPh51hE70qbKVxZy7z2CQV/zXxwKh1wOjhovcrxY5 iAEj255hQGtpFFXvRTivpIAC19kQgrALGPGwdmCIB1nZUdiN4/NbQrubVbftKFlY 4vbzKV5Ew0ODLJnqn99/1VO1Q8Omedg+GoC4s5nZShhL7cRGvap5royDB5FhJt0T l7WPOt6MzqxDLh9++WsNfwfWCAu7x7eVDP+bORveXxv4+OPwvg+oAMKtGEqRhT7n QVmJk0B923U0sAHoUwHzvuiLBNlIwAgJfkbfTLrPaII66zSToDUgYq+k/TJerdY= =wqwR -----END PGP SIGNATURE----- --W/nzBZO5zC0uMSeA--