Re: logrotate.d - reload vs restart

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]



On Mon, Dec 27, 2010, Frank Cox wrote:
>On Mon, 27 Dec 2010 16:31:29 -0500
>Nico Kadel-Garcia wrote:
>
>> */sbin/service* is working fine. It's just a shell script that finds
>> and passes arguments to the init scripts in /etc/rc.d/init.d/.
>> (/etc/init.d is a symlink to /etc/rc.d/init.d: don't be confused by
>> that.)
>> 
>> If the init script supports reload, then service will successfully
>> pass the argument to it. If it doesn't support reload, such as the
>> "privoxy" script in this case does not, then you'll need  to use
>> start, stop, or restart.
>
>Ah... gotcha!  I've learned something today....

There are many options to logrotate that control this, and things
like creating a new log file before reloading or restarting the
service (e.g. at least some syslogd programs will not work unless
their output log file(s) exist when they start.

The GNU shtool also provides log rotate functions which can be
used in cron jobs and such.

Bill
-- 
INTERNET:   bill@xxxxxxxxxxxxx  Bill Campbell; Celestial Software LLC
URL: http://www.celestial.com/  PO Box 820; 6641 E. Mercer Way
Voice:          (206) 236-1676  Mercer Island, WA 98040-0820
Fax:            (206) 232-9186  Skype: jwccsllc (206) 855-5792

When the customer has beaten upon you long enough, give him what he asks
for, instead of what he needs.  This is very strong medicine, and is
normally only required once.
    -- The Consultant's Curse:
_______________________________________________
CentOS mailing list
CentOS@xxxxxxxxxx
http://lists.centos.org/mailman/listinfo/centos


[Index of Archives]     [CentOS]     [CentOS Announce]     [CentOS Development]     [CentOS ARM Devel]     [CentOS Docs]     [CentOS Virtualization]     [Carrier Grade Linux]     [Linux Media]     [Asterisk]     [DCCP]     [Netdev]     [Xorg]     [Linux USB]
  Powered by Linux