Go Back   nV News Forums > Linux Support Forums > NVIDIA Linux

Newegg Daily Deals

Reply
 
Thread Tools
Old 03-08-09, 09:16 AM   #1
Linea
Registered User
 
Join Date: Mar 2009
Posts: 1
Default Segmentation fault as user - nvidia-settings

Hi, whenever I click on the OpenGL/GLX Information button as a normal user, I get a segmentation fault. I've tried compiling and running glxgears/glxinfo - same probs. When I run as root, everything works as it should.

Program received signal SIGSEGV, Segmentation fault.
0xb77b03c8 in memset () from /lib/libc.so.6
(gdb) bt
#0 0xb77b03c8 in memset () from /lib/libc.so.6
#1 0xb5ca3346 in ?? () from /usr/lib/libGLcore.so.1

Thanks
Attached Files
File Type: log nvidia-bug-report.log (120.6 KB, 101 views)
Linea is offline   Reply With Quote
Old 03-08-09, 09:50 AM   #2
kernelOfTruth
Gentoo Linux addict
 
Join Date: Nov 2007
Location: Vienna, Austria; Germany; hello world :)
Posts: 202
Default Re: Segmentation fault as user - nvidia-settings

I get something similar

~amd64, gcc-4.3.3, glibc-2.9
GNU/Gentoo

running 2.6.29-rc7-zen2 (2.6.29-rc7 with some additional filesystem + driver patches)

180.35 and 180.37 produce this kind of behavior whenever I'm trying to run accelerated / opengl apps or try to launch gdm

when manually going into X from the root account (via startx), e.g. googleearth works fine

this doesn't seem to happen with 180.29 (works fine here),

I suspect a kind of incompatible kernel-configuration since there are users having no problems with that kernel
__________________
2.6.30-rc3-zen0+ w. compcache, reiser4 + ccreg40 (lzo-compression + checksumming)
gcc version 4.4.0-pre9999 built 20090425 (prerelease) rev. 146764 (Gentoo SVN)
gcc version 4.4.0 (Gentoo Hardened 4.4.0-r1, espf-0.2.1)
Ubuntu Jaunty/9.04 x86_64 Dell XPS M1330
kernelOfTruth is offline   Reply With Quote
Old 03-19-09, 02:41 AM   #3
alan242
Registered User
 
Join Date: Sep 2006
Posts: 20
Default Re: Segmentation fault as user - nvidia-settings

Unfortunately, 180.29 doesn't work for me. I haven't tried any later drivers yet.

I'm running F10, glibc-2.9-3.x86_64, gcc 4.3.2-7. F10 32 bit is ok on the same hardware.

Interesting thing, it works as root or su'ed to root.

As a normal user, it always segfaults for me in the same place in gettimeofday in glibc. Googling on that shows some various hits for this problem over the last couple of years. AFAICT, there's not a end all to fix it. It seems to point to a bad pointer being passed and possibly compounded with a call to gettimeofday in a C++ initializer that's being called before main() inits the C library. But since we don't have the code to the GL library, that's all conjecture at this point...

Anyhow, if anyone from Nvidia is still reading at this point. Here's a full backtrace with the glibc debuginfo installed.

Code:
[alan@tarrant Desktop]$ gdb glxinfo

GNU gdb Fedora (6.8-29.fc10)
Copyright (C) 2008 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-redhat-linux-gnu"...
(no debugging symbols found)
Missing separate debuginfos, use: debuginfo-install glx-utils-7.2-0.13.fc10.x86_64
(gdb) r

Starting program: /usr/bin/glxinfo 

Program received signal SIGSEGV, Segmentation fault.
gettimeofday () at ../sysdeps/unix/sysv/linux/x86_64/gettimeofday.S:37
37		callq	*%rax
Current language:  auto; currently asm

(gdb) bt full
#0  gettimeofday () at ../sysdeps/unix/sysv/linux/x86_64/gettimeofday.S:37
No locals.
#1  0x000015555519dfae in _nv000169gl () from /usr/lib64/libGL.so.1
No symbol table info available.
#2  0x0000155553d67a03 in _nv000199gl () from /usr/lib64/libGLcore.so.1
No symbol table info available.
#3  0x00001555551cd92c in _init () from /usr/lib64/libGL.so.1
No symbol table info available.
#4  0x0000155555343af0 in call_init () at dl-init.c:70
	init_array = <value optimized out>
#5  _dl_init (main_map=0x155555552000, argc=1, argv=0x7fffffffe528, env=0x7fffffffe538)
    at dl-init.c:134
	preinit_array = <value optimized out>
	preinit_array_size = (Elf64_Dyn *) 0x155553346d68
	i = <value optimized out>
