William A. Knob wrote:
Hi all,
I have a problem using FIFO and Squid.
The problem is: I create a log with mkfifo to work with my personal
mysql logger, works fine. But when Logrotate runs, my fifo disapears!
Logrotate moves my original FIFO to a .1 FIFO and create an empty FILE
with the name of my fifo. Anyone knows how I make to logrotate create
another FIFO when it runs?
postrotate
/usr/sbin/squid -k rotate
endscript
Does whatever shell code you place between them. It's run AFTER the logs
are renumbered. The catch I have usually found with linux is that when
logrotate moves the logfile, its really only a rename. So any programs
with open writing to the file keep sending their stuff to the old .1
What you need in postrotate is something that causes the apps to close
their old file handles and open new ones against the pre-existing new
log file.
Amos
--
Please use Squid 2.7.STABLE1 or 3.0.STABLE6