gqrx-sdr crashes on startup

Bug #1637774 reported by Robert Grasböck
180
This bug affects 39 people
Affects Status Importance Assigned to Milestone
gqrx-sdr (Ubuntu)
Confirmed
Undecided
Unassigned

Bug Description

If gqrx is started, it crashes during startup.

gqrx
linux; GNU C++ version 6.2.0 20160824; Boost_106100; UHD_003.009.005-0-unknown

Controlport disabled
No user supplied config file. Using "default.conf"
gr-osmosdr 0.1.4 (0.1.4) gnuradio 3.7.10
built-in source types: file osmosdr fcd rtl rtl_tcp uhd miri hackrf bladerf rfspace airspy redpitaya
FM demod gain: 1.52789
IQ DCR alpha: 1.04166e-05
Using audio backend: auto
BookmarksFile is /home/user/.config/gqrx/bookmarks.csv
fish: 'gqrx' terminated by signal SIGSEGV (Adressbereichsfehler)

gdb tells us this:

(gdb) r
Starting program: /usr/bin/gqrx
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
linux; GNU C++ version 6.2.0 20160824; Boost_106100; UHD_003.009.005-0-unknown

[New Thread 0x7fffe3c2c700 (LWP 28577)]
[New Thread 0x7fffd8d00700 (LWP 28578)]
Controlport disabled
No user supplied config file. Using "default.conf"
gr-osmosdr 0.1.4 (0.1.4) gnuradio 3.7.10
built-in source types: file osmosdr fcd rtl rtl_tcp uhd miri hackrf bladerf rfspace airspy redpitaya
FM demod gain: 1.52789
IQ DCR alpha: 1.04166e-05
[New Thread 0x7fffcf5ef700 (LWP 28579)]
Using audio backend: auto
BookmarksFile is /home/user/.config/gqrx/bookmarks.csv
[New Thread 0x7fffcd99e700 (LWP 28580)]
[Thread 0x7fffcd99e700 (LWP 28580) exited]
[New Thread 0x7fffcd99e700 (LWP 28581)]
[Thread 0x7fffcd99e700 (LWP 28581) exited]
[New Thread 0x7fffcd99e700 (LWP 28582)]
[Thread 0x7fffcd99e700 (LWP 28582) exited]
[New Thread 0x7fffcd99e700 (LWP 28583)]
[Thread 0x7fffcd99e700 (LWP 28583) exited]
[New Thread 0x7fffcd99e700 (LWP 28584)]
[New Thread 0x7fffcd19d700 (LWP 28585)]
[Thread 0x7fffcd19d700 (LWP 28585) exited]
[Thread 0x7fffcd99e700 (LWP 28584) exited]

Thread 1 "gqrx" received signal SIGSEGV, Segmentation fault.
0x00007ffff6df4188 in boost::asio::detail::task_io_service::shutdown_service() () from /usr/lib/x86_64-linux-gnu/libgnuradio-blocks.so.3.7.10
(gdb) where
#0 0x00007ffff6df4188 in boost::asio::detail::task_io_service::shutdown_service() () from /usr/lib/x86_64-linux-gnu/libgnuradio-blocks.so.3.7.10
#1 0x00007ffff6df6fb9 in boost::asio::detail::resolver_service_base::shutdown_service() () from /usr/lib/x86_64-linux-gnu/libgnuradio-blocks.so.3.7.10
#2 0x00007ffff12dd159 in ?? () from /usr/lib/x86_64-linux-gnu/libuhd.so.003
#3 0x00007ffff151de3a in ?? () from /usr/lib/x86_64-linux-gnu/libuhd.so.003
#4 0x00007ffff152e2a1 in ?? () from /usr/lib/x86_64-linux-gnu/libuhd.so.003
#5 0x00007ffff152cfee in ?? () from /usr/lib/x86_64-linux-gnu/libuhd.so.003
#6 0x00007ffff14ef360 in ?? () from /usr/lib/x86_64-linux-gnu/libuhd.so.003
#7 0x00007ffff1699f13 in uhd::device::find(uhd::device_addr_t const&, uhd::device::device_filter_t) () from /usr/lib/x86_64-linux-gnu/libuhd.so.003
#8 0x00007ffff6190443 in ?? () from /usr/lib/x86_64-linux-gnu/libgnuradio-osmosdr.so.0.1.4
#9 0x00007ffff6167a1b in osmosdr::device::find(osmosdr::device_t const&) () from /usr/lib/x86_64-linux-gnu/libgnuradio-osmosdr.so.0.1.4
#10 0x0000555555699bdb in CIoConfig::getDeviceList(std::map<QString, QVariant, std::less<QString>, std::allocator<std::pair<QString const, QVariant> > >&) ()
#11 0x000055555561302c in MainWindow::MainWindow(QString, bool, QWidget*) ()
#12 0x00005555555b505a in main ()

