Bug 1368909 - gnome-settings-daemons spins using full CPU if it cannot connect to cups
Summary: gnome-settings-daemons spins using full CPU if it cannot connect to cups
Keywords:
Status: CLOSED DUPLICATE of bug 1366775
Alias: None
Product: Fedora
Classification: Fedora
Component: gnome-settings-daemon
Version: 25
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Bastien Nocera
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2016-08-22 05:13 UTC by Zbigniew Jędrzejewski-Szmek
Modified: 2016-09-01 10:38 UTC (History)
7 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2016-09-01 10:38:42 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description Zbigniew Jędrzejewski-Szmek 2016-08-22 05:13:54 UTC
Description of problem:
I just upgraded to F25. I disabled cups.{socket,service,path} a long time ago, because I don't own any printers. Unfortunately it seems that gnome-settings-daemon in F25 cannot deal with not being able to connect to localhost:631:

$ ps u 5093
USER       PID %CPU %MEM    VSZ   RSS TTY      STAT START   TIME COMMAND
zbyszek   5093 84.3  0.9 873196 37852 tty2     Rl+  00:55  12:11 /usr/libexec/gnome-settings-daemon

$ strace -s999 -p 5093 -tt
...
01:07:05.499324 socket(AF_INET6, SOCK_STREAM, IPPROTO_IP) = 22
01:07:05.499373 setsockopt(22, SOL_SOCKET, SO_REUSEADDR, [1], 4) = 0
01:07:05.499414 setsockopt(22, SOL_SOCKET, SO_REUSEPORT, [1], 4) = 0
01:07:05.499455 setsockopt(22, SOL_TCP, TCP_NODELAY, [1], 4) = 0
01:07:05.499495 fcntl(22, F_SETFD, FD_CLOEXEC) = 0
01:07:05.499537 fcntl(22, F_GETFL)      = 0x2 (flags O_RDWR)
01:07:05.499574 fcntl(22, F_SETFL, O_RDWR|O_NONBLOCK) = 0
01:07:05.499624 connect(22, {sa_family=AF_INET6, sin6_port=htons(631), inet_pton(AF_INET6, "::1", &sin6_addr), sin6_flowinfo=htonl(0), sin6_scope_id=0}, 28) = -1 EINPROGRESS (Operation now in progress)
01:07:05.499713 fcntl(22, F_SETFL, O_RDWR) = 0
01:07:05.499752 poll([{fd=22, events=POLLIN|POLLOUT}], 1, 100) = 1 ([{fd=22, revents=POLLIN|POLLOUT|POLLERR|POLLHUP}])
01:07:05.499806 sendto(22, "POST / HTTP/1.1\r\nContent-Length: 722\r\nContent-Type: application/ipp\r\nHost: localhost:631\r\nUser-Agent: CUPS/2.2rc1 (Linux 4.6.7-300.fc24.x86_64; x86_64) IPP/2.0\r\nExpect: 100-continue\r\n\r\n", 185, 0, NULL, 0) = -1 ECONNREFUSED (Connection refused)
01:07:05.499858 sendto(22, "POST / HTTP/1.1\r\nContent-Length: 722\r\nContent-Type: application/ipp\r\nHost: localhost:631\r\nUser-Agent: CUPS/2.2rc1 (Linux 4.6.7-300.fc24.x86_64; x86_64) IPP/2.0\r\nExpect: 100-continue\r\n\r\n", 185, 0, NULL, 0) = -1 EPIPE (Broken pipe)
01:07:05.499911 --- SIGPIPE {si_signo=SIGPIPE, si_code=SI_USER, si_pid=5093, si_uid=1002} ---
01:07:05.499936 sendto(22, "POST / HTTP/1.1\r\nContent-Length: 722\r\nContent-Type: application/ipp\r\nHost: localhost:631\r\nUser-Agent: CUPS/2.2rc1 (Linux 4.6.7-300.fc24.x86_64; x86_64) IPP/2.0\r\nExpect: 100-continue\r\n\r\n", 185, 0, NULL, 0) = -1 EPIPE (Broken pipe)
01:07:05.499985 --- SIGPIPE {si_signo=SIGPIPE, si_code=SI_USER, si_pid=5093, si_uid=1002} ---
01:07:05.500009 close(22)               = 0
01:07:05.500055 socket(AF_INET6, SOCK_STREAM, IPPROTO_IP) = 22
01:07:05.500105 setsockopt(22, SOL_SOCKET, SO_REUSEADDR, [1], 4) = 0
01:07:05.500146 setsockopt(22, SOL_SOCKET, SO_REUSEPORT, [1], 4) = 0
01:07:05.500188 setsockopt(22, SOL_TCP, TCP_NODELAY, [1], 4) = 0
01:07:05.500228 fcntl(22, F_SETFD, FD_CLOEXEC) = 0
01:07:05.500265 fcntl(22, F_GETFL)      = 0x2 (flags O_RDWR)
01:07:05.500305 fcntl(22, F_SETFL, O_RDWR|O_NONBLOCK) = 0
01:07:05.500343 connect(22, {sa_family=AF_INET6, sin6_port=htons(631), inet_pton(AF_INET6, "::1", &sin6_addr), sin6_flowinfo=htonl(0), sin6_scope_id=0}, 28) = -1 EINPROGRESS (Operation now in progress)
01:07:05.500432 fcntl(22, F_SETFL, O_RDWR) = 0
01:07:05.500471 poll([{fd=22, events=POLLIN|POLLOUT}], 1, 100) = 1 ([{fd=22, revents=POLLIN|POLLOUT|POLLERR|POLLHUP}])
01:07:05.500525 sendto(22, "POST / HTTP/1.1\r\nContent-Length: 722\r\nContent-Type: application/ipp\r\nHost: localhost:631\r\nUser-Agent: CUPS/2.2rc1 (Linux 4.6.7-300.fc24.x86_64; x86_64) IPP/2.0\r\nExpect: 100-continue\r\n\r\n", 185, 0, NULL, 0) = -1 ECONNREFUSED (Connection refused)
01:07:05.500579 sendto(22, "POST / HTTP/1.1\r\nContent-Length: 722\r\nContent-Type: application/ipp\r\nHost: localhost:631\r\nUser-Agent: CUPS/2.2rc1 (Linux 4.6.7-300.fc24.x86_64; x86_64) IPP/2.0\r\nExpect: 100-continue\r\n\r\n", 185, 0, NULL, 0) = -1 EPIPE (Broken pipe)
01:07:05.500652 --- SIGPIPE {si_signo=SIGPIPE, si_code=SI_USER, si_pid=5093, si_uid=1002} ---
01:07:05.500675 sendto(22, "POST / HTTP/1.1\r\nContent-Length: 722\r\nContent-Type: application/ipp\r\nHost: localhost:631\r\nUser-Agent: CUPS/2.2rc1 (Linux 4.6.7-300.fc24.x86_64; x86_64) IPP/2.0\r\nExpect: 100-continue\r\n\r\n", 185, 0, NULL, 0) = -1 EPIPE (Broken pipe)
01:07:05.500726 --- SIGPIPE {si_signo=SIGPIPE, si_code=SI_USER, si_pid=5093, si_uid=1002} ---
01:07:05.500750 close(22)               = 0
01:07:05.500793 socket(AF_INET6, SOCK_STREAM, IPPROTO_IP) = 22
01:07:05.500849 setsockopt(22, SOL_SOCKET, SO_REUSEADDR, [1], 4) = 0
01:07:05.500892 setsockopt(22, SOL_SOCKET, SO_REUSEPORT, [1], 4) = 0
01:07:05.500938 setsockopt(22, SOL_TCP, TCP_NODELAY, [1], 4) = 0
01:07:05.500981 fcntl(22, F_SETFD, FD_CLOEXEC) = 0
01:07:05.501023 fcntl(22, F_GETFL)      = 0x2 (flags O_RDWR)
01:07:05.501066 fcntl(22, F_SETFL, O_RDWR|O_NONBLOCK) = 0
01:07:05.501108 connect(22, {sa_family=AF_INET6, sin6_port=htons(631), inet_pton(AF_INET6, "::1", &sin6_addr), sin6_flowinfo=htonl(0), sin6_scope_id=0}, 28) = -1 EINPROGRESS (Operation now in progress)
01:07:05.501193 fcntl(22, F_SETFL, O_RDWR) = 0
01:07:05.501232 poll([{fd=22, events=POLLIN|POLLOUT}], 1, 100) = 1 ([{fd=22, revents=POLLIN|POLLOUT|POLLERR|POLLHUP}])
01:07:05.501285 sendto(22, "POST / HTTP/1.1\r\nContent-Length: 722\r\nContent-Type: application/ipp\r\nHost: localhost:631\r\nUser-Agent: CUPS/2.2rc1 (Linux 4.6.7-300.fc24.x86_64; x86_64) IPP/2.0\r\nExpect: 100-continue\r\n\r\n", 185, 0, NULL, 0) = -1 ECONNREFUSED (Connection refused)
01:07:05.501335 sendto(22, "POST / HTTP/1.1\r\nContent-Length: 722\r\nContent-Type: application/ipp\r\nHost: localhost:631\r\nUser-Agent: CUPS/2.2rc1 (Linux 4.6.7-300.fc24.x86_64; x86_64) IPP/2.0\r\nExpect: 100-continue\r\n\r\n", 185, 0, NULL, 0) = -1 EPIPE (Broken pipe)
01:07:05.501385 --- SIGPIPE {si_signo=SIGPIPE, si_code=SI_USER, si_pid=5093, si_uid=1002} ---
01:07:05.501410 sendto(22, "POST / HTTP/1.1\r\nContent-Length: 722\r\nContent-Type: application/ipp\r\nHost: localhost:631\r\nUser-Agent: CUPS/2.2rc1 (Linux 4.6.7-300.fc24.x86_64; x86_64) IPP/2.0\r\nExpect: 100-continue\r\n\r\n", 185, 0, NULL, 0) = -1 EPIPE (Broken pipe)
01:07:05.501460 --- SIGPIPE {si_signo=SIGPIPE, si_code=SI_USER, si_pid=5093, si_uid=1002} ---
01:07:05.501483 close(22)               = 0
01:07:05.501527 socket(AF_INET6, SOCK_STREAM, IPPROTO_IP) = 22
01:07:05.501578 setsockopt(22, SOL_SOCKET, SO_REUSEADDR, [1], 4) = 0
01:07:05.501650 setsockopt(22, SOL_SOCKET, SO_REUSEPORT, [1], 4) = 0
01:07:05.501696 setsockopt(22, SOL_TCP, TCP_NODELAY, [1], 4) = 0
01:07:05.501741 fcntl(22, F_SETFD, FD_CLOEXEC) = 0
01:07:05.501782 fcntl(22, F_GETFL)      = 0x2 (flags O_RDWR)
01:07:05.501825 fcntl(22, F_SETFL, O_RDWR|O_NONBLOCK) = 0
01:07:05.501868 connect(22, {sa_family=AF_INET6, sin6_port=htons(631), inet_pton(AF_INET6, "::1", &sin6_addr), sin6_flowinfo=htonl(0), sin6_scope_id=0}, 28) = -1 EINPROGRESS (Operation now in progress)
01:07:05.501953 fcntl(22, F_SETFL, O_RDWR) = 0
01:07:05.501993 poll([{fd=22, events=POLLIN|POLLOUT}], 1, 100) = 1 ([{fd=22, revents=POLLIN|POLLOUT|POLLERR|POLLHUP}])
01:07:05.502046 sendto(22, "POST / HTTP/1.1\r\nContent-Length: 722\r\nContent-Type: application/ipp\r\nHost: localhost:631\r\nUser-Agent: CUPS/2.2rc1 (Linux 4.6.7-300.fc24.x86_64; x86_64) IPP/2.0\r\nExpect: 100-continue\r\n\r\n", 185, 0, NULL, 0) = -1 ECONNREFUSED (Connection refused)
01:07:05.502099 sendto(22, "POST / HTTP/1.1\r\nContent-Length: 722\r\nContent-Type: application/ipp\r\nHost: localhost:631\r\nUser-Agent: CUPS/2.2rc1 (Linux 4.6.7-300.fc24.x86_64; x86_64) IPP/2.0\r\nExpect: 100-continue\r\n\r\n", 185, 0, NULL, 0) = -1 EPIPE (Broken pipe)
01:07:05.502149 --- SIGPIPE {si_signo=SIGPIPE, si_code=SI_USER, si_pid=5093, si_uid=1002} ---
01:07:05.502173 sendto(22, "POST / HTTP/1.1\r\nContent-Length: 722\r\nContent-Type: application/ipp\r\nHost: localhost:631\r\nUser-Agent: CUPS/2.2rc1 (Linux 4.6.7-300.fc24.x86_64; x86_64) IPP/2.0\r\nExpect: 100-continue\r\n\r\n", 185, 0, NULL, 0) = -1 EPIPE (Broken pipe)
01:07:05.502221 --- SIGPIPE {si_signo=SIGPIPE, si_code=SI_USER, si_pid=5093, si_uid=1002} ---
01:07:05.502244 close(22)               = 0
01:07:05.502287 socket(AF_INET6, SOCK_STREAM, IPPROTO_IP) = 22
01:07:05.502338 setsockopt(22, SOL_SOCKET, SO_REUSEADDR, [1], 4) = 0
01:07:05.502384 setsockopt(22, SOL_SOCKET, SO_REUSEPORT, [1], 4) = 0
01:07:05.502428 setsockopt(22, SOL_TCP, TCP_NODELAY, [1], 4) = 0
01:07:05.502472 fcntl(22, F_SETFD, FD_CLOEXEC) = 0
01:07:05.502514 fcntl(22, F_GETFL)      = 0x2 (flags O_RDWR)
01:07:05.502557 fcntl(22, F_SETFL, O_RDWR|O_NONBLOCK) = 0
01:07:05.502599 connect(22, {sa_family=AF_INET6, sin6_port=htons(631), inet_pton(AF_INET6, "::1", &sin6_addr), sin6_flowinfo=htonl(0), sin6_scope_id=0}, 28) = -1 EINPROGRESS (Operation now in progress)
01:07:05.502697 fcntl(22, F_SETFL, O_RDWR) = 0
01:07:05.502733 poll([{fd=22, events=POLLIN|POLLOUT}], 1, 100) = 1 ([{fd=22, revents=POLLIN|POLLOUT|POLLERR|POLLHUP}])
01:07:05.502783 sendto(22, "POST / HTTP/1.1\r\nContent-Length: 722\r\nContent-Type: application/ipp\r\nHost: localhost:631\r\nUser-Agent: CUPS/2.2rc1 (Linux 4.6.7-300.fc24.x86_64; x86_64) IPP/2.0\r\nExpect: 100-continue\r\n\r\n", 185, 0, NULL, 0) = -1 ECONNREFUSED (Connection refused)
01:07:05.502834 sendto(22, "POST / HTTP/1.1\r\nContent-Length: 722\r\nContent-Type: application/ipp\r\nHost: localhost:631\r\nUser-Agent: CUPS/2.2rc1 (Linux 4.6.7-300.fc24.x86_64; x86_64) IPP/2.0\r\nExpect: 100-continue\r\n\r\n", 185, 0, NULL, 0) = -1 EPIPE (Broken pipe)
01:07:05.503469 --- SIGPIPE {si_signo=SIGPIPE, si_code=SI_USER, si_pid=5093, si_uid=1002} ---
01:07:05.503503 sendto(22, "POST / HTTP/1.1\r\nContent-Length: 722\r\nContent-Type: application/ipp\r\nHost: localhost:631\r\nUser-Agent: CUPS/2.2rc1 (Linux 4.6.7-300.fc24.x86_64; x86_64) IPP/2.0\r\nExpect: 100-continue\r\n\r\n", 185, 0, NULL, 0) = -1 EPIPE (Broken pipe)
01:07:05.503556 --- SIGPIPE {si_signo=SIGPIPE, si_code=SI_USER, si_pid=5093, si_uid=1002} ---
01:07:05.503581 close(22)               = 0
...

$ telnet localhost 631
Trying ::1%1...
telnet: connect to address ::1%1: Connection refused
Trying 127.0.0.1...
telnet: connect to address 127.0.0.1: Connection refused

Version-Release number of selected component (if applicable):
gnome-settings-daemon-3.20.1-3.fc25.x86_64

Additional info:
systemctl start cups.service resolves the issue.

Comment 1 Marek Kašík 2016-09-01 10:38:42 UTC

*** This bug has been marked as a duplicate of bug 1366775 ***


Note You need to log in before you can comment on or make changes to this bug.