Subject: Re: starting package with /etc/rc.d
To: Geert Hendrickx <firstname.lastname@example.org>
From: Iain Hibbert <email@example.com>
Date: 11/23/2005 21:29:54
On Wed, 23 Nov 2005, Geert Hendrickx wrote:
> On Wed, Nov 23, 2005 at 11:47:19AM +0000, Iain Hibbert wrote:
> > 1. I have nullmailer=YES set in my /etc/rc.conf file.
> > 2. During bootup I get a "Starting Nullmailer." message but nullmailer is
> > not started and no messages are logged to /var/log/messages or the
> > console.
> > 3. "/etc/rc.d/nullmailer start" as root starts nullmailer just fine and
> > messages are logged to /var/log/messages as normal..
> Is your /etc/rc.d/nullmailer a symlink to /usr/pkg/...? If /usr is on a
> separate partition, it's not yet mounted at the time rcorder is ran, and
> the nullmailer script will not be invoked afterwards. The script itself
> must be on your / partition (in /etc/rc.d/).
/etc/rc.d/nullmailer script is all present and correct, mode 555 and owned
by root.wheel ...
hmm. casting about randomly.. the command to be executed according to
the "sh -x" output when I ran it normally is probably:
su -m nullmail -c 'sh -c "/usr/pkg/libexec/nullmailer-send .."'
the executable is present, but thinking about su
-m leave environment intact - I think this has nothing to do with it,
there is no nullmailer environment set in my user profile that I know of
(there used to be, but fetchmail complained about it)
-c specify a login class - I know nothing about this, and have no
/etc/login.conf file, is that likely to be important? (how does that work?
the man page seems to think it should have an argument, is that the shell
nullmail is a user present and correct in /etc/passwd (and master). I
wonder if having home directory as /nonexistent and user shell as
/sbin/nologin would make a difference to su? (except that it works when I
run it from a root shell..)