From owner-freebsd-rc@FreeBSD.ORG Mon Jul 19 22:10:45 2004 Return-Path: Delivered-To: freebsd-rc@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id BA4D016A4CE; Mon, 19 Jul 2004 22:10:45 +0000 (GMT) Received: from postfix4-2.free.fr (postfix4-2.free.fr [213.228.0.176]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4F35843D55; Mon, 19 Jul 2004 22:10:45 +0000 (GMT) (envelope-from clefevre-lists@9online.fr) Received: from pc2k (nas-cbv-7-213-228-32-43.dial.proxad.net [213.228.32.43]) by postfix4-2.free.fr (Postfix) with SMTP id 162C91AD3C5; Tue, 20 Jul 2004 00:10:03 +0200 (CEST) Message-ID: <040d01c46ddd$25798f20$7890a8c0@dyndns.org> From: "Cyrille Lefevre" To: "Mike Makonnen" , "Oliver Eikemeier" References: <38080924-D73B-11D8-8DBE-00039312D914@fillmore-labs.com> Date: Tue, 20 Jul 2004 00:10:01 +0200 Organization: ACME MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 6.00.2800.1409 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1409 cc: ports@FreeBSD.org cc: freebsd-rc@freebsd.org Subject: Re: localpkg script changes X-BeenThere: freebsd-rc@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Discussion related to /etc/rc.d design and implementation. List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 19 Jul 2004 22:10:45 -0000 "Oliver Eikemeier" wrote: > Mike Makonnen wrote: [snip] > > It's not as simple as that. Besides the security implications there are > > also > > many possible corner cases. To name just a couple: diskless, / (root > > partition), > > /usr/local, /usr/X11R6 on different partitions or even mounted > > remotely, etc... > > I can't see any security implications here, and when you manage to get > things working diskless, I can't see any problems when /usr/local and > /usr/X11R6 are on different partitions... Could you just name some > *real* problems instead of just stating that it is `difficult', so that > we can start to work on them? I suppose that if you want to mix /etc/rc.d and /usr/local/etc/rc.d startup files, you can't since /usr/local/etc/rc.d may not be accessible at the time where rcorder is executed since /usr/local will be mounted after. Cyrille Lefevre. -- home: mailto:cyrille.lefevre@laposte.net From owner-freebsd-rc@FreeBSD.ORG Wed Jul 21 04:41:18 2004 Return-Path: Delivered-To: freebsd-rc@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 5A00D16A4CE for ; Wed, 21 Jul 2004 04:41:18 +0000 (GMT) Received: from smtp1.utdallas.edu (smtp1.utdallas.edu [129.110.10.12]) by mx1.FreeBSD.org (Postfix) with ESMTP id 3918643D1F for ; Wed, 21 Jul 2004 04:41:18 +0000 (GMT) (envelope-from pauls@utdallas.edu) Received: from [192.168.2.102] (adsl-68-90-206-81.dsl.rcsntx.swbell.net [68.90.206.81]) by smtp1.utdallas.edu (Postfix) with ESMTP id 94116388D1A for ; Tue, 20 Jul 2004 23:41:17 -0500 (CDT) Date: Tue, 20 Jul 2004 23:41:16 -0500 From: Paul Schmehl To: freebsd-rc@freebsd.org Message-ID: <2147483647.1090366876@[192.168.2.102]> X-Mailer: Mulberry/3.0.3 (Mac OS X) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Content-Disposition: inline Subject: rc script won't start daemon on reboot X-BeenThere: freebsd-rc@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list Reply-To: Paul Schmehl List-Id: Discussion related to /etc/rc.d design and implementation. List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 21 Jul 2004 04:41:18 -0000 I've tried the general list without success. I'm hoping this list can help me. I've written a very simple rc script using the new format and rc.subr. The script works fine from the commandline (start|stop|restart|rcvar|status|poll), but when the server is rebooted, the script fails to start the daemon. There are no errors in /var/log/messages or in the extractor.log file, and the daemon is too simplistically written to have a debug or verbose switch. Any ideas what the problem could be? Here's the necessary details: bash-2.05b# uname -v FreeBSD 4.8-RELEASE #0: Thu Apr 3 10:53:38 GMT 2003 root@freebsd-stable.sentex.ca:/usr/obj/usr/src/sys/GENERIC bash-2.05b# cat /usr/local/etc/rc.d/extractor.sh #!/bin/sh # $Id$ # PROVIDE: extractor # BEFORE: LOGIN # KEYWORD: FreeBSD . /usr/local/etc/rc.subr name=extractor rcvar=`set_rcvar` command="/usr/local/bin/${name}" load_rc_config $name run_rc_command "$1" bash-2.05b# ls -lsa /usr/local/etc/rc.d/extractor.sh 2 -rwxr-x--- 1 root wheel 1154 Jul 17 01:07 /usr/local/etc/rc.d/extractor.sh bash-2.05b# /usr/local/etc/rc.d/extractor.sh rcvar # extractor $extractor_enable=YES Paul Schmehl (pauls@utdallas.edu) Adjunct Information Security Officer The University of Texas at Dallas AVIEN Founding Member http://www.utdallas.edu From owner-freebsd-rc@FreeBSD.ORG Wed Jul 21 07:43:47 2004 Return-Path: Delivered-To: freebsd-rc@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id C626916A4CE for ; Wed, 21 Jul 2004 07:43:47 +0000 (GMT) Received: from telecom.net.et (sparrow.telecom.net.et [213.55.64.38]) by mx1.FreeBSD.org (Postfix) with ESMTP id 972AD43D1F for ; Wed, 21 Jul 2004 07:43:45 +0000 (GMT) (envelope-from mtm@identd.net) Received: from [213.55.66.129] (HELO pool-151-200-10-97.res.east.verizon.net) by telecom.net.et (CommuniGate Pro SMTP 3.4.8) with ESMTP-TLS id 52180892; Wed, 21 Jul 2004 10:37:05 +0300 Received: from rogue.acs-et.com (localhost [127.0.0.1]) ESMTP id i6L7ijVx001571; Wed, 21 Jul 2004 10:44:47 +0300 (EAT) (envelope-from mtm@rogue.acs-et.com) Received: (from mtm@localhost) by rogue.acs-et.com (8.12.11/8.12.11/Submit) id i6L7igib001570; Wed, 21 Jul 2004 10:44:42 +0300 (EAT) (envelope-from mtm) Date: Wed, 21 Jul 2004 10:44:39 +0300 From: Mike Makonnen To: Paul Schmehl Message-ID: <20040721074439.GA1288@rogue.acs-et.com> References: <2147483647.1090366876@[192.168.2.102]> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <2147483647.1090366876@[192.168.2.102]> User-Agent: Mutt/1.4.2.1i X-Operating-System: FreeBSD/5.2-CURRENT (i386) cc: freebsd-rc@FreeBSD.org Subject: Re: rc script won't start daemon on reboot X-BeenThere: freebsd-rc@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Discussion related to /etc/rc.d design and implementation. List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 21 Jul 2004 07:43:47 -0000 On Tue, Jul 20, 2004 at 11:41:16PM -0500, Paul Schmehl wrote: > > bash-2.05b# uname -v > FreeBSD 4.8-RELEASE #0: Thu Apr 3 10:53:38 GMT 2003 > root@freebsd-stable.sentex.ca:/usr/obj/usr/src/sys/GENERIC FreeBSD 4.x does not use the rc.d mechanism during boot. It has a static rc(8). You should call the script from /etc/rc.local. Cheers. -- Mike Makonnen | GPG-KEY: http://www.identd.net/~mtm/mtm.asc mtm@identd.net | Fingerprint: AC7B 5672 2D11 F4D0 EBF8 5279 5359 2B82 7CD4 1F55 mtm@FreeBSD.Org| FreeBSD - Unleash the Daemon ! From owner-freebsd-rc@FreeBSD.ORG Wed Jul 21 07:58:27 2004 Return-Path: Delivered-To: freebsd-rc@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 447C916A4CF for ; Wed, 21 Jul 2004 07:58:27 +0000 (GMT) Received: from fillmore.dyndns.org (port-212-202-50-15.dynamic.qsc.de [212.202.50.15]) by mx1.FreeBSD.org (Postfix) with ESMTP id D6B3C43D5E for ; Wed, 21 Jul 2004 07:58:24 +0000 (GMT) (envelope-from eikemeier@fillmore-labs.com) Received: from dhcp-13.local ([172.16.0.13] helo=dhcp-11.local) by fillmore.dyndns.org with esmtp (TLSv1:DES-CBC3-SHA:168) (Exim 4.40 (FreeBSD)) id 1BnBzZ-000H7c-Il; Wed, 21 Jul 2004 09:58:24 +0200 Date: Wed, 21 Jul 2004 09:59:21 +0200 Content-Type: text/plain; charset=US-ASCII; format=flowed Mime-Version: 1.0 (Apple Message framework v482) To: Paul Schmehl From: Oliver Eikemeier In-Reply-To: <2147483647.1090366876@[192.168.2.102]> Message-Id: Content-Transfer-Encoding: 7bit User-Agent: KMail/1.5.9 cc: freebsd-rc@freebsd.org Subject: Re: rc script won't start daemon on reboot X-BeenThere: freebsd-rc@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Discussion related to /etc/rc.d design and implementation. List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 21 Jul 2004 07:58:27 -0000 Paul Schmehl wrote: > [...] > I've written a very simple rc script using the new format and rc.subr. > The script works fine from the commandline > (start|stop|restart|rcvar|status|poll), but when the server is > rebooted, the script fails to start the daemon. There are no errors in > /var/log/messages or in the extractor.log file, and the daemon is too > simplistically written to have a debug or verbose switch. Any ideas > what the problem could be? > [...] Try echo 'rc_debug="YES"' >> /etc/rc.conf and look at the trace info in /var/log/messages. -Oliver From owner-freebsd-rc@FreeBSD.ORG Wed Jul 21 10:15:14 2004 Return-Path: Delivered-To: freebsd-rc@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id E9BFB16A4CE for ; Wed, 21 Jul 2004 10:15:14 +0000 (GMT) Received: from telecom.net.et (ns2.telecom.net.et [213.55.64.38]) by mx1.FreeBSD.org (Postfix) with ESMTP id D3B7543D48 for ; Wed, 21 Jul 2004 10:15:12 +0000 (GMT) (envelope-from mtm@identd.net) Received: from [213.55.66.123] (HELO pool-151-200-10-97.res.east.verizon.net) by telecom.net.et (CommuniGate Pro SMTP 3.4.8) with ESMTP-TLS id 52201768; Wed, 21 Jul 2004 13:08:33 +0300 Received: from rogue.acs-et.com (localhost [127.0.0.1]) ESMTP id i6LAGGe7025283; Wed, 21 Jul 2004 13:16:17 +0300 (EAT) (envelope-from mtm@rogue.acs-et.com) Received: (from mtm@localhost) by rogue.acs-et.com (8.12.11/8.12.11/Submit) id i6LAGFRE025282; Wed, 21 Jul 2004 13:16:15 +0300 (EAT) (envelope-from mtm) Date: Wed, 21 Jul 2004 13:16:14 +0300 From: Mike Makonnen To: Paul Schmehl Message-ID: <20040721101614.GA25243@rogue.acs-et.com> References: <2147483647.1090366876@[192.168.2.102]> <20040721074439.GA1288@rogue.acs-et.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20040721074439.GA1288@rogue.acs-et.com> User-Agent: Mutt/1.4.2.1i X-Operating-System: FreeBSD/5.2-CURRENT (i386) cc: freebsd-rc@freebsd.org Subject: Re: rc script won't start daemon on reboot X-BeenThere: freebsd-rc@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Discussion related to /etc/rc.d design and implementation. List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 21 Jul 2004 10:15:15 -0000 On Wed, Jul 21, 2004 at 10:44:39AM +0300, Mike Makonnen wrote: > On Tue, Jul 20, 2004 at 11:41:16PM -0500, Paul Schmehl wrote: > > > > bash-2.05b# uname -v > > FreeBSD 4.8-RELEASE #0: Thu Apr 3 10:53:38 GMT 2003 > > root@freebsd-stable.sentex.ca:/usr/obj/usr/src/sys/GENERIC > > FreeBSD 4.x does not use the rc.d mechanism during boot. It has > a static rc(8). You should call the script from /etc/rc.local. > On second thought, nevermind. I didn't realize it was in /usr/local/etc/rc.d/, in which case it should be started with all the rest of the ports scripts. If your rc.subr supports it put rc_debug=yes in /etc/rc.conf and post a link to the output (it's quite verbose :-). Cheers. -- Mike Makonnen | GPG-KEY: http://www.identd.net/~mtm/mtm.asc mtm@identd.net | Fingerprint: AC7B 5672 2D11 F4D0 EBF8 5279 5359 2B82 7CD4 1F55 mtm@FreeBSD.Org| FreeBSD - Unleash the Daemon ! From owner-freebsd-rc@FreeBSD.ORG Wed Jul 21 17:37:43 2004 Return-Path: Delivered-To: freebsd-rc@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id DD3E616A4CE for ; Wed, 21 Jul 2004 17:37:43 +0000 (GMT) Received: from smtp1.utdallas.edu (smtp1.utdallas.edu [129.110.10.12]) by mx1.FreeBSD.org (Postfix) with ESMTP id B40E043D1F for ; Wed, 21 Jul 2004 17:37:43 +0000 (GMT) (envelope-from pauls@utdallas.edu) Received: from utd49554 (utd49554.utdallas.edu [129.110.3.85]) by smtp1.utdallas.edu (Postfix) with ESMTP id 8D6DF389005 for ; Wed, 21 Jul 2004 12:37:00 -0500 (CDT) Date: Wed, 21 Jul 2004 12:36:57 -0500 From: Paul Schmehl To: freebsd-rc@freebsd.org Message-ID: In-Reply-To: References: X-Mailer: Mulberry/3.1.6 (Linux/x86) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Content-Disposition: inline Subject: Re: rc script won't start daemon on reboot X-BeenThere: freebsd-rc@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Discussion related to /etc/rc.d design and implementation. List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 21 Jul 2004 17:37:44 -0000 --On Wednesday, July 21, 2004 09:59:21 AM +0200 Oliver Eikemeier wrote: > > Try > echo 'rc_debug="YES"' >> /etc/rc.conf > > and look at the trace info in /var/log/messages. > Here it is: /var/log/messages: Jul 21 12:23:06 smblure root: /usr/local/etc/rc.d/extractor.sh: INFO: checkyesno: extractor_enable is set to YES. Jul 21 12:23:06 smblure root: /usr/local/etc/rc.d/extractor.sh: INFO: run_rc_command: _doit: /usr/local/bin/extractor -D Despite this, the daemon did not start. bash-2.05b# /usr/local/etc/rc.d/extractor.sh status /usr/local/etc/rc.d/extractor.sh: DEBUG: checkyesno: extractor_enable is set to YES. extractor is not running. bash-2.05b# /usr/local/etc/rc.d/extractor.sh start /usr/local/etc/rc.d/extractor.sh: DEBUG: checkyesno: extractor_enable is set to YES. Starting extractor. /usr/local/etc/rc.d/extractor.sh: DEBUG: run_rc_command: _doit: /usr/local/bin/extractor -D DeepSight Extractor 4.3 Copyright 2000-2004, Symantec Using sensors file: /root/.extractor/Timestamps Using config file: /root/.extractor/ConfigFile.ini Initializing Daemon Mode. ********* * NOTE: * ********* When any of your logfiles are moved/renamed or rolled, you must kill -HUP the Extractor process. Please see the README-FIRST file for details. bash-2.05b# /usr/local/etc/rc.d/extractor.sh status /usr/local/etc/rc.d/extractor.sh: DEBUG: checkyesno: extractor_enable is set to YES. extractor is running as pid 229. This is really strange. It appears that the exact same command that fails during boot succeeds from the commandline. Is there a way to use ktrace to capture everything that's going on with this script during the reboot? I wonder if it matters that /usr/local/bin/extractor is a symlink to /usr/local/extractor/bin/extractor? bash-2.05b# ls -lsa /usr/local/bin/extractor 0 lrwxr-xr-x 1 root wheel 34 Jul 12 15:34 /usr/local/bin/extractor -> /usr/local/extractor/bin/extractor Paul Schmehl (pauls@utdallas.edu) Adjunct Information Security Officer The University of Texas at Dallas AVIEN Founding Member http://www.utdallas.edu/ir/security/ From owner-freebsd-rc@FreeBSD.ORG Thu Jul 22 08:59:18 2004 Return-Path: Delivered-To: freebsd-rc@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id E221F16A4CE for ; Thu, 22 Jul 2004 08:59:18 +0000 (GMT) Received: from fillmore.dyndns.org (port-212-202-50-15.dynamic.qsc.de [212.202.50.15]) by mx1.FreeBSD.org (Postfix) with ESMTP id 5CCE443D41 for ; Thu, 22 Jul 2004 08:59:18 +0000 (GMT) (envelope-from eikemeier@fillmore-labs.com) Received: from dhcp-14.local ([172.16.0.14] helo=dhcp-11.local) by fillmore.dyndns.org with esmtp (TLSv1:DES-CBC3-SHA:168) (Exim 4.40 (FreeBSD)) id 1BnZQ2-000Pvg-HX; Thu, 22 Jul 2004 10:59:17 +0200 Date: Thu, 22 Jul 2004 11:00:15 +0200 Content-Type: text/plain; charset=US-ASCII; format=flowed Mime-Version: 1.0 (Apple Message framework v482) To: Paul Schmehl From: Oliver Eikemeier In-Reply-To: Message-Id: <8C8C3455-DBBD-11D8-BA2D-00039312D914@fillmore-labs.com> Content-Transfer-Encoding: 7bit User-Agent: KMail/1.5.9 cc: freebsd-rc@freebsd.org Subject: Re: rc script won't start daemon on reboot X-BeenThere: freebsd-rc@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Discussion related to /etc/rc.d design and implementation. List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 22 Jul 2004 08:59:19 -0000 Paul Schmehl wrote: > --On Wednesday, July 21, 2004 09:59:21 AM +0200 Oliver Eikemeier > wrote: >> Try >> echo 'rc_debug="YES"' >> /etc/rc.conf >> >> and look at the trace info in /var/log/messages. >> > Here it is: > > /var/log/messages: > > Jul 21 12:23:06 smblure root: /usr/local/etc/rc.d/extractor.sh: INFO: > checkyesno: extractor_enable is set to YES. > Jul 21 12:23:06 smblure root: /usr/local/etc/rc.d/extractor.sh: INFO: > run_rc_command: _doit: /usr/local/bin/extractor -D > > Despite this, the daemon did not start. > > bash-2.05b# /usr/local/etc/rc.d/extractor.sh status > /usr/local/etc/rc.d/extractor.sh: DEBUG: checkyesno: extractor_enable > is set to YES. > extractor is not running. > > bash-2.05b# /usr/local/etc/rc.d/extractor.sh start > /usr/local/etc/rc.d/extractor.sh: DEBUG: checkyesno: extractor_enable > is set to YES. > Starting extractor. > /usr/local/etc/rc.d/extractor.sh: DEBUG: run_rc_command: _doit: > /usr/local/bin/extractor -D > DeepSight Extractor 4.3 > Copyright 2000-2004, Symantec > > Using sensors file: /root/.extractor/Timestamps > Using config file: /root/.extractor/ConfigFile.ini > > Initializing Daemon Mode. > > ********* > * NOTE: * > ********* > When any of your logfiles are moved/renamed or rolled, you must > kill -HUP the Extractor process. > Please see the README-FIRST file for details. > > bash-2.05b# /usr/local/etc/rc.d/extractor.sh status > /usr/local/etc/rc.d/extractor.sh: DEBUG: checkyesno: extractor_enable > is set to YES. > extractor is running as pid 229. > > This is really strange. It appears that the exact same command that > fails during boot succeeds from the commandline. > > Is there a way to use ktrace to capture everything that's going on with > this script during the reboot? I wonder if it matters that > /usr/local/bin/extractor is a symlink to > /usr/local/extractor/bin/extractor? > > bash-2.05b# ls -lsa /usr/local/bin/extractor > 0 lrwxr-xr-x 1 root wheel 34 Jul 12 15:34 > /usr/local/bin/extractor -> /usr/local/extractor/bin/extractor This violates hier(7), but should not be the cause of any of your current problems. Perhaps Extractor depends on PATH or other environment variables that are not set during startup. Of course you can replace the symlink with a small shell script dumping the environment and wrapping the call to extractor with truss (or ktrace), but I would try debugging options to extractor first, or contact Symantec support. Btw, when extractor supports SIGHUP you can set `extra_commands="reload"' -Oliver From owner-freebsd-rc@FreeBSD.ORG Fri Jul 23 22:48:36 2004 Return-Path: Delivered-To: freebsd-rc@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id CA21816A4CE for ; Fri, 23 Jul 2004 22:48:36 +0000 (GMT) Received: from smtp1.utdallas.edu (smtp1.utdallas.edu [129.110.10.12]) by mx1.FreeBSD.org (Postfix) with ESMTP id A051843D2F for ; Fri, 23 Jul 2004 22:48:36 +0000 (GMT) (envelope-from pauls@utdallas.edu) Received: from UTDEVS08.campus.ad.utdallas.edu (utdex08.utdallas.edu [129.110.70.103]) by smtp1.utdallas.edu (Postfix) with ESMTP id 5597A388D58 for ; Fri, 23 Jul 2004 17:48:36 -0500 (CDT) X-MIMEOLE: Produced By Microsoft Exchange V6.5.7226.0 Content-class: urn:content-classes:message MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Date: Fri, 23 Jul 2004 17:48:36 -0500 Message-ID: X-MS-Has-Attach: X-MS-TNEF-Correlator: Thread-Topic: rc script won't start daemon on reboot Thread-Index: AcRvyjTwdZEZV44MRayoqnni637EhQBPJz7w From: "Schmehl, Paul L" Cc: Subject: RE: rc script won't start daemon on reboot X-BeenThere: freebsd-rc@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Discussion related to /etc/rc.d design and implementation. List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 23 Jul 2004 22:48:36 -0000 > -----Original Message----- > From: Oliver Eikemeier [mailto:eikemeier@fillmore-labs.com]=20 > Sent: Thursday, July 22, 2004 4:00 AM > To: Schmehl, Paul L > Cc: freebsd-rc@freebsd.org > Subject: Re: rc script won't start daemon on reboot > > > > bash-2.05b# ls -lsa /usr/local/bin/extractor 0 lrwxr-xr-x 1 root =20 > > wheel 34 Jul 12 15:34 /usr/local/bin/extractor ->=20 > > /usr/local/extractor/bin/extractor >=20 > This violates hier(7), but should not be the cause of any of=20 > your current problems. Perhaps Extractor depends on PATH or=20 > other environment variables that are not set during startup.=20 > Of course you can replace the symlink with a small shell=20 > script dumping the environment and wrapping the call to=20 > extractor with truss (or ktrace), but I would try debugging=20 > options to extractor first, or contact Symantec support. Btw,=20 > when extractor supports SIGHUP you can set `extra_commands=3D"reload"' > Thanks for the tip. I assumed that extra_commands goes in the script, not in rc.conf, right? I rm'd the symlink and cp'd the actual binary, but that didn't change anything. For now, I think I'll just let it go. The cron job ensures that the binary will start within 15 minutes of a reboot, and that's good enough for me. Maybe when I have more time in the future, I'll revisit it and try to figure out what the heck is going on. Your idea of the wrapper script is a good one. =20 Paul Schmehl (pauls@utdallas.edu) Adjunct Information Security Officer The University of Texas at Dallas AVIEN Founding Member http://www.utdallas.edu/~pauls/=20 From owner-freebsd-rc@FreeBSD.ORG Fri Jul 23 23:06:15 2004 Return-Path: Delivered-To: freebsd-rc@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 680ED16A4CE for ; Fri, 23 Jul 2004 23:06:15 +0000 (GMT) Received: from fillmore.dyndns.org (port-212-202-50-15.dynamic.qsc.de [212.202.50.15]) by mx1.FreeBSD.org (Postfix) with ESMTP id 1566D43D2D for ; Fri, 23 Jul 2004 23:06:15 +0000 (GMT) (envelope-from eikemeier@fillmore-labs.com) Received: from dhcp-13.local ([172.16.0.13] helo=dhcp-11.local) by fillmore.dyndns.org with esmtp (TLSv1:DES-CBC3-SHA:168) (Exim 4.41 (FreeBSD)) id 1Bo97D-000KQd-4g; Sat, 24 Jul 2004 01:06:14 +0200 Date: Sat, 24 Jul 2004 01:07:13 +0200 Content-Type: text/plain; charset=US-ASCII; format=flowed Mime-Version: 1.0 (Apple Message framework v482) To: "Schmehl, Paul L" From: Oliver Eikemeier In-Reply-To: Message-Id: <08B735A5-DCFD-11D8-BA2D-00039312D914@fillmore-labs.com> Content-Transfer-Encoding: 7bit User-Agent: KMail/1.5.9 cc: freebsd-rc@freebsd.org Subject: Re: rc script won't start daemon on reboot X-BeenThere: freebsd-rc@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Discussion related to /etc/rc.d design and implementation. List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 23 Jul 2004 23:06:15 -0000 Schmehl, Paul L wrote: >> -----Original Message----- >> From: Oliver Eikemeier [mailto:eikemeier@fillmore-labs.com] >> Sent: Thursday, July 22, 2004 4:00 AM >> To: Schmehl, Paul L >> Cc: freebsd-rc@freebsd.org >> Subject: Re: rc script won't start daemon on reboot >>> >>> bash-2.05b# ls -lsa /usr/local/bin/extractor 0 lrwxr-xr-x 1 root >>> wheel 34 Jul 12 15:34 /usr/local/bin/extractor -> >>> /usr/local/extractor/bin/extractor >> >> This violates hier(7), but should not be the cause of any of >> your current problems. Perhaps Extractor depends on PATH or >> other environment variables that are not set during startup. >> Of course you can replace the symlink with a small shell >> script dumping the environment and wrapping the call to >> extractor with truss (or ktrace), but I would try debugging >> options to extractor first, or contact Symantec support. Btw, >> when extractor supports SIGHUP you can set `extra_commands="reload"' >> > Thanks for the tip. I assumed that extra_commands goes in the script, > not in rc.conf, right? Jup, is is documented in rc.subr(8), although not easy to find. > I rm'd the symlink and cp'd the actual binary, but that didn't change > anything. For now, I think I'll just let it go. The cron job ensures > that the binary will start within 15 minutes of a reboot, and that's > good enough for me. Maybe when I have more time in the future, I'll > revisit it and try to figure out what the heck is going on. Your idea > of the wrapper script is a good one. My first guess would be the environment, like PATH. Anyway, Symantec should care. Have you tried to contact them? Ah, and since you are concerned about security, have you tried portaudit? (Shameless hijack of this thread, please follow-up to freebsd-security@) -Oliver