#6  0x0000155555335b2a in _dl_start_user () from /lib64/ld-linux-x86-64.so.2
No symbol table info available.
#7  0x0000000000000001 in ?? ()
No symbol table info available.
#8  0x00007fffffffe770 in ?? ()
No symbol table info available.
#9  0x0000000000000000 in ?? ()
No symbol table info available.

(gdb) info registers 
rax            0x9b4e64e4dd84b1c7	-7255751015515508281
rbx            0x605880	6314112
rcx            0x155554832aa0	23456234285728
rdx            0x605880	6314112
rsi            0x0	0
rdi            0x7fffffffe440	140737488348224
rbp            0x371f	0x371f
rsp            0x7fffffffe430	0x7fffffffe430
r8             0x68	104
r9             0x101010101010101	72340172838076673
r10            0x7fffffffe220	140737488347680
r11            0x155553d67960	23456222968160
r12            0x15555531e360	23456245736288
r13            0x29a	666
r14            0x7fffffffe538	140737488348472
r15            0x15555531eaa0	23456245738144
rip            0x155554be3e18	0x155554be3e18 <gettimeofday+24>
eflags         0x10282	[ SF IF RF ]
cs             0x33	51
ss             0x2b	43
ds             0x0	0
es             0x0	0
fs             0x63	99
gs             0x0	0
fctrl          0x37f	895
fstat          0x0	0
ftag           0xffff	65535
fiseg          0x0	0
fioff          0x0	0
foseg          0x0	0
fooff          0x0	0
fop            0x0	0
mxcsr          0x1fa0	[ PE IM DM ZM OM UM PM ]
(gdb) quit
The program is running.  Exit anyway? (y or n) y
And yes, the GL libs appear to be pointing the to right ones.

ls -l /usr/lib64/libGLcore.so.1
lrwxrwxrwx 1 root root 19 2009-03-18 13:11 /usr/lib64/libGLcore.so.1 -> libGLcore.so.180.29

ls -l /usr/lib64/libGL.so.1
lrwxrwxrwx 1 root root 15 2009-03-18 13:11 /usr/lib64/libGL.so.1 -> libGL.so.180.29

I'd be happy to do anymore debugging if you need it Nvidia.

Thanks.
alan242 is offline   Reply With Quote
Old 03-20-09, 03:12 AM   #4
alan242
Registered User
 
Join Date: Sep 2006
Posts: 20
Default Re: Segmentation fault as user - nvidia-settings

To follow myself up... I upgraded to the beta 185.13 driver and still had the segfault. In researching it more, it turns out this

Quote:
Originally Posted by alan242 View Post
Interesting thing, it works as root or su'ed to root.
it the key to my problem. Googling around I came across this page:
http://www.linuxquestions.org/questi...-solved-589149
This person noted his segfault problem was due to permissions not being set correctly.
Doing a ldd `which glxinfo` as me and as root showed a interesting but significant difference.

As a user I get these libraries:
[alan@tarrant Desktop]$ ldd `which glxinfo`
linux-vdso.so.1 => (0x00007fff63fff000)
libGL.so.1 => /usr/lib64/libGL.so.1 (0x00001477b9178000)
libm.so.6 => /lib64/libm.so.6 (0x00000037e0a00000)
libc.so.6 => /lib64/libc.so.6 (0x00000037e0600000)
libX11.so.6 => /usr/lib64/libX11.so.6 (0x00001477b8e6c000)
libGLcore.so.1 => /usr/lib64/libGLcore.so.1 (0x00001477b7b76000)
libnvidia-tls.so.1 => /usr/lib64/libnvidia-tls.so.1 (0x00001477b7a74000)
libXext.so.6 => /usr/lib64/libXext.so.6 (0x00001477b7863000)
libdl.so.2 => /lib64/libdl.so.2 (0x00000037e0e00000)
/lib64/ld-linux-x86-64.so.2 (0x00000037e0000000)
libxcb-xlib.so.0 => /usr/lib64/libxcb-xlib.so.0 (0x00001477b7661000)
libxcb.so.1 => /usr/lib64/libxcb.so.1 (0x00001477b7446000)
libXau.so.6 => /usr/lib64/libXau.so.6 (0x00001477b7243000)
libXdmcp.so.6 => /usr/lib64/libXdmcp.so.6 (0x00001477b703e000)

