[Bug 541802] New: syslog-ng needs 100% cpu usage on remote logging
http://bugzilla.novell.com/show_bug.cgi?id=541802 Summary: syslog-ng needs 100% cpu usage on remote logging Classification: openSUSE Product: openSUSE 11.1 Version: Final Platform: Other OS/Version: Other Status: NEW Severity: Normal Priority: P5 - None Component: Other AssignedTo: bnc-team-screening@forge.provo.novell.com ReportedBy: vogt@itwm.fraunhofer.de QAContact: qa@suse.de Found By: --- User-Agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.0.12) Gecko/2009071200 SUSE/3.0.12-0.1.2 Firefox/3.0.12 Mnenhy/0.7.6.666 Hello, today I noticed 100% CPU usage on my local syslog-ng daemon. I straced it: endless of these messages:
events=POLLIN}, {fd=5, events=POLLIN}], 8, 1028000) = 1 ([{fd=10, >revents=POLLERR}]) poll([{fd=7, events=0}, {fd=6, events=0}, {fd=8, events=0}, {fd=9, events=0}, >{fd=10, events=0}, {fd=3, events=POLLIN}, {fd=4, events=POLLIN}, {fd=5, >events=POLLIN}], 8, 1028000) = 1 ([{fd=10, revents=POLLERR}]) poll([{fd=7, events=0}, {fd=6, events=0}, {fd=8, events=0}, {fd=9, events=0}, [...]
Further debugging revealed: 1. the local syslog is configured to forward the messages to a loghost: I added locally in /etc/syslog-ng/syslog-ng.conf : (*)
destination a_udp { udp( "loghost" port(514) ); }; log { source(src); destination(a_udp); };
This forwards the locally generated messages to "loghost". But the remote syslog-ng was not running(!) Thus the bug is: - syslog-ng produces 100% cpu usage, if it send logging to a remote location which is not availabe (eg crashed) In the local log file you will find: Sep 24 16:07:10 syslog-ng[6128]: I/O error occurred while writing; fd='6' , error='Connection refused (111)' top: PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND 6246 root 20 0 23204 808 516 R 100 0.0 0:03.32 syslog-ng The cpu load of 100% occurs for around five minutes, then it comes down to normal cpu usage for maybe a minute, and then it starts over again with 100%. This is a bug IMHO. The rpm -qi for syslog-ng says:
This package contains Novell/SUSE specific modifications / extensions, please report problems using Bugzilla at https://bugzilla.novell.com/ before you contact the authors.
and among the features: * better network forwarding :-) (not) regards, Martin PS: I know that this bugs only shows up if something is wrong, but syslog-ng does not handle this corner case fine. Reproducible: Always Steps to Reproduce: 1.add (*) to you local syslog-ng.conf 2.change "loghost" to something which exists, but _not_ your local machine name 3.restart syslog 4. monitor with "top" Actual Results: 100 % cpu usage Expected Results: syslog should ignore it if it cannot send udp messages or something but should not eat up 100% cpu. -- Configure bugmail: http://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
http://bugzilla.novell.com/show_bug.cgi?id=541802
zhu rensheng
http://bugzilla.novell.com/show_bug.cgi?id=541802
http://bugzilla.novell.com/show_bug.cgi?id=541802#c1
Marius Tomaschewski
http://bugzilla.novell.com/show_bug.cgi?id=541802
http://bugzilla.novell.com/show_bug.cgi?id=541802#c2
Marius Tomaschewski
http://bugzilla.novell.com/show_bug.cgi?id=541802
http://bugzilla.novell.com/show_bug.cgi?id=541802#c3
--- Comment #3 from Marius Tomaschewski
http://bugzilla.novell.com/show_bug.cgi?id=541802
http://bugzilla.novell.com/show_bug.cgi?id=541802#c4
--- Comment #4 from Martin Vogt
http://bugzilla.novell.com/show_bug.cgi?id=541802
http://bugzilla.novell.com/show_bug.cgi?id=541802#c5
Marius Tomaschewski
Hello,
I still can reproduce the bug:
Swap: 1048568k total, 168k used, 1048400k free, 2796316k cached
PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND 23438 root 20 0 23204 924 612 S 100 0.0 1:53.00 syslog-ng
Have you used a remote host which is on (ping) but has not remote syslog running.
Yes.
If I have only a dns entry put the machine is off I could reproduce it either.
OK, I'll try now.
PS: I dont think thich should be closed, please give it another try.
Sure. -- Configure bugmail: http://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
http://bugzilla.novell.com/show_bug.cgi?id=541802
http://bugzilla.novell.com/show_bug.cgi?id=541802#c6
--- Comment #6 from Martin Vogt
If I have only a dns entry put the machine is off I could reproduce it either. Should be If I have only a dns entry _b_ut the machine is off I could_n't_ reproduce it either.
-- Configure bugmail: http://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
http://bugzilla.novell.com/show_bug.cgi?id=541802
http://bugzilla.novell.com/show_bug.cgi?id=541802#c7
--- Comment #7 from Martin Vogt
http://bugzilla.novell.com/show_bug.cgi?id=541802
http://bugzilla.novell.com/show_bug.cgi?id=541802#c8
--- Comment #8 from Marius Tomaschewski
http://bugzilla.novell.com/show_bug.cgi?id=541802
http://bugzilla.novell.com/show_bug.cgi?id=541802#c9
--- Comment #9 from Martin Vogt
http://bugzilla.novell.com/show_bug.cgi?id=541802
http://bugzilla.novell.com/show_bug.cgi?id=541802#c10
Marius Tomaschewski
http://bugzilla.novell.com/show_bug.cgi?id=541802
http://bugzilla.novell.com/show_bug.cgi?id=541802#c11
Martin Vogt
http://bugzilla.novell.com/show_bug.cgi?id=541802
http://bugzilla.novell.com/show_bug.cgi?id=541802#c12
--- Comment #12 from Marius Tomaschewski
http://bugzilla.novell.com/show_bug.cgi?id=541802
http://bugzilla.novell.com/show_bug.cgi?id=541802#c
Swamp Workflow Management
http://bugzilla.novell.com/show_bug.cgi?id=541802
http://bugzilla.novell.com/show_bug.cgi?id=541802#c14
Swamp Workflow Management
http://bugzilla.novell.com/show_bug.cgi?id=541802
http://bugzilla.novell.com/show_bug.cgi?id=541802#c17
Swamp Workflow Management
http://bugzilla.novell.com/show_bug.cgi?id=541802
http://bugzilla.novell.com/show_bug.cgi?id=541802#c18
Swamp Workflow Management
http://bugzilla.novell.com/show_bug.cgi?id=541802
http://bugzilla.novell.com/show_bug.cgi?id=541802#c
Swamp Workflow Management
https://bugzilla.novell.com/show_bug.cgi?id=541802
https://bugzilla.novell.com/show_bug.cgi?id=541802#c19
Marius Tomaschewski
participants (1)
-
bugzilla_noreply@novell.com