It seems it is a problem with boost and the rest.
Maybe an upgrade to version 2.6 will fix the issues?

Revision history for this message
Dennis Heitmann (dennisheitmann) wrote :

I can confirm the bug on my computer:

[dennis@dennis-pc][~]% gdb gqrx
GNU gdb (Ubuntu 7.11.90.20161005-0ubuntu1) 7.11.90.20161005-git
Copyright (C) 2016 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-linux-gnu".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
<http://www.gnu.org/software/gdb/documentation/>.
For help, type "help".
Type "apropos word" to search for commands related to "word"...
Reading symbols from gqrx...(no debugging symbols found)...done.
(gdb) r
Starting program: /usr/bin/gqrx
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
linux; GNU C++ version 6.2.0 20160824; Boost_106100; UHD_003.009.005-0-unknown

[New Thread 0x7fffe3c11700 (LWP 7560)]
Controlport disabled
No user supplied config file. Using "default.conf"
[New Thread 0x7fffd74fb700 (LWP 7561)]
gr-osmosdr 0.1.4 (0.1.4) gnuradio 3.7.10
built-in source types: file osmosdr fcd rtl rtl_tcp uhd miri hackrf bladerf rfspace airspy redpitaya
FM demod gain: 1.52789
IQ DCR alpha: 1.04166e-05
[New Thread 0x7fffd6a5d700 (LWP 7562)]
Using audio backend: auto
BookmarksFile is /home/dennis/.config/gqrx/bookmarks.csv
[New Thread 0x7fffd4d28700 (LWP 7563)]
[Thread 0x7fffd4d28700 (LWP 7563) exited]
[New Thread 0x7fffd4d28700 (LWP 7564)]
[Thread 0x7fffd4d28700 (LWP 7564) exited]
[New Thread 0x7fffd4d28700 (LWP 7565)]
[Thread 0x7fffd4d28700 (LWP 7565) exited]
[New Thread 0x7fffd4d28700 (LWP 7566)]
[Thread 0x7fffd4d28700 (LWP 7566) exited]
[New Thread 0x7fffd4d28700 (LWP 7567)]
[New Thread 0x7fffcbfff700 (LWP 7568)]
[Thread 0x7fffcbfff700 (LWP 7568) exited]
[Thread 0x7fffd4d28700 (LWP 7567) exited]

Thread 1 "gqrx" received signal SIGSEGV, Segmentation fault.
0x00007ffff6df4188 in boost::asio::detail::task_io_service::shutdown_service() () from /usr/lib/x86_64-linux-gnu/libgnuradio-blocks.so.3.7.10
(gdb)

Revision history for this message
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in gqrx-sdr (Ubuntu):
status: New → Confirmed
Revision history for this message
Tonu Jaansoo (chain256) wrote :

Confirming

Revision history for this message
misko (michael-wagner-gmx) wrote :

Unfortunately it affects me too:

GNU gdb (Ubuntu 7.11.90.20161005-0ubuntu1) 7.11.90.20161005-git
Copyright (C) 2016 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-linux-gnu".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
<http://www.gnu.org/software/gdb/documentation/>.
For help, type "help".
Type "apropos word" to search for commands related to "word"...
Reading symbols from gqrx...(no debugging symbols found)...done.
(gdb) r
Starting program: /usr/bin/gqrx
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
linux; GNU C++ version 6.2.0 20160824; Boost_106100; UHD_003.009.005-0-unknown

