Subject: Re: rc.d: client-server dependencies
To: John Nemeth <firstname.lastname@example.org>
From: Mike M. Volokhov <mishka@NetBSD.org>
Date: 08/15/2006 13:12:16
John Nemeth <email@example.com> wrote:
> On Jan 5, 5:34am, "Mike M. Volokhov" wrote:
> } Geert Hendrickx <ghen@NetBSD.org> wrote:
> } >
> } > I'm playing around with sysutils/ups-nut, a collection of networked UPS
> } > tools. There's a client upsmon which connects to a server upsd, either
> } > locally or over the network. The rc.d script for upsmon has:
> } >
> } > # PROVIDE: upsmon
> } > # REQUIRE: upsd
> } >
> } > As a consequence, when running "/etc/rc.d/upsmon start" on a client-only
> } > machine (where upsd runs on a different machine), it says:
> } >
> } > WARNING: $upsmon is not set properly - see rc.conf(5).
> This problem can be solved by putting "# BEFORE: upsmon" in
> /etc/rc.d/upsd, and removing the "# REQUIRE: upsd" from
> /etc/rc.d/upsmon. This way you can run upsmon without upsd, but if you
> do use upsd, you are guaranteed that it will start before upsmon.
> } There is another problem with such setup - rcorder(8) will not find upsd
> } via dependency list (real message may be different):
> } rcorder: requirement `upsd' in file `upsmon' has no providers.
> } To solve this you need fake upsd script, or implemented optional dependency,
> } like in bin/25785.
> The ups-nut package can be fixed as above.
Only if upsd will always be installed with upsmon. Otherwise it tuns upsmon's
problem into upsd's one :-)
(I don't know is upsmon installed by dependency of upsd.)
> As for the PR, since you're a developer now, why don't you commit
> the patch? If you don't feel comfortable doing it, ask your sponsor or
> lukem for advice.
To be honest, I've forgot about it. At that moment we're running
dedicated antivirus server and boot process wasn't smooth because
of absent AV rcd scripts. But system was refactored an this PR
becames no more actual for me.
But, of course, this doesn't solve roots of the problem. So I'll
raise this question once more, and if there are will no objections
I will commit the changes.