Nvclock crash ("*** stack smashing detected ***")

Bug #331750 reported by Anton Kraus
28
This bug affects 4 people
Affects Status Importance Assigned to Milestone
nvclock (Ubuntu)
New
Undecided
Unassigned

Bug Description

Binary package hint: nvclock

I'm running Jaunty with nvclock at version 0.8b3-1ubuntu1.

Whenever I try to use it with a parameter (e.g.: -i, -T or -s), it crashes with the following error message:

*** stack smashing detected ***: nvclock terminated
======= Backtrace: =========
/lib/tls/i686/cmov/libc.so.6(__fortify_fail+0x48)[0xb7eacda8]
/lib/tls/i686/cmov/libc.so.6(__fortify_fail+0x0)[0xb7eacd60]
nvclock[0x805884c]
nvclock[0x8059c0c]
nvclock[0x805a1dd]
nvclock[0x805a044]
nvclock[0x804e020]
nvclock[0x804db09]
nvclock[0x80574ce]
nvclock[0x804a34b]
/lib/tls/i686/cmov/libc.so.6(__libc_start_main+0xe5)[0xb7dc5775]
nvclock[0x80491e1]
======= Memory map: ========
08048000-08062000 r-xp 00000000 08:02 411292 /usr/bin/nvclock
08062000-08063000 rw-p 0001a000 08:02 411292 /usr/bin/nvclock
09220000-09241000 rw-p 09220000 00:00 0 [heap]
b7d18000-b7d25000 r-xp 00000000 08:02 24250 /lib/libgcc_s.so.1
b7d25000-b7d26000 r--p 0000c000 08:02 24250 /lib/libgcc_s.so.1
b7d26000-b7d27000 rw-p 0000d000 08:02 24250 /lib/libgcc_s.so.1
b7d36000-b7d46000 r--s 00000000 08:03 1794367 /home/toe/.nvclock/bios0.rom
b7d46000-b7d56000 rw-s de300000 00:0e 7894 /dev/nvidia0
b7d56000-b7d86000 rw-s de000000 00:0e 7894 /dev/nvidia0
b7d86000-b7d88000 rw-p b7d86000 00:00 0
b7d88000-b7d8c000 r-xp 00000000 08:02 413903 /usr/lib/libXdmcp.so.6.0.0
b7d8c000-b7d8d000 rw-p 00003000 08:02 413903 /usr/lib/libXdmcp.so.6.0.0
b7d8d000-b7d8f000 r-xp 00000000 08:02 25196 /lib/tls/i686/cmov/libdl-2.9.so
b7d8f000-b7d90000 r--p 00001000 08:02 25196 /lib/tls/i686/cmov/libdl-2.9.so
b7d90000-b7d91000 rw-p 00002000 08:02 25196 /lib/tls/i686/cmov/libdl-2.9.so
b7d91000-b7da9000 r-xp 00000000 08:02 413453 /usr/lib/libxcb.so.1.1.0
b7da9000-b7daa000 r--p 00017000 08:02 413453 /usr/lib/libxcb.so.1.1.0
b7daa000-b7dab000 rw-p 00018000 08:02 413453 /usr/lib/libxcb.so.1.1.0
b7dab000-b7dad000 r-xp 00000000 08:02 413515 /usr/lib/libXau.so.6.0.0
b7dad000-b7dae000 r--p 00001000 08:02 413515 /usr/lib/libXau.so.6.0.0
b7dae000-b7daf000 rw-p 00002000 08:02 413515 /usr/lib/libXau.so.6.0.0
b7daf000-b7f0b000 r-xp 00000000 08:02 24889 /lib/tls/i686/cmov/libc-2.9.so
b7f0b000-b7f0c000 ---p 0015c000 08:02 24889 /lib/tls/i686/cmov/libc-2.9.so
b7f0c000-b7f0e000 r--p 0015c000 08:02 24889 /lib/tls/i686/cmov/libc-2.9.so
b7f0e000-b7f0f000 rw-p 0015e000 08:02 24889 /lib/tls/i686/cmov/libc-2.9.so
b7f0f000-b7f13000 rw-p b7f0f000 00:00 0
b7f13000-b7ffd000 r-xp 00000000 08:02 411405 /usr/lib/libX11.so.6.2.0
b7ffd000-b7ffe000 ---p 000ea000 08:02 411405 /usr/lib/libX11.so.6.2.0
b7ffe000-b7fff000 r--p 000ea000 08:02 411405 /usr/lib/libX11.so.6.2.0
b7fff000-b8001000 rw-p 000eb000 08:02 411405 /usr/lib/libX11.so.6.2.0
b8001000-b8002000 rw-p b8001000 00:00 0
b8002000-b800f000 r-xp 00000000 08:02 413570 /usr/lib/libXext.so.6.4.0
b800f000-b8011000 rw-p 0000c000 08:02 413570 /usr/lib/libXext.so.6.4.0
b801a000-b801c000 rw-s de680000 00:0e 7894 /dev/nvidia0
b801c000-b801e000 rw-s de601000 00:0e 7894 /dev/nvidia0
b801e000-b801f000 rw-s de100000 00:0e 7894 /dev/nvidia0
b801f000-b8020000 rw-s de101000 00:0e 7894 /dev/nvidia0
b8020000-b8022000 rw-p b8020000 00:00 0
b8022000-b8023000 r-xp b8022000 00:00 0 [vdso]
b8023000-b803f000 r-xp 00000000 08:02 24349 /lib/ld-2.9.so
b803f000-b8040000 r--p 0001b000 08:02 24349 /lib/ld-2.9.so
b8040000-b8041000 rw-p 0001c000 08:02 24349 /lib/ld-2.9.so
bf92c000-bf941000 rw-p bffeb000 00:00 0 [stack]
Aborted