[New Thread 0x7fffe3c3f700 (LWP 8256)]
Controlport disabled
No user supplied config file. Using "default.conf"
[New Thread 0x7fffe2fab700 (LWP 8257)]
gr-osmosdr 0.1.4 (0.1.4) gnuradio 3.7.10
built-in source types: file osmosdr fcd rtl rtl_tcp uhd miri hackrf bladerf rfspace airspy redpitaya
FM demod gain: 1.52789
IQ DCR alpha: 1.04166e-05
[New Thread 0x7fffe23b7700 (LWP 8263)]
Using audio backend: auto
BookmarksFile is /root/.config/gqrx/bookmarks.csv
[New Thread 0x7fffcffff700 (LWP 8264)]
[Thread 0x7fffcffff700 (LWP 8264) exited]
[New Thread 0x7fffcffff700 (LWP 8265)]
[Thread 0x7fffcffff700 (LWP 8265) exited]
[New Thread 0x7fffcffff700 (LWP 8266)]
[New Thread 0x7fffcf7fe700 (LWP 8267)]
[Thread 0x7fffcf7fe700 (LWP 8267) exited]
[Thread 0x7fffcffff700 (LWP 8266) exited]

Thread 1 "gqrx" received signal SIGSEGV, Segmentation fault.
0x00007ffff6df4188 in boost::asio::detail::task_io_service::shutdown_service() () from /usr/lib/x86_64-linux-gnu/libgnuradio-blocks.so.3.7.10

(reproducible on two different machines)

Revision history for this message
misko (michael-wagner-gmx) wrote :

This bug was discussed on the github of gqrx,( https://github.com/csete/gqrx/issues/452 )
There, following workaround was found:
Recompile gr-osmosdr from sources, but diable UHD-support -> then gqrx works (at least with RTL2838 DVB-T-Sticks).
So, the bug seems to be there, and not in gqrx.

Revision history for this message
flux242 (flux242) wrote :

if you have compiled gr-osmosdr yourself and still nothing works then it could be becase there's another lib installed in the /usr/lib/x86_64-linux-gnu

solution:

sudo mv /usr/lib/x86_64-linux-gnu/libgnuradio-osmosdr.so.0.1.4 /usr/lib/x86_64-linux-gnu/libgnuradio-osmosdr.so.0.1.4.sav

sudo ln -s /usr/local/lib/libgnuradio-osmosdr.so /usr/lib/x86_64-linux-gnu/libgnuradio-osmosdr.so.0.1.4

Revision history for this message
DooMMasteR (winrootkit-w) wrote :

I am also affected, I rebuild gnuradio with the defaults on my machine and everything works fine.
So I think the package is broken, but would like to know how this happened...

Revision history for this message
gadLinux (gad-aguilardelgado) wrote :

Affects me also...

Revision history for this message
Henning Meyer (henning.meyer) wrote :

This crash is caused by a C++ ODR violation between libuhd.so.003 and libgnuradio-blocks.so.3.7.10 both of which implement the virtual class boost::asio::detail::task_io_service but the implementations are not identical

Revision history for this message
Henning Meyer (henning.meyer) wrote :

since gqrx does not actually use boost::asio functionality in libgnuradio-blocks, the following workaround prevents crashes:

```
set LD_PRELOAD=/usr/lib/x86_64-linux-gnu/libuhd.so.003
gqrx
```

without the need to change libraries on the file system

Revision history for this message
Henning Meyer (henning.meyer) wrote :

of course, the maintainers of libgnuradio and libuhd should figure out which library is at fault (i.e. built with non-standard compile options or boost versions) so that this does not happen again

Revision history for this message
Henning Meyer (henning.meyer) wrote :

I looked at the build logs and gnuradio is build with the flag std=c++98 while g++ defaults to std=c++14 and libuhd uses the defaults.

Revision history for this message
Henning Meyer (henning.meyer) wrote :

gnuradio in Ubuntu 17.10 will be built with std=c++11 hopefully that will avoid the problem.

Revision history for this message
Alexandru Csete (alexc) wrote :

Hello,

It looks like this problem has been resolved. At least I no longer see this problem in Ubuntu 18.04 even though UHD support is enabled.

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

Duplicates of this bug

Other bug subscribers

Remote bug watches

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