<div dir="ltr">According to strace -p, xorg is spinning on a select(), which always return the same fd #6, which seems related to the system dbus:<div><br></div><div><br></div><div><div>$ pgrep Xorg</div><div>614</div></div><div>$ strace -p 614</div><div><div>Process 614 attached</div><div>select(256, [1 3 5 6 8 10 19 23 25 29 36 37 38 39 40 41], NULL, NULL, {214, 537000}) = 1 (in [6], left {214, 536993})</div><div>select(256, [1 3 5 6 8 10 19 23 25 29 36 37 38 39 40 41], NULL, NULL, {214, 537000}) = 1 (in [6], left {214, 536995})</div><div>select(256, [1 3 5 6 8 10 19 23 25 29 36 37 38 39 40 41], NULL, NULL, {214, 537000}) = 1 (in [6], left {214, 536995})</div><div>select(256, [1 3 5 6 8 10 19 23 25 29 36 37 38 39 40 41], NULL, NULL, {214, 537000}) = 1 (in [6], left {214, 536995})</div><div>select(256, [1 3 5 6 8 10 19 23 25 29 36 37 38 39 40 41], NULL, NULL, {214, 537000}) = 1 (in [6], left {214, 536996})</div><div>select(256, [1 3 5 6 8 10 19 23 25 29 36 37 38 39 40 41], NULL, NULL, {214, 536000}) = 1 (in [6], left {214, 535996})</div><div>select(256, [1 3 5 6 8 10 19 23 25 29 36 37 38 39 40 41], NULL, NULL, {214, 536000}) = 1 (in [6], left {214, 535996})</div></div><div>^C</div><div>$ gdb -p 614</div><div>GNU gdb (GDB) 7.10</div><div>Copyright (C) 2015 Free Software Foundation, Inc.</div><div>License GPLv3+: GNU GPL version 3 or later <<a href="http://gnu.org/licenses/gpl.html">http://gnu.org/licenses/gpl.html</a>></div><div>This is free software: you are free to change and redistribute it.</div><div>There is NO WARRANTY, to the extent permitted by law. Type "show copying"</div><div>and "show warranty" for details.</div><div>This GDB was configured as "x86_64-unknown-linux-gnu".</div><div>Type "show configuration" for configuration details.</div><div>For bug reporting instructions, please see:</div><div><<a href="http://www.gnu.org/software/gdb/bugs/">http://www.gnu.org/software/gdb/bugs/</a>>.</div><div>Find the GDB manual and other documentation resources online at:</div><div><<a href="http://www.gnu.org/software/gdb/documentation/">http://www.gnu.org/software/gdb/documentation/</a>>.</div><div>For help, type "help".</div><div>Type "apropos word" to search for commands related to "word".</div><div>Attaching to process 614</div><div>Reading symbols from /usr/lib/xorg-server/Xorg...(no debugging symbols found)...done.</div><div>Reading symbols from /usr/lib/libdbus-1.so.3...(no debugging symbols found)...done.</div><div>Reading symbols from /usr/lib/libudev.so.1...(no debugging symbols found)...done.</div><div>Reading symbols from /usr/lib/libgcrypt.so.20...(no debugging symbols found)...done.</div><div>Reading symbols from /usr/lib/libdl.so.2...(no debugging symbols found)...done.</div><div>Reading symbols from /usr/lib/libunwind.so.8...(no debugging symbols found)...done.</div><div>Reading symbols from /usr/lib/libpciaccess.so.0...(no debugging symbols found)...done.</div><div>Reading symbols from /usr/lib/libdrm.so.2...(no debugging symbols found)...done.</div><div>Reading symbols from /usr/lib/libpixman-1.so.0...(no debugging symbols found)...done.</div><div>Reading symbols from /usr/lib/libXfont.so.1...(no debugging symbols found)...done.</div><div>Reading symbols from /usr/lib/libXau.so.6...(no debugging symbols found)...done.</div><div>Reading symbols from /usr/lib/libsystemd.so.0...(no debugging symbols found)...done.</div><div>Reading symbols from /usr/lib/libxshmfence.so.1...(no debugging symbols found)...done.</div><div>Reading symbols from /usr/lib/libXdmcp.so.6...(no debugging symbols found)...done.</div><div>Reading symbols from /usr/lib/libm.so.6...(no debugging symbols found)...done.</div><div>Reading symbols from /usr/lib/libc.so.6...(no debugging symbols found)...done.</div><div>Reading symbols from /usr/lib/libpthread.so.0...(no debugging symbols found)...done.</div><div>[New LWP 980]</div><div>[Thread debugging using libthread_db enabled]</div><div>Using host libthread_db library "/usr/lib/libthread_db.so.1".</div><div>Reading symbols from /usr/lib/librt.so.1...(no debugging symbols found)...done.</div><div>Reading symbols from /usr/lib/libresolv.so.2...(no debugging symbols found)...done.</div><div>Reading symbols from /usr/lib/libcap.so.2...(no debugging symbols found)...done.</div><div>Reading symbols from /lib64/ld-linux-x86-64.so.2...(no debugging symbols found)...done.</div><div>Reading symbols from /usr/lib/libgpg-error.so.0...(no debugging symbols found)...done.</div><div>Reading symbols from /usr/lib/liblzma.so.5...(no debugging symbols found)...done.</div><div>Reading symbols from /usr/lib/libfreetype.so.6...(no debugging symbols found)...done.</div><div>Reading symbols from /usr/lib/libz.so.1...(no debugging symbols found)...done.</div><div>Reading symbols from /usr/lib/libfontenc.so.1...(no debugging symbols found)...done.</div><div>Reading symbols from /usr/lib/liblz4.so.1...(no debugging symbols found)...done.</div><div>Reading symbols from /usr/lib/libattr.so.1...(no debugging symbols found)...done.</div><div>Reading symbols from /usr/lib/libbz2.so.1.0...(no debugging symbols found)...done.</div><div>Reading symbols from /usr/lib/libpng16.so.16...(no debugging symbols found)...done.</div><div>Reading symbols from /usr/lib/libharfbuzz.so.0...(no debugging symbols found)...done.</div><div>Reading symbols from /usr/lib/libglib-2.0.so.0...(no debugging symbols found)...done.</div><div>Reading symbols from /usr/lib/libgraphite2.so.3...(no debugging symbols found)...done.</div><div>Reading symbols from /usr/lib/libpcre.so.1...(no debugging symbols found)...done.</div><div>Reading symbols from /usr/lib/xorg/modules/extensions/libglx.so...(no debugging symbols found)...done.</div><div>Reading symbols from /usr/lib/libGL.so.1...(no debugging symbols found)...done.</div><div>Reading symbols from /usr/lib/libexpat.so.1...(no debugging symbols found)...done.</div><div>Reading symbols from /usr/lib/libglapi.so.0...(no debugging symbols found)...done.</div><div>Reading symbols from /usr/lib/libXext.so.6...(no debugging symbols found)...done.</div><div>Reading symbols from /usr/lib/libXdamage.so.1...(no debugging symbols found)...done.</div><div>Reading symbols from /usr/lib/libXfixes.so.3...(no debugging symbols found)...done.</div><div>Reading symbols from /usr/lib/libX11-xcb.so.1...(no debugging symbols found)...done.</div><div>Reading symbols from /usr/lib/libX11.so.6...(no debugging symbols found)...done.</div><div>Reading symbols from /usr/lib/libxcb-glx.so.0...(no debugging symbols found)...done.</div><div>Reading symbols from /usr/lib/libxcb-dri2.so.0...(no debugging symbols found)...done.</div><div>Reading symbols from /usr/lib/libxcb-dri3.so.0...(no debugging symbols found)...done.</div><div>Reading symbols from /usr/lib/libxcb-present.so.0...(no debugging symbols found)...done.</div><div>Reading symbols from /usr/lib/libxcb-randr.so.0...(no debugging symbols found)...done.</div><div>Reading symbols from /usr/lib/libxcb-xfixes.so.0...(no debugging symbols found)...done.</div><div>Reading symbols from /usr/lib/libxcb-render.so.0...(no debugging symbols found)...done.</div><div>Reading symbols from /usr/lib/libxcb-shape.so.0...(no debugging symbols found)...done.</div><div>Reading symbols from /usr/lib/libxcb-sync.so.1...(no debugging symbols found)...done.</div><div>Reading symbols from /usr/lib/libxcb.so.1...(no debugging symbols found)...done.</div><div>Reading symbols from /usr/lib/libXxf86vm.so.1...(no debugging symbols found)...done.</div><div>Reading symbols from /usr/lib/xorg/modules/drivers/intel_drv.so...(no debugging symbols found)...done.</div><div>Reading symbols from /usr/lib/libdrm_intel.so.1...(no debugging symbols found)...done.</div><div>Reading symbols from /usr/lib/libstdc++.so.6...done.</div><div>Reading symbols from /usr/lib/libgcc_s.so.1...done.</div><div>Reading symbols from /usr/lib/xorg/modules/input/evdev_drv.so...(no debugging symbols found)...done.</div><div>Reading symbols from /usr/lib/libmtdev.so.1...(no debugging symbols found)...done.</div><div>Reading symbols from /usr/lib/libevdev.so.2...(no debugging symbols found)...done.</div><div>Reading symbols from /usr/lib/xorg/modules/input/synaptics_drv.so...(no debugging symbols found)...done.</div><div>Reading symbols from /usr/lib/xorg/modules/dri/i965_dri.so...(no debugging symbols found)...done.</div><div>Reading symbols from /usr/lib/libdrm_nouveau.so.2...(no debugging symbols found)...done.</div><div>Reading symbols from /usr/lib/libdrm_radeon.so.1...(no debugging symbols found)...done.</div><div>0x00007f47ceec8e23 in select () from /usr/lib/libc.so.6</div><div>(gdb) bt</div><div>#0 0x00007f47ceec8e23 in select () from /usr/lib/libc.so.6</div><div>#1 0x000000000058f537 in WaitForSomething ()</div><div>#2 0x0000000000438be1 in ?? ()</div><div>#3 0x000000000043cf0b in ?? ()</div><div>#4 0x00007f47cee07610 in __libc_start_main () from /usr/lib/libc.so.6</div><div>#5 0x0000000000427319 in _start ()</div><div>(gdb) quit</div><div>A debugging session is active.</div><div><br></div><div><span class="Apple-tab-span" style="white-space:pre"> </span>Inferior 1 [process 614] will be detached.</div><div><br></div><div>Quit anyway? (y or n) Y</div><div>Detaching from program: /usr/lib/xorg-server/Xorg, process 614</div><div>$ ls -l /proc/614/fd/6</div><div>lrwx------ 1 jin users 64 9月 23 14:23 /proc/614/fd/6 -> socket:[15637]</div><div>$ lsof +E -p 614 | grep 15637</div><div>dbus-daem 449 dbus 16u unix 0xffff8800d8c4e300 0t0 14185 /run/dbus/system_bus_socket type=STREAM ->INO=15637 614,Xorg,6u</div><div>Xorg 614 jin 6u unix 0xffff8800d8c4e680 0t0 15637 type=STREAM ->INO=14185 449,dbus-daem,16u</div><div><br></div><div><br></div><div>BTW, I run xorg from a user session, not the usual root.</div><div>My software versions:</div><div> systemd / libsystemd 226</div><div> dbus / libdbus 1.10.0-3</div><div> xorg-server 1.17.2-4</div></div><br><div class="gmail_quote"><div dir="ltr">On Wed, Sep 23, 2015 at 7:25 AM David Herrmann <<a href="mailto:dh.herrmann@gmail.com">dh.herrmann@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi<br>
<br>
On Tue, Sep 22, 2015 at 9:23 PM, Jin Liu <<a href="mailto:m.liu.jin@gmail.com" target="_blank">m.liu.jin@gmail.com</a>> wrote:<br>
> After upgrading to 226, the Xorg process keeps using 100% CPU. Also, the<br>
> "xrandr --dpi 168" command in my .xinitrc no longer works.<br>
><br>
> My startx.service and .xinitrc:<br>
><br>
> $ systemctl cat startx.service<br>
> # /etc/systemd/system/startx.service<br>
> [Unit]<br>
> Description=Direct X login<br>
> After=systemd-user-sessions.service<br>
> Conflicts=getty@tty1.service<br>
><br>
> [Service]<br>
> User=jin<br>
> TTYPath=/dev/tty1<br>
> PAMName=login<br>
> Environment=DISPLAY=:0<br>
> ExecStart=/usr/bin/bash --login -c "cd; (/usr/lib/xorg-server/Xorg -nolisten<br>
> tcp vt1 &); source .xinitrc"<br>
><br>
> [Install]<br>
> WantedBy=graphical.target<br>
> $ cat .xinitrc<br>
> #!/bin/sh<br>
> #<br>
> # ~/.xinitrc<br>
> #<br>
> # Executed by startx (run your window manager from here)<br>
><br>
> export DESKTOP_SESSION="plasma"<br>
><br>
> if [ -d /etc/X11/xinit/xinitrc.d ]; then<br>
> for f in /etc/X11/xinit/xinitrc.d/*; do<br>
> [ -x "$f" ] && . "$f"<br>
> done<br>
> unset f<br>
> fi<br>
><br>
> xrandr --dpi 168<br>
><br>
> exec /usr/bin/startkde<br>
><br>
> $<br>
><br>
> BTW, if I move the "xrandr --dpi 168" line into /usr/bin/startkde, it works<br>
> again (only DPI setting. Xorg still uses 100% CPU).<br>
><br>
> What change in version 226 could cause the above problem, and how should I<br>
> change the above files to fix it? Thanks.<br>
<br>
Please run "strace -p <pid>" on the offending process or "perf top".<br>
Then try to figure out which function is spinning.<br>
<br>
Thanks<br>
David<br>
</blockquote></div>