On Sun, Sep 7, 2014 at 2:43 AM, O. Hartmann <ohart...@zedat.fu-berlin.de> wrote:
> Am Sun, 7 Sep 2014 15:33:42 +0800
> Erich Dollansky <er...@alogt.com> schrieb:
>> Hi,
>> On Sun, 7 Sep 2014 09:03:21 +0200
>> "O. Hartmann" <ohart...@zedat.fu-berlin.de> wrote:
>> >
>> > I use a service (textprox/refdb from ports, refdb_enable="YES"
>> > in /etc/rc.conf.local) that is supposed to startup at boottime. On
>> > one CURRENT system, running
>> >
>> >  FreeBSD 11.0-CURRENT #3 r271210: Sat Sep  6 22:39:59 CEST 2014 amd64
>> >
>> > the service is not started at boottime, but I can start the service
>> > manually via
>> >
>> > service refdb start
>> >
>> > I tried enabling rc_debug=YES in /etc/rc.conf but I do not see any
>> > failure of the start attempt of that specific service in the logs or
>> > on the console.
>> >
>> > Is there an elegant way to debug rc.d and the startup procedure
>> > without having the system reboot (I do not have jails or VM, sorry)?
>> >
>> could it be that the spelling in either rc.conf and the spelling in the
>> actual script differ so that FreeBSD does not start it?
>> Erich
> No. If it would be the case, I guess starting it manually wouldn't work 
> either. The fact
> is that the port textproc/refdb uses a startup script named "refdb.sh" and by 
> maintaining
> the port and on the way to make it more CURRENT compliant, I started with 
> renaming it to
> "refdb" and it seems this is the culprit.
> The script textproc/refdb uses is a bit awkward since it targets both *BSD 
> and Linux
> init/rc scripts and the initial rc.d/refddb scripts gives control to another 
> script
> called refdbctl which seems to perform all the stuff FreeBSD's /etc/rc.subr 
> is providing.
> I renamed the script back to "refdb.sh" by now and the service starts again as
> expected.  I guess the spawning into a subshell fails somehow at that point 
> when booting
> the box.

I had a look at scripts/refdb.in, it is not a proper rc script for
FreeBSD, as it is missing several keywords:

# PROVIDE: <- all scripts need this
# KEYWORD: <- optional

Which tells rcorder where to put refdb in the startup order.  Since
these are missing, rcorder doesn't place it in the startup list.

The following will show you the order that your startup scripts run,
refdb may not be listed:

rcorder /etc/rc.d/* /usr/local/etc/rc.d/*

Some one will have to create a proper rc script by looking at what
both scripts/refdb.in and scripts/refdbctl.in do.

The reason that you are able to use service to start refdb, is due to
service doesn't check the scripts header for the keywords.


No electrons were maimed while sending this message. Only slightly bruised.
freebsd-current@freebsd.org mailing list
To unsubscribe, send any mail to "freebsd-current-unsubscr...@freebsd.org"

Reply via email to