Running nvclock without a parameter works as expected and brings up the list of possible commands.

My graphics card is a Geforce 6600 LE. Its lspci output:

01:00.0 VGA compatible controller: nVidia Corporation NV43 [GeForce 6600 LE] (rev a2)
 Control: I/O+ Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- SERR- FastB2B- DisINTx-
 Status: Cap+ 66MHz+ UDF- FastB2B+ ParErr- DEVSEL=medium >TAbort- <TAbort- <MAbort- >SERR- <PERR- INTx-
 Latency: 248 (1250ns min, 250ns max)
 Interrupt: pin A routed to IRQ 16
 Region 0: Memory at de000000 (32-bit, non-prefetchable) [size=16M]
 Region 1: Memory at e0000000 (32-bit, prefetchable) [size=256M]
 Region 2: Memory at dd000000 (32-bit, non-prefetchable) [size=16M]
 [virtual] Expansion ROM at dffe0000 [disabled] [size=128K]
 Capabilities: [60] Power Management version 2
  Flags: PMEClk- DSI- D1- D2- AuxCurrent=0mA PME(D0-,D1-,D2-,D3hot-,D3cold-)
  Status: D0 PME-Enable- DSel=0 DScale=0 PME-
 Capabilities: [44] AGP version 3.0
  Status: RQ=32 Iso- ArqSz=0 Cal=0 SBA+ ITACoh- GART64- HTrans- 64bit- FW+ AGP3- Rate=x1,x2,x4
  Command: RQ=32 ArqSz=0 Cal=0 SBA+ AGP+ GART64- 64bit- FW+ Rate=x4
 Kernel driver in use: nvidia
 Kernel modules: nvidia, nvidiafb

Back in Intrepid everything worked fine.

Revision history for this message
Anton Kraus (done) wrote :

I just discovered that bug 72117, which was marked as "Fix released" two years ago seems to be a duplicate of this.

Revision history for this message
Obrouni (nick-fisk) wrote :

I also get this problem:-

Jaunty (2.6.28-8-generic)

Changed in nvclock:
status: New → Confirmed
Revision history for this message
Geoff123 (gsking1) wrote :

Same Problem Here.
This is a critical program for me since I need it to control the nvidia fan speed which does not work for my card (6600 GT).
This has worked fine in last several versions of Ubuntu.

A newer version 0.8b4 from http://www.linuxhardware.org/nvclock/ compiles and works fine. So maybe his can be fixed by getting the new version; there is also a request for that in bug #326365

However, 0.8b3 crashes both from the ubuntu packages and when I compile myself.

Linux version 2.6.28-8-generic

Description: Ubuntu jaunty (development branch)
Release: 9.04

