Bug 100655 - XOpenDisplay() hanging
Summary: XOpenDisplay() hanging
Status: RESOLVED MOVED
Alias: None
Product: xorg
Classification: Unclassified
Component: Server/General (show other bugs)
Version: unspecified
Hardware: Other All
: medium normal
Assignee: Xorg Project Team
QA Contact: Xorg Project Team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2017-04-11 15:38 UTC by Philipp
Modified: 2018-12-17 17:34 UTC (History)
0 users

See Also:
i915 platform:
i915 features:


Attachments
reproducer g.c (1.05 KB, text/x-csrc)
2017-04-11 15:38 UTC, Philipp
no flags Details
strace of reproducer triggering the delay, see gap between 17:27:44 and 17:28:48 (28.46 KB, text/x-log)
2017-04-11 15:39 UTC, Philipp
no flags Details

Description Philipp 2017-04-11 15:38:17 UTC
Created attachment 130799 [details]
reproducer g.c

When logged into localhost as root via SSH, XOpenDisplay()
blocks for more than 60 s about every other time it is called:

#0  0x00007f48d4209c90 in __connect_nocancel () from /lib64/libc.so.6
#1  0x00007f48d3ee8409 in _xcb_open_tcp () from /lib64/libxcb.so.1
#2  0x00007f48d3ee87a4 in xcb_connect_to_display_with_auth_info () from /lib64/libxcb.so.1
#3  0x00007f48d4507a3a in _XConnectXCB () from /lib64/libX11.so.6
#4  0x00007f48d44f8772 in XOpenDisplay () from /lib64/libX11.so.6
#5  0x00000000004007bf in main () at g.c:19

For reference, I mistakenly filed this as a GTK bug first:
https://bugzilla.gnome.org/show_bug.cgi?id=781182

The system is Fedora 25:

~> uname -a
Linux drift.m.i2n 4.10.8-200.fc25.x86_64 #1 SMP Fri Mar 31 13:20:22 UTC 2017 x86_64 x86_64 x86_64 GNU/Linux                                                                                                     
~> rpm -qi xorg-x11-server-Xorg
Name        : xorg-x11-server-Xorg
Version     : 1.19.3
Release     : 1.fc25
Architecture: x86_64
Install Date: Mon 03 Apr 2017 09:49:02 AM CEST
Group       : User Interface/X
Size        : 3744258
License     : MIT
Signature   : RSA/SHA256, Thu 30 Mar 2017 06:26:25 PM CEST, Key ID 4089d8f2fdb19c98
Source RPM  : xorg-x11-server-1.19.3-1.fc25.src.rpm
Build Date  : Wed 15 Mar 2017 07:39:18 PM CET
Build Host  : buildhw-03.phx2.fedoraproject.org
Relocations : (not relocatable)
Packager    : Fedora Project
Vendor      : Fedora Project
URL         : http://www.x.org
Summary     : Xorg X server
Comment 1 Philipp 2017-04-11 15:39:33 UTC
Created attachment 130800 [details]
strace of reproducer triggering the delay, see gap between 17:27:44 and 17:28:48
Comment 2 Adam Jackson 2018-06-13 19:37:11 UTC
The only things that can really cause XOpenDisplay to block are reloading the XAUTHORITY file and (maybe) doing hostname lookups. It would be informative to strace the _server_ when running this test to see what it's doing, since clearly all the delay is happening there.
Comment 3 GitLab Migration User 2018-12-17 17:34:42 UTC
-- GitLab Migration Automatic Message --

This bug has been migrated to freedesktop.org's GitLab instance and has been closed from further activity.

You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.freedesktop.org/xorg/xserver/issues/619.


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.