Proper way to start a program at log-on

Christopher Nehren apeiron at
Mon May 24 11:51:34 PDT 2004

On Sun, May 23, 2004 at 21:42:04 EDT, Kirk Strauser scribbled these
curious markings:
> Nope, that's fine.  Of course, you *could* just leave it running forever, if
> you really wanted to.

No, it is anything _but_ fine. If Gerard makes a mistake with
mergemaster, his shutdown changes are lost. The proper way to do so is, 
as others have suggested, to place a script in /usr/local/etc/rc.d/. If 
you want to do it completely properly, using rcNG (with rc.subr and
rc.conf) is the way to go.

Generally speaking, any well-behaved port leaves /etc alone completely. 
The only change that you should ever have to make to anything in /etc 
is a ${portname}_enable="YES" in /etc/rc.conf, if the port uses rcNG. 
Having third-party software muck around in /etc (especially things like
a shutdown script) is a Linux prob ... er ... methodology. I'd hate to
think of what would happen if an entry in /etc/rc.shutdown was
incorrect, and caused the script to fail, thus not returning 0...

I abhor a system designed for the "user", if that word is a coded
pejorative meaning "stupid and unsophisticated".  -- Ken Thompson
Unix is user friendly. However, it isn't idiot friendly.
Please CC me in all replies, even if I'm on the relevant list(s).
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 187 bytes
Desc: not available
Url :

More information about the freebsd-questions mailing list