Re: Logrotate Mechanics

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

 



David Cary Hart wrote:
> Typically, the post rotate script looks like:
> /bin/kill -HUP `cat /var/run/httpd.pid 2>/dev/null` \
>                  2> /dev/null || true
> 
> I get "cat /var/run/httpd.pid" to identify the process. In this case,
> what restarts httpd?
It does not get stopped. What the kill command is doing is sending
httpd the -HUP signal. This causes it to close and re-open the log
files, so it uses the new file, instead of the old file that was
processed by logrotate. The -HUP signal is commonly used to tell
a daemon to re-read its config file, or to re-open its log files.

Mikkel
-- 

  Do not meddle in the affairs of dragons,
for thou art crunchy and taste good with Ketchup!


[Index of Archives]     [Current Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]     [Fedora Docs]

  Powered by Linux