nvclock:
  Installed: 0.8b3-1ubuntu1
  Candidate: 0.8b3-1ubuntu1
  Version table:
 *** 0.8b3-1ubuntu1 0
        500 http://us.archive.ubuntu.com jaunty/universe Packages
        100 /var/lib/dpkg/status

Revision history for this message
Anton Kraus (done) wrote :

The newest nvclock version in the Jaunty repositories (0.8b4-1ubuntu1) fixed this bug for me. :)

Revision history for this message
Steve Langasek (vorlon) wrote :

Thanks, closing the bug per the latest follow-up.

Changed in nvclock:
status: Confirmed → Fix Released
Revision history for this message
Roger Binns (ubuntu-rogerbinns) wrote :

0.8b4-1ubunt2 still crashes on AMD64

Changed in nvclock (Ubuntu):
status: Fix Released → New
Revision history for this message
Roger Binns (ubuntu-rogerbinns) wrote :

On AMD64 (latest Jaunty, all updates applied) it still crashes 0.8b4-1ubuntu2 although it is a little later in running. For example nvclock -i (get info) shows a few things then voltages:

$ nvclock -i
[ nice information elided ]
Voltage level 2: 1.05V, VID: 2
Voltage level 3: 1.10V, VID: 3

*** stack smashing detected ***: nvclock terminated
======= Backtrace: =========
/lib/libc.so.6(__fortify_fail+0x37)[0x3e078ff2c7]
/lib/libc.so.6(__fortify_fail+0x0)[0x3e078ff290]
nvclock[0x4059b3]
/lib/libc.so.6(__libc_start_main+0xe6)[0x3e0781e5a6]
nvclock[0x401889]
======= Memory map: ========
00400000-00421000 r-xp 00000000 08:02 79881523 /usr/bin/nvclock
00620000-00621000 r--p 00020000 08:02 79881523 /usr/bin/nvclock
00621000-00622000 rw-p 00021000 08:02 79881523 /usr/bin/nvclock
00622000-00623000 rw-p 00622000 00:00 0
0063e000-0065f000 rw-p 0063e000 00:00 0 [heap]
.... system shared libraries from this point .....

Other commands seem to work without the crashes, but I won't try most of them since I don't want to possibly damage my hardware.

Revision history for this message
Roger Binns (ubuntu-rogerbinns) wrote :

Debug symbols aren't available so I can't get anything more helpful. gdb doesn't show anything useful except the call to abort. valgrind doesn't complain about anything at all.

Revision history for this message
TSanchess (tsanchess) wrote :

I also get this problem on freshly installed Jaunty with nvclock (0.8b4-1ubuntu2)
2.6.28-11-generic(i686)

Revision history for this message
Martin P (martin-pittamitz) wrote :

I am experiencing the same problem, 2.6.28-11-generic (x86_64), nvclock 0.8b4-1ubuntu2.

Revision history for this message
gnufreex (gnufreex) wrote :

I to have that problem. Jaunty 64-bit, GF 8800GT, newest nvclock version (and only) in Ubuntu repositories. Is there a workaround yet?

Revision history for this message
gnufreex (gnufreex) wrote :

nvclock actually does its job. I only need nvclock to adjust GPU fan rpm, and that part (thanks God) work fine. Command "nvclock -f --fanspeed XX" (where XX is number of %) does not give any error and does its job. But it would be nice if that "stack smacking" issue get fixed...

Revision history for this message
aftertaf (david-wooffindin) wrote :

Would like to open bug again for karmic koala.
0.8 beta4 in shell says cant find /dev/nvidia0, and both _qt and _gtk version core dump/seg fault.

this is since update to karmic, using -185 nvidia drivers from repositories.

lspci:
01:00.0 VGA compatible controller: nVidia Corporation NV40 [GeForce 6800] (rev a1)

Revision history for this message
gnufreex (gnufreex) wrote :

I updated to Karmic Koala, and I think there is no any bug anymore. When I type 'nvclock --info', there is no that "stack smacking" anymore. 'nvclock -f --fanspeed XX' works fine as well. Well done fixing that bug.

@aftertaf

What qt and gtk+ versions? I use only terminal version. Did not know that threre is any graphical one. :D

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.