Source: Jussi Laakkonen, Jolla.
-----------------------
Debugging connman
It would really help to see what prevents connman from waking up. This document instructs how to start a log with the gdb (GNU debugger) in such a case. Most likely, some packages are not installed/configured but required by connman.
Stopping connman before debugging can start
NOTE: gdb is not included in the public Sailfish OS releases - it has to be installed.
First of all, we need to stop connman and ensure it did not start by itself in the meanwhile:
devel-su
systemctl stop connman pidof connman systemctl status connman
Start debugging
If connman does not start running after an OS update or in some other case (i.e. the device cannot access the Internet), give the following command to start connman with gdb enabled (root rights required):
> gdb --args /usr/sbin/connmand -n -W nl80211 --nobacktrace \
--systemd --noplugin=wifi
Next, type the following command in gdb:
> run
and press enter. This will print the errors, if any, in startup of connman. The errors such as
> Missing separate debuginfo for
are just what they state, missing debugging info that can be installed using the command given below the warning. The information provided in gdb would help to pinpoint the problem.
A demo run
This chapter shows how a demo run worked on a device where connman has worked normally.
[root@Sailfish nemo]# pkill connmand
[root@Sailfish nemo]# gdb --args /usr/sbin/connmand -n -W nl80211 --nobacktrace --systemd --noplugin=wifi
GNU gdb (GDB) Mer (8.2.1+git7)
Copyright (C) 2018 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 "armv7hl-meego-linux-gnueabi". 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 /usr/sbin/connmand...Missing separate debuginfo for /usr/sbin/connmand Try: zypper install -C "debuginfo(build-id)=cdf136451435958afd57fecfb2414e74561a2580" (no debugging symbols found)...done.
(gdb) run Starting program: /usr/sbin/connmand -n -W nl80211 --nobacktrace --systemd --noplugin=wifi Missing separate debuginfo for /lib/ld-linux-armhf.so.3 Try: zypper install -C "debuginfo(build-id)=8446552173b8e4f4421806af6d806408d05c931f" Missing separate debuginfo for /usr/lib/libdbus-1.so.3 Try: zypper install -C "debuginfo(build-id)=092d271a1144000bcccfe3c01f86e1ffa5ad3e6b" Missing separate debuginfo for /usr/lib/libxtables.so.12 Try: zypper install -C "debuginfo(build-id)=bb657689c56b0fa29b347e8928c9f20ca4dfc037" Missing separate debuginfo for /usr/lib/libgnutls.so.26 Try: zypper install -C "debuginfo(build-id)=61f6f99ac31fcecf8d1e65a026c4aab529f11c99" Missing separate debuginfo for /usr/lib/libiphb.so.0 Try: zypper install -C "debuginfo(build-id)=246f5d6280c994eb53e3af2510ad3eccc55b041a" Missing separate debuginfo for /usr/lib/libip4tc.so.0 Try: zypper install -C "debuginfo(build-id)=1826929b65d96f186f59fda38066122179a801b9" Missing separate debuginfo for /usr/lib/libdbusaccess.so.1 Try: zypper install -C "debuginfo(build-id)=91531e6d3c28e26b3b0ea2b2de1e487428b65a07" Missing separate debuginfo for /lib/libresolv.so.2 Try: zypper install -C "debuginfo(build-id)=0a862a7ce620ccb65625918f9e333ae4e7f26c1d" Missing separate debuginfo for /lib/libdl.so.2 Try: zypper install -C "debuginfo(build-id)=96caba7c3a7208d47cf8c3b2ee72b963d3a7636b" Missing separate debuginfo for /usr/lib/libsystemd.so.0
Try: zypper install -C "debuginfo(build-id)=3942da68ec901d805f9a499c838c86d1e9cefadc" Missing separate debuginfo for /usr/lib/libdbuslogserver-dbus.so.1 Try: zypper install -C "debuginfo(build-id)=276173a49939ae66ad62bce54a084bd7d29f7909" Missing separate debuginfo for /usr/lib/libgsupplicant.so.1 Try: zypper install -C "debuginfo(build-id)=604e9d4dc06c2bd9e321cd0ccde9dee3b9036b76" Missing separate debuginfo for /usr/lib/libmce-glib.so.1 Try: zypper install -C "debuginfo(build-id)=f1105803ca96bb0441e10c2c9afbdf81be33676f" Missing separate debuginfo for /usr/lib/libgofonoext.so.1 Try: zypper install -C "debuginfo(build-id)=10431d839e19e92d91e49766bb8630eb93ee7631" Missing separate debuginfo for /usr/lib/libgio-2.0.so.0 Try: zypper install -C "debuginfo(build-id)=70a5e254541740aee8805860bfffe9e363521bcb" Missing separate debuginfo for /usr/lib/libgobject-2.0.so.0 Try: zypper install -C "debuginfo(build-id)=ef0290f7d9dd0f2b8e79bc33277696aa8c963c2b" Missing separate debuginfo for /usr/lib/libglib-2.0.so.0 Try: zypper install -C "debuginfo(build-id)=8e0d033ea6e49a47c47a1f54a2bac9f9949d9f82" Missing separate debuginfo for /usr/lib/libgofono.so.2 Try: zypper install -C "debuginfo(build-id)=eca31d3fedf001c1f4d6cc57ad9dfabc6cd12508" Missing separate debuginfo for /usr/lib/libglibutil.so.1 Try: zypper install -C "debuginfo(build-id)=c3c36d7093afb1b2028ca74c5cd90a22017e8f61" Missing separate debuginfo for /lib/libgcc_s.so.1 Try: zypper install -C "debuginfo(build-id)=b9a936eb5126c54444a44172ad83c001a534c06d" Missing separate debuginfo for /lib/libpthread.so.0 Try: zypper install -C "debuginfo(build-id)=397de98628fd803e732533580eb002e57f8b3af8" warning: File "/lib/libthread_db-1.0.so" auto-loading has been declined by your `auto-load safe-path' set to "$debugdir:$datadir/auto-load".
To enable execution of this file add add-auto-load-safe-path /lib/libthread_db-1.0.so line to your configuration file "/root/.gdbinit". To completely disable this security protection add set auto-load safe-path / line to your configuration file "/root/.gdbinit". For more information about this security protection see the "Auto-loading safe path" section in the GDB manual. E.g., run from the shell: info "(gdb)Auto-loading safe path" warning: Unable to find libthread_db matching inferior's thread library, thread debugging will not be available.
Missing separate debuginfo for /lib/libc.so.6 Try: zypper install -C "debuginfo(build-id)=e3856548d9b975e72ae70b3f6568dcd1ed57310a" Missing separate debuginfo for /usr/lib/libgcrypt.so.20 Try: zypper install -C "debuginfo(build-id)=af352d0be3dfda9b07bc9b3e4c0ff71a235f8d71" Missing separate debuginfo for /usr/lib/libz.so.1 Try: zypper install -C "debuginfo(build-id)=9523cdced798c5286bbbf6a1f07d285386b506c7" Missing separate debuginfo for /usr/lib/libtasn1.so.6 Missing separate debuginfo for /usr/lib/libp11-kit.so.0 Try: zypper install -C "debuginfo(build-id)=bf7d4e349da8fd111590e802e14ede15afc9bf97" Missing separate debuginfo for /lib/librt.so.1 Try: zypper install -C "debuginfo(build-id)=e29ad0bd73e5b5bee7e0ee4da5ea51fd7874404f" Missing separate debuginfo for /usr/lib/libselinux.so.1 Try: zypper install -C "debuginfo(build-id)=a99116063880034ff1076ab2137145b765a4ecb6" Missing separate debuginfo for /lib/libm.so.6 Try: zypper install -C "debuginfo(build-id)=1b4fed5a5fc11e010aa16c45f579732f33f05e14" Missing separate debuginfo for /usr/lib/liblzma.so.5 Try: zypper install -C "debuginfo(build-id)=e22bbd1f4d484e5e32ec43fdad2ab1dcd50d6c52" Missing separate debuginfo for /usr/lib/libgpg-error.so.0 Try: zypper install -C "debuginfo(build-id)=637aff4743b33bdaaf9437ab6f332dbf099da165" Missing separate debuginfo for /usr/lib/libcap.so.2 Try: zypper install -C "debuginfo(build-id)=262507b94863ef5972e814e29572b685022e4999" Missing separate debuginfo for /usr/lib/libgmodule-2.0.so.0 Try: zypper install -C "debuginfo(build-id)=62eb2395652c7479e12eb9acdacfb4f5f0255e82" Missing separate debuginfo for /usr/lib/libffi.so.6 Try: zypper install -C "debuginfo(build-id)=a3a2ecab4f75343bda388c73b1754267700fdb88" Missing separate debuginfo for /usr/lib/libpcre.so.1 Try: zypper install -C "debuginfo(build-id)=0139a0e9ad27cb93dc6c1dc08da76a49c7041e02" Name already in use [Inferior 1 (process 11324) exited with code 01]