From owner-freebsd-questions@FreeBSD.ORG Sat Jul 25 11:20:14 2009 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id BC5CA1065673 for ; Sat, 25 Jul 2009 11:20:14 +0000 (UTC) (envelope-from axel@glemsk.net) Received: from mail.alternativdata.no (mail.alternativdata.no [195.18.251.125]) by mx1.freebsd.org (Postfix) with ESMTP id 763528FC14 for ; Sat, 25 Jul 2009 11:20:14 +0000 (UTC) (envelope-from axel@glemsk.net) Received: from 190.79-160-172.customer.lyse.net ([79.160.172.190] helo=[10.5.5.98]) by mail.alternativdata.no with esmtpsa (TLSv1:AES256-SHA:256) (Exim 4.69 (FreeBSD)) (envelope-from ) id 1MUfIM-0008Dt-9C; Sat, 25 Jul 2009 13:20:09 +0200 Message-ID: <4A6AEA5D.80708@glemsk.net> Date: Sat, 25 Jul 2009 13:19:57 +0200 From: Axel User-Agent: Thunderbird 2.0.0.22 (Windows/20090605) MIME-Version: 1.0 To: Matthew Seaman References: <4A6A3C49.4090403@glemsk.net> <4A6AC134.2050101@infracaninophile.co.uk> In-Reply-To: <4A6AC134.2050101@infracaninophile.co.uk> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Content-Filtered-By: Mailman/MimeDel 2.1.5 Cc: freebsd-questions@freebsd.org Subject: Re: Restarting daemons after portupgrade/portmanager X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 25 Jul 2009 11:20:15 -0000 Thanks for your reply! I want to make the upgrade process as easy as possible, so I guess that I'll set up automated restart of daemons (unless you think it's a bad idea). Is it okay to send a restart signal using AFTERINSTALL, or should the restart wait until after portmanager has updated all dependencies etc (= make a shell script)? Axel Matthew Seaman wrote: > Axel wrote: > >> Hello! I have a question concerning port upgrades. >> >> mysql51-server stops automatically during upgrade (using portupgrade or >> portmanager), and is properly started again based on a AFTERINSTALL >> setting in pktools.conf. >> >> So far, so good. But what about the other daemons that still seem to run >> after upgrade (Apache, Courier IMAP etc)? Are the new version running >> fine after the upgrade, or should I set AFTERINSTALL to do a restart of >> these daemons, to make sure they run the upgraded version? >> > > No -- the sample AFTERINSTALL stuff in pkgtools.conf will run any RC > scripts the package installs to try and start those services. This will > have no effect if: > > * The daemon is already running > > * There's no foo_enable="yes" setting in /etc/rc.conf or equivalent. > > So daemons like mysql or slapd that get shutdown during the process of > updating the port will be restarted, but daemons like apache or snmpd > that don't get shutdown will still be running the old version and you'll > have to restart them manually, as you will have to configure and start > anything newly installed. > > Cheers, > > Matthew > >