<div dir="ltr">thks<br>but i want the change bee sent in (real time) if we can use this term<br>because follow_freq(1) means that syslog need to check tchangee in the fie every 1 second<br>is there any way to make it 0 second ====> detect changes in the apache error log as they happen<br>
thks<br><br><div class="gmail_quote">2009/3/10 Balazs Scheidler <span dir="ltr"><<a href="mailto:bazsi@balabit.hu" target="_blank">bazsi@balabit.hu</a>></span><br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<div><div></div><div>On Mon, 2009-03-09 at 02:36 +0100, gatfi sami wrote:<br>
> hi i am using syslog-ng 2.0.9.1 on open suse 11.0<br>
><br>
> i configured this littele script in /etc/syslog-ng/syslog-ng.conf<br>
><br>
> source my_src { file("/var/log/apache2/error_log"); };<br>
><br>
> #filter my_filter { };<br>
><br>
> destination my_dest{ file("/var/log/Sami/$HOST/messages"<br>
> owner("root") group("root") perm(0640) dir_perm(0750)<br>
> create_dirs(yes));<br>
> };<br>
><br>
> log { source(my_src); #filter(my_filter);<br>
> destination(my_dest); };<br>
> the problem is when i restart apache2 while using the tail<br>
> -f /var/log/Sami/$HOST/messages<br>
><br>
> nothing happens i have to restart syslog-ng to see those errors<br>
><br>
> by the way i stoped the apparmor to avoid a permission denied on the<br>
> destination driver<br>
<br>
</div></div>Since you are using 2.0, you need to explicitly specify for syslog-ng<br>
that you want to poll the file for changes. You can do this via the<br>
follow-freq() option, e.g.<br>
<br>
file("/var/log/apache2/error_log" follow_freq(1));<br>
<br>
In 3.0, the default value for follow_freq() for regular files is 1<br>
seconds, so you wouldn't have to specify it explicitly.<br>
<font color="#888888"><br>
--<br>
Bazsi<br>
<br>
<br>
______________________________________________________________________________<br>
Member info: <a href="https://lists.balabit.hu/mailman/listinfo/syslog-ng" target="_blank">https://lists.balabit.hu/mailman/listinfo/syslog-ng</a><br>
Documentation: <a href="http://www.balabit.com/support/documentation/?product=syslog-ng" target="_blank">http://www.balabit.com/support/documentation/?product=syslog-ng</a><br>
FAQ: <a href="http://www.campin.net/syslog-ng/faq.html" target="_blank">http://www.campin.net/syslog-ng/faq.html</a><br>
<br>
</font></blockquote></div><br></div>