After update to CentOS-6.5 Xserver freezes

General support questions
User avatar
GabyB
Posts: 7
Joined: 2013/12/04 15:39:24

After update to CentOS-6.5 Xserver freezes

Post by GabyB » 2013/12/04 15:58:36

Since I've updated to CentOS 6.5 my Xorg server gets very often frozen on moving the mouse.
The rest of the system still works. Killing the Xorg server from a remote session does not help,
the window stays frozen, I have to reboot.

First time I thought the NVIDIA driver is not compatible and uninstalled it and switched back
to the default nouveau driver but the result is the same: X server still freezes.

alibarber
Posts: 3
Joined: 2013/03/18 17:16:30
Contact:

Re: After update to CentOS-6.5 Xserver freezes

Post by alibarber » 2013/12/05 13:04:23

I have been experiencing exactly this issue. Does your machine have a hybrid graphics card? (Nvidia Optimus?)
Currently looking into downgrading Xorg. Will update if I find out anything more...

User avatar
GabyB
Posts: 7
Joined: 2013/12/04 15:39:24

Re: After update to CentOS-6.5 Xserver freezes

Post by GabyB » 2013/12/05 13:31:39

No my card is a NVIDIA Corporation G96GL [Quadro FX 380] (rev a1)

In the meantime I found the command howto downgrade:
yum --disablerepo=\* --enablerepo=C6.4\* downgrade xorg\*

and the system is not frozen since! (2 hours)

Yesterday I have also created a crash dump of the X11 server by 'killall -6 Xorg'
if that info is useful for anyone I cat attach the tar file.

Gabriella.

User avatar
GabyB
Posts: 7
Joined: 2013/12/04 15:39:24

Re: After update to CentOS-6.5 Xserver freezes

Post by GabyB » 2013/12/05 14:55:15

