From owner-freebsd-questions Thu Oct 4 4:59:37 2001 Delivered-To: freebsd-questions@freebsd.org Received: from guru.mired.org (okc-65-31-203-60.mmcable.com [65.31.203.60]) by hub.freebsd.org (Postfix) with SMTP id 1729837B405 for ; Thu, 4 Oct 2001 04:59:34 -0700 (PDT) Received: (qmail 56041 invoked by uid 100); 4 Oct 2001 11:59:33 -0000 From: Mike Meyer MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Message-ID: <15292.20261.480669.377198@guru.mired.org> Date: Thu, 4 Oct 2001 06:59:33 -0500 To: Andreas Pauley Cc: questions@freebsd.org Subject: Re: Restarting Daemons in FreeBSD In-Reply-To: <93324075@toto.iv> X-Mailer: VM 6.90 under 21.1 (patch 14) "Cuyahoga Valley" XEmacs Lucid X-face: "5Mnwy%?j>IIV\)A=):rjWL~NB2aH[}Yq8Z=u~vJ`"(,&SiLvbbz2W`;h9L,Yg`+vb1>RG% *h+%X^n0EZd>TM8_IB;a8F?(Fb"lw'IgCoyM.[Lg#r\ Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Andreas Pauley types: > I've just made changes to my syslog.conf and the syslog startup > parameters in rc.conf Since nobody mentioned two things that make life a *lot* easier, I think I'll do so. > How do I restart syslog with the new flags in rc.conf, and how do I get > syslog to re-read its config if I just change something small in > syslog.conf? Changing the flags in rc.conf means you have to kill it and restart it by hand with the the flags copied in by hand. Or, if you're paranoid, by doing something like: # sh # start a shell we're going to toss later # killall syslogd # killall kills by process name # . /etc/rc.conf # Get the value for syslogd_flags # /usr/sbin/syslogd ${syslogd_flags} # Start syslogdf # exit # as promised, throw away the shell. > Is there a standard way to stop/start/restart daemons in FreeBSD? If the daemons were installed from ports, there's probably a script in /usr/local/etc/rc.d that starts and stops them. Invoke it with the option "stop" and then "start". Some of them may accept a "restart" argument as well; just read them and see. Many of the standard system daemons - which aren't started that way - will take a HUP signal to mean "reread configuration information." You can do that for syslogd like so: # killall -HUP syslogd For these, you have to read the man page. Hopefully, 5.0 (or maybe something before that) will include the NetBSD rc system, which combines the advantages of both the SysV system that most Linux distros use with those of the BSD rc.conf system. http://www.mired.org/home/mwm/ Q: How do you make the gods laugh? A: Tell them your plans. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message