As root I get:
[root@tarrant ~]# ldd `which glxinfo`
linux-vdso.so.1 => (0x00007fffd2bfe000)
libGL.so.1 => /usr/lib64/libGL.so.1 (0x0000153427de6000)
libm.so.6 => /lib64/libm.so.6 (0x00000037e0a00000)
libc.so.6 => /lib64/libc.so.6 (0x00000037e0600000)
libX11.so.6 => /usr/lib64/libX11.so.6 (0x0000153427ada000)
libGLcore.so.1 => /usr/lib64/libGLcore.so.1 (0x00001534267e5000)
libnvidia-tls.so.1 => /usr/lib64/tls/libnvidia-tls.so.1 (0x00001534266e2000)
libXext.so.6 => /usr/lib64/libXext.so.6 (0x00001534264d1000)
libdl.so.2 => /lib64/libdl.so.2 (0x00000037e0e00000)
/lib64/ld-linux-x86-64.so.2 (0x00000037e0000000)
libxcb-xlib.so.0 => /usr/lib64/libxcb-xlib.so.0 (0x00001534262cf000)
libxcb.so.1 => /usr/lib64/libxcb.so.1 (0x00001534260b4000)
libXau.so.6 => /usr/lib64/libXau.so.6 (0x0000153425eb2000)
libXdmcp.so.6 => /usr/lib64/libXdmcp.so.6 (0x0000153425cac000)

The different library is libnvidia-tls.so.1. As a user, it's getting loaded from /usr/lib64. As root, it's getting loaded from /usr/lib64/tls. It turns out that the permissions on /usr/lib64/tls is set to rwx------. And the lib in /usr/lib64 is not the same as the one in /usr/lib64/tls. By changing the tls directory permissions to rwxr-xr-x made the glxinfo and 3D programs work again.

I'm not sure why Fedora is restricting permissions to this directory. They may be trying to phase out the directory. /lib64/tls is also restricted to rwx------. I'm not sure whom to ask about that.

I also wonder why /usr/lib64/libnvidia-tls.so.1 is different than the /usr/lib64/tls version. It looks like there's about a 200 byte difference between the two. Anyone from Nvidia care to shed some light on this??? Maybe the version in /usr/lib64/tls should be in /usr/lib64???
alan242 is offline   Reply With Quote
Old 03-20-09, 06:10 AM   #5
kernelOfTruth
Gentoo Linux addict
 
Join Date: Nov 2007
Location: Vienna, Austria; Germany; hello world :)
Posts: 202
Default Re: Segmentation fault as user - nvidia-settings

interesting find

I'll have a look if my problem could also be related to a permissions thing

thanks
__________________
2.6.30-rc3-zen0+ w. compcache, reiser4 + ccreg40 (lzo-compression + checksumming)
gcc version 4.4.0-pre9999 built 20090425 (prerelease) rev. 146764 (Gentoo SVN)
gcc version 4.4.0 (Gentoo Hardened 4.4.0-r1, espf-0.2.1)
Ubuntu Jaunty/9.04 x86_64 Dell XPS M1330
kernelOfTruth is offline   Reply With Quote
Old 03-20-09, 10:57 AM   #6
kernelOfTruth
Gentoo Linux addict
 
Join Date: Nov 2007
Location: Vienna, Austria; Germany; hello world :)
Posts: 202
Default Re: Segmentation fault as user - nvidia-settings

and for me it was NOT due to faulty permissions, all permissions are correct so my problem is not the same

glad for you, alan242, that it was only a permissions issue

for me it has to be something deeper ...
__________________
2.6.30-rc3-zen0+ w. compcache, reiser4 + ccreg40 (lzo-compression + checksumming)
gcc version 4.4.0-pre9999 built 20090425 (prerelease) rev. 146764 (Gentoo SVN)
gcc version 4.4.0 (Gentoo Hardened 4.4.0-r1, espf-0.2.1)
Ubuntu Jaunty/9.04 x86_64 Dell XPS M1330
kernelOfTruth is offline   Reply With Quote
Reply


Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


Similar Threads
Thread Thread Starter Forum Replies Last Post
Need Help Installing NVIDIA Tesla M2070Q in Linux RHEL5 Ferianto85 NVIDIA Linux 0 05-18-12 08:35 PM
Former Nvidia user: 9700 impressions nin_fragile14 Other Desktop Graphics Cards 58 11-01-02 01:38 PM
Segmentation Fault on RH 7.3 Lawrence DeLeon NVIDIA Linux 4 09-16-02 11:42 AM

All times are GMT -5. The time now is 12:12 AM.


Powered by vBulletin® Version 3.7.1
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Copyright 1998 - 2014, nV News.