My previous post was too early!
Some minutes later the system freezes again :(

bonok
Posts: 4
Joined: 2013/12/07 12:57:45

Re: After update to CentOS-6.5 Xserver freezes

Post by bonok » 2013/12/07 13:36:40

I also had the same problem. After long investigation i understood the problem.

First i use laptop with optimus but i don't use the nvidia card. I alsho thought the suspect is the Xorg but after several freezes i decided to see the backtrace of the freezed Xorg:

Code: Select all

# pstack `pgrep Xorg`
#0  0x00000037b6a0e264 in __lll_lock_wait () from /lib64/libpthread.so.0
#1  0x00000037b6a09523 in _L_lock_892 () from /lib64/libpthread.so.0
#2  0x00000037b6a09407 in pthread_mutex_lock () from /lib64/libpthread.so.0
#3  0x00000037c76ae44c in ?? () from /usr/lib64/nvidia/libGL.so.1
#4  0x00000037c76af520 in ?? () from /usr/lib64/nvidia/libGL.so.1
#5  0x00000037c76af7c8 in ?? () from /usr/lib64/nvidia/libGL.so.1
#6  0x00007f8ada6dee3b in ?? () from /usr/lib64/nvidia/tls/libnvidia-tls.so.331.20
#7  0x00007f8ad84d56a7 in mtdev_fetch_event () from /usr/lib64/libmtdev.so.1
#8  0x00007f8ad84d5745 in mtdev_get () from /usr/lib64/libmtdev.so.1
#9  0x00007f8ad82cf335 in ?? () from /usr/lib64/xorg/modules/input/synaptics_drv.so
#10 0x00007f8ad82ca3ff in ?? () from /usr/lib64/xorg/modules/input/synaptics_drv.so
#11 0x000000000048ba57 in ?? ()
#12 0x00000000004b664b in ?? ()
#13 <signal handler called>
#14 0x00000037b6a09401 in pthread_mutex_lock () from /lib64/libpthread.so.0
#15 0x00000037c76ae44c in ?? () from /usr/lib64/nvidia/libGL.so.1
#16 0x00000037c76af520 in ?? () from /usr/lib64/nvidia/libGL.so.1
#17 0x00000037c76af7c8 in ?? () from /usr/lib64/nvidia/libGL.so.1
#18 0x00007f8ada6dee3b in ?? () from /usr/lib64/nvidia/tls/libnvidia-tls.so.331.20
#19 0x000000000047a0a6 in ?? ()
#20 0x0000000000470654 in ReadRequestFromClient ()
#21 0x0000000000437cc6 in ?? ()
#22 0x000000000047d08a in ?? ()
#23 0x00000037b621ed1d in __libc_start_main () from /lib64/libc.so.6
#24 0x0000000000426189 in _start () 
Something totally strange. The Xorg uses Nvidia libGL library instead the mesa one. This is totally wrong i use my integrated Intel card not the gedicated Nvidia.
So that is the problem. Also you can feel it if you execute glxgears. The performance is totally bad. The next question i why?

Linux linker picks the needed libraries from ld cache i wanted to see what is in it.

Code: Select all

# ldconfig -p | grep GL
        libQtOpenGL.so.4 (libc6,x86-64) => /usr/lib64/libQtOpenGL.so.4
        libGLU.so.1 (libc6,x86-64) => /usr/lib64/libGLU.so.1
        libGLU.so.1 (libc6) => /usr/lib/libGLU.so.1
        libGLEW.so.1.5 (libc6,x86-64) => /usr/lib64/libGLEW.so.1.5
        libGL.so.1 (libc6,x86-64) => /usr/lib64/nvidia/libGL.so.1
        libGL.so.1 (libc6,x86-64) => /usr/lib64/libGL.so.1
        libGL.so.1 (libc6) => /usr/lib/libGL.so.1
        libGL.so (libc6,x86-64) => /usr/lib64/nvidia/libGL.so
        libGL.so (libc6,x86-64) => /usr/lib64/libGL.so
        libGL.so (libc6) => /usr/lib/libGL.so
        libEGL.so.1 (libc6,x86-64) => /usr/lib64/libEGL.so.1

# ldconfig -p | grep vdpau
        libvdpau_trace.so.1 (libc6,x86-64) => /usr/lib64/vdpau/libvdpau_trace.so.1
        libvdpau_trace.so (libc6,x86-64) => /usr/lib64/vdpau/libvdpau_trace.so
        libvdpau_nvidia.so.1 (libc6,x86-64, OS ABI: Linux 2.3.99) => /usr/lib64/vdpau/libvdpau_nvidia.so.1
        libvdpau_nvidia.so (libc6,x86-64, OS ABI: Linux 2.3.99) => /usr/lib64/vdpau/libvdpau_nvidia.so
        libvdpau.so.1 (libc6,x86-64) => /usr/lib64/libvdpau.so.1
        libevdocument.so.1 (libc6,x86-64) => /usr/lib64/libevdocument.so.1
        libdvdread.so.4 (libc6,x86-64) => /usr/lib64/libdvdread.so.4
        libavdevice.so.52 (libc6,x86-64) => /usr/lib64/libavdevice.so.52
Hint: I knew what libraries i search from my /etc/ld.so.conf.d/nvidia.conf from nvidia-x11-drv-331.20-1.el6.elrepo.x86_64.

That is the libGL and libvpdau libraries are before the mesa libGL and libvdpau.
The ldconfig first search in this order (http://www.monperrus.net/martin/notes-o ... es-with-ld):
1) ld.so.conf
2) files in /etc/ld.so.conf.d/* by alphabetical order
3) pre-configured directories.

Because nvidia.conf directories are searched first and then /usr/lib* directories the nvidia libraries are picked first.

The solution/workaround:
Because i don't use so much my nvidia card i commented the directories in the nvidia.conf file

Code: Select all

#/usr/lib64/nvidia
#/usr/lib64/vdpau
#/usr/lib/nvidia
#/usr/lib/vdpau
And then execute ldconfig (as root) to update the cache.

WARNING: After doing this the linker won't know the nvidia libraries, this means you WON'T use your Nvidia card.

The problem is the colision with the libraries. If you have two dedicated cards try to hide the libraries of your card or reorder the priority of the libraries
of both cards.


That is all. Now everything works fine. For me since i now know what is the cause i don't know how this was worked before CentOS 6.5. If there is someone that have two video cards and still use 6.4 lets say what is the configuration there so we can make solution instead workaround.

EDIT: There is a config option in bumblebeed for the nvidia libraries so you can use the optimus feature 'optirun glxgears'. It seems for me the workaround is actually solution, but people without Optimus should be cautious if they do this.

User avatar
GabyB
Posts: 7
Joined: 2013/12/04 15:39:24

Re: After update to CentOS-6.5 Xserver freezes

Post by GabyB » 2013/12/07 20:36:36

I had the freezes even after I uninstalled the nvidia package, but I did not check if all traces of the nvidia installation had gone.
And after two days where I can't do any use full work, I decided to reinstall CentOS-6.4 from scratch ( as I use separate /home
and /opt partitions with my working environment, this was the easier solution for me).
I'm not really happy to at 6.4 from now on. So if anybody finds the reason for the freeze I would be glad.

bonok
Posts: 4
Joined: 2013/12/07 12:57:45

Re: After update to CentOS-6.5 Xserver freezes

Post by bonok » 2013/12/07 20:59:55

Hi GabyB,

If you have time to experiment do this thing:
1. Wait for a freeze. When X freeze everything is working exept you cant use your display and keyboard.
2. Log to your computer though ssh.
3. Execute

Code: Select all

pstack `pgrep Xorg`
and show the output. The pstack command is from gdb package.
4. Execute

Code: Select all

ldconfig -p
and show the output
5. Show your "ModulePath" config option from your xorg.conf file. If you don't have you can build one if you run

Code: Select all

Xorg :9 -configure
as root. I assume that you don't use display number 9. Then show the xorg.conf.new file.

I think there is a colision with the libraries for you. The suspects are:
1. the gl driver for X
2. the libgl library
3. the vpdau library
and every library that comes from the nvidia package.

I think if you show me this information i can help you.

Since you use now 6.4 it is interesting to me to see if there any difference in the configuration(taken from the steps above) between 6.4 and 6.5.

chemal
Posts: 776
Joined: 2013/12/08 19:44:49

Re: After update to CentOS-6.5 Xserver freezes

Post by chemal » 2013/12/08 19:49:08

Try 'yum remove xorg-x11-glamor'. This new module came with 6.5 and does strange things with Nvidia's libGL.

bonok
Posts: 4
Joined: 2013/12/07 12:57:45

Re: After update to CentOS-6.5 Xserver freezes

Post by bonok » 2013/12/08 22:34:12

Now i understand why i did't have problems before the update. I have used the wrong (nvidia)libraries and when this package came the bug came. So the bug is in the libGL nvidia library. It has to written somewhere it's not a CentOS bug and maybe other distributions would expect this. I think the problem is solved.

User avatar
GabyB
Posts: 7
Joined: 2013/12/04 15:39:24

Re: After update to CentOS-6.5 Xserver freezes

Post by GabyB » 2013/12/09 08:57:12

Im not sure about this solution, because my freezes continues after I uninstalled the nvidia package! ( didn't check if the mentioned library was still there)
With my current 6.4 installation my Monitor works perfectly with the nouveau driver an there is no need to reinstall it again.

And with the new installation I updated my BIOS from Version A05 to A18 and there even no need to modify the kernel line
with several acpi flags

Post Reply