[Bug 828228] New: cups poll runs busy-loop at ca 5% CPU
https://bugzilla.novell.com/show_bug.cgi?id=828228 https://bugzilla.novell.com/show_bug.cgi?id=828228#c0 Summary: cups poll runs busy-loop at ca 5% CPU Classification: openSUSE Product: openSUSE 12.3 Version: Final Platform: Other OS/Version: Other Status: NEW Severity: Normal Priority: P5 - None Component: Printing AssignedTo: jsmeix@suse.com ReportedBy: jw@suse.com QAContact: jsmeix@suse.com Found By: --- Blocker: --- since todays online updates, I have a cups-poll process that constantly consumes cpu. strace shows this again and again: .. connect(4, {sa_family=AF_INET, sin_port=htons(631), sin_addr=inet_addr("10.120.0.103")}, 16) = 0 time(NULL) = 1372962892 time(NULL) = 1372962892 time(NULL) = 1372962892 time(NULL) = 1372962892 time(NULL) = 1372962892 time(NULL) = 1372962892 time(NULL) = 1372962892 time(NULL) = 1372962892 send(4, "POST / HTTP/1.1\r\nContent-Length: 338\r\nContent-Type: application/ipp\r\nHost: cups.suse.de\r\nUser-Agent: CUPS/1.5.4\r\nExpect: 100-continue\r\n\r\n", 137, 0) = 137 time(NULL) = 1372962892 time(NULL) = 1372962892 time(NULL) = 1372962892 time(NULL) = 1372962892 time(NULL) = 1372962892 time(NULL) = 1372962892 time(NULL) = 1372962892 send(4, "\1\1@\2\0\0\0\1\1G\0\22attributes-charset\0\5utf-8H\0\33attributes-natural-language\0\5en-usD\0\24requested-attributes\0\22job-sheets-defaultD\0\0\0\fprinter-infoD\0\0\0\31printer-is-accepting-jobsD\0\0\0\20printer-locationD\0\0\0\26printer-make-and-modelD\0\0\0\fprinter-nameD\0\0\0\rprinter-stateD\0\0\0\fprinter-typeD\0\0\0\25printer-uri-supported#\0\fprinter-type\0\4\0\0\0\0#\0\21printer-type-mask\0\4\0!\0\2\3", 338, 0) = 338 poll([{fd=4, events=POLLIN}], 1, 1000) = 1 ([{fd=4, revents=POLLIN}]) poll([{fd=4, events=POLLIN}], 1, 60000) = 1 ([{fd=4, revents=POLLIN}]) recv(4, "HTTP/1.1 403 Forbidden\r\nDate: Thu, 04 Jul 2013 18:34:53 GMT\r\nServer: CUPS/1.3\r\nContent-Language: en\r\nUpgrade: TLS/1.0,HTTP/1.1\r\nConnection: close\r\nContent-Type: text/html; charset=utf-8\r\nContent-Length: 340\r\n\r\n<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.0 Transitional//EN\" \"http://www.w3.org/TR/REC-html40/loose.dtd\">\n<HTML>\n<HEAD>\n\t<META HTTP-EQUIV=\"Content-Type\" CONTENT=\"text/html; charset=utf-8\">\n\t<TITLE>403 Forbidden</TITLE>\n\t<LINK REL=\"STYLESHEET\" TYPE=\"text/css\" HREF=\"/cups.css\">\n</HEAD>\n<BODY>\n<H1>403 Forbidden</H1>\n<P></P>\n</BODY>\n</HTML>\n", 2048, 0) = 550 time(NULL) = 1372962892 .. -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=828228 https://bugzilla.novell.com/show_bug.cgi?id=828228#c1 Johannes Meixner <jsmeix@suse.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |NEEDINFO Platform|Other |All Found By|--- |Development InfoProvider| |jw@suse.com Summary|cups poll runs busy-loop at |cups-polld runs busy-loop |ca 5% CPU |at ca 5% CPU OS/Version|Other |openSUSE 12.3 --- Comment #1 from Johannes Meixner <jsmeix@suse.com> 2013-07-05 08:55:04 CEST --- What are the cups-polld comand line arguments? I.e. what shows a command like # ps auxw | grep cups-polld What is the content of your /etc/cups/cupsd.conf file? -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=828228 https://bugzilla.novell.com/show_bug.cgi?id=828228#c2 --- Comment #2 from Johannes Meixner <jsmeix@suse.com> 2013-07-05 09:17:34 CEST --- Regarding "since todays online updates": There are no updates for CUPS for openSUSE 12.3. -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=828228 https://bugzilla.novell.com/show_bug.cgi?id=828228#c3 --- Comment #3 from Johannes Meixner <jsmeix@suse.com> 2013-07-05 09:36:44 CEST --- I cannot reproduce it. Neither with the official CUPS for openSUSE 12.3 nor with the newest CUPS from the openSUSE "Printing" project. A RPM update from the official CUPS for openSUSE 12.3 to the newest CUPS from the openSUSE "Printing" project "just works" for me. I have this cups-polld configuration in my /etc/cups/cupsd.conf ------------------------------------------------------------------------- # Show shared printers on the local network. Browsing On BrowseOrder allow,deny BrowseDeny from all #BrowseAllow all #BrowseLocalProtocols CUPS BrowsePoll 10.120.0.103 ------------------------------------------------------------------------- Here the log of my RPM update: ------------------------------------------------------------------------- # ps auxw | grep cups root 4804 ... /usr/sbin/cupsd -f lp 4805 ... cups-polld 10.120.0.103 631 30 631 .. # osc getbinaries Printing cups openSUSE_12.3 i586 .. # rpm -Uhv binaries/cups-1.5.4-120.1.i586.rpm \ binaries/cups-client-1.5.4-120.1.i586.rpm \ binaries/cups-libs-1.5.4-120.1.i586.rpm .. redirecting to systemctl try-restart cups .. # ps auxw | grep cups root 4909 ... /usr/sbin/cupsd -f lp 4910 ... cups-polld 10.120.0.103 631 30 631 ------------------------------------------------------------------------- For both cups-polld processes (before and after the update) "strace -p <cups-polld PID>" shows the same behaviour: Several sendto() calls with a one second sleep in between and then a longer sleep for 20 seconds in my case and then again the sendto() calls... -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=828228 https://bugzilla.novell.com/show_bug.cgi?id=828228#c4 --- Comment #4 from Juergen Weigert <jw@suse.com> 2013-07-05 09:48:41 UTC --- Created an attachment (id=546933) --> (http://bugzilla.novell.com/attachment.cgi?id=546933) /etc/cups/cupsd.conf -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=828228 https://bugzilla.novell.com/show_bug.cgi?id=828228#c5 Juergen Weigert <jw@suse.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEEDINFO |NEW InfoProvider|jw@suse.com | --- Comment #5 from Juergen Weigert <jw@suse.com> 2013-07-05 09:49:59 UTC --- I had killed cups-polld, sudo rccups restart brings it back, again eating CPU. $ ps auxw | grep cups root 16040 0.5 0.1 11148 5236 ? Ss 11:36 0:01 /usr/sbin/cupsd -f lp 16043 3.6 0.0 6700 1940 ? S 11:36 0:11 cups-polld cups.suse.de 631 30 631 I have commented out all the Browse* lines that differ from yours, and added the BrowseDeny line to match yours. still eats CPU after restart. Browsing On BrowseOrder allow,deny BrowseDeny from all # BrowseAllow all # BrowseRemoteProtocols CUPS # BrowseAddress @LOCAL # BrowseLocalProtocols CUPS BrowsePoll cups.suse.de -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=828228 https://bugzilla.novell.com/show_bug.cgi?id=828228#c6 --- Comment #6 from Juergen Weigert <jw@suse.com> 2013-07-05 10:02:41 UTC --- I am pulling packages from Pringing: The following packages are going to be upgraded: cups 1.5.4-5.2.1 -> 1.5.4-120.1 cups-client 1.5.4-5.2.1 -> 1.5.4-120.1 cups-libs 1.5.4-5.2.1 -> 1.5.4-120.1 still eats cpu after restart. -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=828228 https://bugzilla.novell.com/show_bug.cgi?id=828228#c7 --- Comment #7 from Juergen Weigert <jw@suse.com> 2013-07-05 10:05:09 UTC --- Created an attachment (id=546937) --> (http://bugzilla.novell.com/attachment.cgi?id=546937) unabreviated strace (duration 4 seconds) -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=828228 https://bugzilla.novell.com/show_bug.cgi?id=828228#c8 Johannes Meixner <jsmeix@suse.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Priority|P5 - None |P3 - Medium Status|NEW |ASSIGNED Summary|cups-polld runs busy-loop |cups-polld runs busy-loop |at ca 5% CPU |doing retries to connect to | |servers which reject it --- Comment #8 from Johannes Meixner <jsmeix@suse.com> 2013-07-05 14:15:00 CEST --- I reproduced it on your machine. It has IP address 149.*.*.* Connecting from that IP address to the cups.suse.de server gets rejected by cups.suse.de with a "Forbidden" error because cups.suse.de allows access only from the 10.12[0123].*.* addresses. The bug in the scheduler/cups-polld.c source is that it does not sleep in this case but does endless retries to connect to the server. -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=828228 https://bugzilla.novell.com/show_bug.cgi?id=828228#c9 --- Comment #9 from Johannes Meixner <jsmeix@suse.com> 2013-07-05 14:40:29 CEST --- FYI: The issue exists since a long time in cups-polld (at least since CUPS 1.3.9) so that it has nothing to do with "todays online updates". -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=828228 https://bugzilla.novell.com/show_bug.cgi?id=828228#c10 --- Comment #10 from Johannes Meixner <jsmeix@suse.com> 2013-07-05 15:03:56 CEST --- Created an attachment (id=546970) --> (http://bugzilla.novell.com/attachment.cgi?id=546970) cups-polld_avoid_busy_loop.patch cups-polld_avoid_busy_loop.patch avoids any possible busy loop in cups-polld in case of unusual issues by sleeping interval seconds. -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=828228 https://bugzilla.novell.com/show_bug.cgi?id=828228#c11 Johannes Meixner <jsmeix@suse.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|ASSIGNED |RESOLVED Resolution| |FIXED --- Comment #11 from Johannes Meixner <jsmeix@suse.com> 2013-07-05 15:04:32 CEST --- Submitted fixed cups package to OBS "Printing" project via submitrequest 182308 and forwarded this to openSUSE:Factory via submitrequest 182309 -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=828228 https://bugzilla.novell.com/show_bug.cgi?id=828228#c12 --- Comment #12 from Bernhard Wiedemann <bwiedemann@suse.com> 2013-07-05 16:00:18 CEST --- This is an autogenerated message for OBS integration: This bug (828228) was mentioned in https://build.opensuse.org/request/show/182309 Factory / cups -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=828228 https://bugzilla.novell.com/show_bug.cgi?id=828228#c13 --- Comment #13 from Juergen Weigert <jw@suse.com> 2013-07-05 15:55:54 UTC --- Johannes, thank you! -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
participants (1)
-
bugzilla_noreply@novell.com