Bug 435581 - weird messages when running a program
weird messages when running a program
Status: CLOSED CURRENTRELEASE
Product: Fedora
Classification: Fedora
Component: gdb (Show other bugs)
8
i386 Linux
low Severity medium
: ---
: ---
Assigned To: Jan Kratochvil
Fedora Extras Quality Assurance
:
Depends On: 437414
Blocks:
  Show dependency treegraph
 
Reported: 2008-03-01 22:33 EST by Sam Steingold
Modified: 2008-03-17 09:22 EDT (History)
0 users

See Also:
Fixed In Version: gdb-6.6-44.fc8
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2008-03-10 08:18:57 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Sam Steingold 2008-03-01 22:33:22 EST
Description of problem:

when I type "run" in gdb, I get these messages:

Missing separate debuginfo for /lib/ld-linux.so.2
Try: yum --enablerepo='*-debuginfo' install
/usr/lib/debug/.build-id/ac/2eeb206486bb7315d6ac4cd64de0cb50838ff6.debug
Missing separate debuginfo for /lib/libreadline.so.5
Try: yum --enablerepo='*-debuginfo' install
/usr/lib/debug/.build-id/4c/22c0deaa525a4ea4d2a4716f78c52ea9cbc2e5.debug
Missing separate debuginfo for /lib/libncurses.so.5
Try: yum --enablerepo='*-debuginfo' install
/usr/lib/debug/.build-id/f5/735b0c029fbb57ec488d85aa972e05dba5f934.debug
Missing separate debuginfo for /lib/libdl.so.2
Try: yum --enablerepo='*-debuginfo' install
/usr/lib/debug/.build-id/db/a292aff9720bfc3f25c53fa8e469168460a894.debug
Missing separate debuginfo for /usr/lib/libsigsegv.so.0
Try: yum --enablerepo='*-debuginfo' install
/usr/lib/debug/.build-id/a1/faa4b8b1f6d6718f1eb9d7d0bd29c4f50bf9e4.debug
Missing separate debuginfo for /lib/libc.so.6
Try: yum --enablerepo='*-debuginfo' install
/usr/lib/debug/.build-id/ba/4ea1118691c826426e9410cafb798f25cefad5.debug
Missing separate debuginfo for /lib/libtinfo.so.5
Try: yum --enablerepo='*-debuginfo' install
/usr/lib/debug/.build-id/af/9d8e017bca658da6adef0e9493a047bc1e6e09.debug
STACK depth: 98206 [0x1c0f00 0x161088]
Missing separate debuginfo for /usr/lib/gconv/CP1255.so
Try: yum --enablerepo='*-debuginfo' install
/usr/lib/debug/.build-id/d5/a0ae5875c4f3d0aedbfad07d24b517f87a5783.debug
Missing separate debuginfo for /usr/lib/gconv/CP1258.so
Try: yum --enablerepo='*-debuginfo' install
/usr/lib/debug/.build-id/08/42ab1dc933a09e98072d54356e1a58d9194759.debug
Missing separate debuginfo for /usr/lib/gconv/EUC-JP.so
Try: yum --enablerepo='*-debuginfo' install
/usr/lib/debug/.build-id/fd/89bec41718d908562f1f3744aae016c90ffb5a.debug
Missing separate debuginfo for /usr/lib/gconv/libJIS.so
Try: yum --enablerepo='*-debuginfo' install
/usr/lib/debug/.build-id/74/f892a23bff1913ddefb351e8024bb52ce7a242.debug
Missing separate debuginfo for /usr/lib/gconv/SJIS.so
Try: yum --enablerepo='*-debuginfo' install
/usr/lib/debug/.build-id/d7/816301d14efc4db82b5f0aa3cd79afd2067891.debug
Missing separate debuginfo for /usr/lib/gconv/CP932.so
Try: yum --enablerepo='*-debuginfo' install
/usr/lib/debug/.build-id/7a/2dcb3006e369c71a8f3d5285604a38711c35ab.debug
Missing separate debuginfo for /usr/lib/gconv/ISO-2022-JP.so
Try: yum --enablerepo='*-debuginfo' install
/usr/lib/debug/.build-id/37/f00cd239515eb3bc8c69d53a6626c0e93d0e8b.debug
Missing separate debuginfo for /usr/lib/gconv/libGB.so
Try: yum --enablerepo='*-debuginfo' install
/usr/lib/debug/.build-id/5c/7c841035b9cf7be54064805d58ede1f69290a9.debug
Missing separate debuginfo for /usr/lib/gconv/libKSC.so
Try: yum --enablerepo='*-debuginfo' install
/usr/lib/debug/.build-id/2b/4df5d759baf1c997b7dd08976307d45d25a09f.debug
Missing separate debuginfo for /usr/lib/gconv/EUC-CN.so
Try: yum --enablerepo='*-debuginfo' install
/usr/lib/debug/.build-id/ce/08ac03b36608c97d2b29bacdb354cc6b4d38c1.debug
Missing separate debuginfo for /usr/lib/gconv/GBK.so
Try: yum --enablerepo='*-debuginfo' install
/usr/lib/debug/.build-id/2b/95a8d845632e9551fa3b07967e8524eca510d5.debug
Missing separate debuginfo for /usr/lib/gconv/GB18030.so
Try: yum --enablerepo='*-debuginfo' install
/usr/lib/debug/.build-id/0c/db8b776525397f622ae99a05529b52338a0167.debug
Missing separate debuginfo for /usr/lib/gconv/EUC-TW.so
Try: yum --enablerepo='*-debuginfo' install
/usr/lib/debug/.build-id/85/4460cccef3b7db5eba3a8619a24ebeb529dae6.debug
Missing separate debuginfo for /usr/lib/gconv/libCNS.so
Try: yum --enablerepo='*-debuginfo' install
/usr/lib/debug/.build-id/0e/0b59091aad2cb7b72d940672f3dc9e619288ec.debug
Missing separate debuginfo for /usr/lib/gconv/BIG5.so
Try: yum --enablerepo='*-debuginfo' install
/usr/lib/debug/.build-id/53/cb7d6bab17020db1eb53ec8315a39836b14eb8.debug
Missing separate debuginfo for /usr/lib/gconv/BIG5HKSCS.so
Try: yum --enablerepo='*-debuginfo' install
/usr/lib/debug/.build-id/bf/7f49e24739b6830bee44621a6db932063c8a91.debug
Missing separate debuginfo for /usr/lib/gconv/ISO-2022-CN.so
Try: yum --enablerepo='*-debuginfo' install
/usr/lib/debug/.build-id/b6/5ce2cb85bf9a6a8c33b8422e63e33e95a30d9e.debug
Missing separate debuginfo for /usr/lib/gconv/ISO-2022-CN-EXT.so
Try: yum --enablerepo='*-debuginfo' install
/usr/lib/debug/.build-id/bb/811c5269ff398afb6387411babba64550ed7e7.debug
Missing separate debuginfo for /usr/lib/gconv/libISOIR165.so
Try: yum --enablerepo='*-debuginfo' install
/usr/lib/debug/.build-id/7a/e1ba08740d31a2bd257ee461cc6b54f31c855e.debug
Missing separate debuginfo for /usr/lib/gconv/EUC-KR.so
Try: yum --enablerepo='*-debuginfo' install
/usr/lib/debug/.build-id/f3/19fcdad2c8d4e679ef30ff7e2283fefc9d9d49.debug
Missing separate debuginfo for /usr/lib/gconv/UHC.so
Try: yum --enablerepo='*-debuginfo' install
/usr/lib/debug/.build-id/b2/457fab11c05c7463e7616ea6d084677039c8f9.debug
Missing separate debuginfo for /usr/lib/gconv/ISO-2022-KR.so
Try: yum --enablerepo='*-debuginfo' install
/usr/lib/debug/.build-id/94/d2d958b2920550923795b7dfc37ede61a411cc.debug
Missing separate debuginfo for /usr/lib/gconv/JOHAB.so
Try: yum --enablerepo='*-debuginfo' install
/usr/lib/debug/.build-id/4c/792fe5a47115205331b14eb2e5ea8e779a7dfa.debug
Missing separate debuginfo for /usr/lib/gconv/ARMSCII-8.so
Try: yum --enablerepo='*-debuginfo' install
/usr/lib/debug/.build-id/69/a6685d19deadf8229f9d69471457984f80939e.debug
Missing separate debuginfo for /usr/lib/gconv/GEORGIAN-ACADEMY.so
Try: yum --enablerepo='*-debuginfo' install
/usr/lib/debug/.build-id/18/20a9141c8263b67fc8e0194ed07ef3795cfad9.debug
Missing separate debuginfo for /usr/lib/gconv/GEORGIAN-PS.so
Try: yum --enablerepo='*-debuginfo' install
/usr/lib/debug/.build-id/12/0a6bd7a48198c6a61e0b40b33eedb9fea326f9.debug
Missing separate debuginfo for /usr/lib/gconv/TIS-620.so
Try: yum --enablerepo='*-debuginfo' install
/usr/lib/debug/.build-id/fd/0e682c509137c89fd6363fa867a0c8cc0e67e8.debug
Missing separate debuginfo for /usr/lib/gconv/IBM1133.so
Try: yum --enablerepo='*-debuginfo' install
/usr/lib/debug/.build-id/ca/060d19a2930bc16164aeeb4ee6c25fe2ef18b8.debug
Missing separate debuginfo for /usr/lib/gconv/VISCII.so
Try: yum --enablerepo='*-debuginfo' install
/usr/lib/debug/.build-id/83/b2a7760b5dfd332fbf46bf2ae7dc1bf26de624.debug
Missing separate debuginfo for /usr/lib/gconv/TCVN5712-1.so
Try: yum --enablerepo='*-debuginfo' install
/usr/lib/debug/.build-id/4f/4fe1432cadc6cb793bea630ca37ad7fae6cf89.debug
Missing separate debuginfo for /usr/lib/gconv/UTF-16.so
Try: yum --enablerepo='*-debuginfo' install
/usr/lib/debug/.build-id/d7/682620ff7055d12bdf18226d942f0c71402e34.debug
Missing separate debuginfo for /usr/lib/gconv/UTF-7.so
Try: yum --enablerepo='*-debuginfo' install
/usr/lib/debug/.build-id/55/802c997a0c60ea4269c333db445fac2c2eebb1.debug

Version-Release number of selected component (if applicable):

GNU gdb Red Hat Linux (6.6-43.fc8rh)

How reproducible:

always

Steps to Reproduce:
1.gdb /bin/ls
2.run
3.
  
Actual results:

lots of useless messages are displayed before the program starts running:

Missing separate debuginfo for /bin/ls
Try: yum --enablerepo='*-debuginfo' install
/usr/lib/debug/.build-id/0f/ec5c4e1d8f00996dcc2d47db9e525e1d323ad5.debug
Getting all the debuginfos: debuginfo-install coreutils
(no debugging symbols found)
Using host libthread_db library "/lib/libthread_db.so.1".
(gdb) run
Starting program: /bin/ls 
Missing separate debuginfo for /lib/ld-linux.so.2
Try: yum --enablerepo='*-debuginfo' install
/usr/lib/debug/.build-id/ac/2eeb206486bb7315d6ac4cd64de0cb50838ff6.debug
(no debugging symbols found)
(no debugging symbols found)
Missing separate debuginfo for /lib/librt.so.1
Try: yum --enablerepo='*-debuginfo' install
/usr/lib/debug/.build-id/e3/3448de964a5ca97b70edbdcea227c6ea5d3657.debug
(no debugging symbols found)
Missing separate debuginfo for /lib/libselinux.so.1
Try: yum --enablerepo='*-debuginfo' install
/usr/lib/debug/.build-id/45/ae9842e5eaf90347568dcd3e8fa60ffd4de915.debug
(no debugging symbols found)
Missing separate debuginfo for /lib/libacl.so.1
Try: yum --enablerepo='*-debuginfo' install
/usr/lib/debug/.build-id/53/c828a4dd19ddb6529d0f2a627e9230374003fa.debug
(no debugging symbols found)
Missing separate debuginfo for /lib/libc.so.6
Try: yum --enablerepo='*-debuginfo' install
/usr/lib/debug/.build-id/ba/4ea1118691c826426e9410cafb798f25cefad5.debug
(no debugging symbols found)
Missing separate debuginfo for /lib/libpthread.so.0
Try: yum --enablerepo='*-debuginfo' install
/usr/lib/debug/.build-id/6c/1cdbb38ae2a292613c8c31195417ee80ea7e1e.debug
(no debugging symbols found)
[Thread debugging using libthread_db enabled]
Missing separate debuginfo for /lib/libdl.so.2
Try: yum --enablerepo='*-debuginfo' install
/usr/lib/debug/.build-id/db/a292aff9720bfc3f25c53fa8e469168460a894.debug
(no debugging symbols found)
Missing separate debuginfo for /lib/libattr.so.1
Try: yum --enablerepo='*-debuginfo' install
/usr/lib/debug/.build-id/b6/0a763c9ebf47f4eeb6c90f6dc820daeb179dff.debug
(no debugging symbols found)


Expected results:

no messages about yum and "Missing separate debuginfo".
the program is executed with possibly 1 (one!) message "(no debugging symbols
found)".

Additional info:
Comment 1 Jan Kratochvil 2008-03-02 00:28:04 EST
Simple workaround for you is to type:
  echo 'set build-id-verbose 0' >>~/.gdbinit 

This is the common conflict of experienced and unexperienced users.
The latter try to debug programs without having the debuginfos installed and the
message `(no debugging symbols found)' is not suggestive enough for them to run:
  debuginfo-install coreutils

Still going to fix it to display only the message:
  debuginfo-install coreutils
if the main debuginfo file is not installed and display the specific build-id
identifiers only if some debuginfo was found but it is not matching the version.
Comment 2 Sam Steingold 2008-03-02 11:34:20 EST
just to clarify: I am NOT interested in debugging
any system utilities or libraries.
I am debugging my own program (compiled with "-g").
Comment 3 Jan Kratochvil 2008-03-02 13:54:42 EST
It depends on the type of the application.

If you develop some mathematical computing application sure you do not care of
the system libraries.

On the other hand some (IMO most) applications mostly call various libraries and
it is essential to be able to see what happens in them:
 * To see what parameters were passed to the functions by the application.
 * To see why the calls do what they do - if we are using the debugger something
   wrong happened and we could call the function a wrong way.
 * Memory corrupted structures crashing in the library need inspection of the
   library code to find out what was wrong in the data structure passed by the
   application.

Missing debuginfos lead to the Bugs like the Bug 385941 (and many others).
In fact Bug 433464 Comment 1 is also due to a missing debuginfo.
Unfortunately it can be seen even the warning messages do not hint the users to
really install the debuginfos there but I believe it could help a lot of them.

It is true it should be more integrated with the package management and offer
automatic installation of the debuginfos there.  This is planned for ...F10?


Another point is that current debuginfos are lacking some info such as the
parameter <value optimized out> in the backtrace
#1  0x0000003b99a3209e in g_main_context_iterate (context=0x1e71660, block=1,
dispatch=1, self=<value optimized out>)
    at gmain.c:2996
This debuginfo content defect is being worked on upstream by RH Alexandre Oliva.
I was using `-O0 -ggdb2' locally rebuilt RPMs to overcome this problem before.


In fact I find much more useless the following info being printed by upstream
GDB as it does not tell any bit of useful information while scrolling over the
screen and which it would be better to remove in the future:
Reading symbols from /usr/lib64/purple-2/log_reader.so...Reading symbols from
/usr/lib/debug/usr/lib64/purple-2/log_reader.so.debug...done.
done.
Loaded symbols for /usr/lib64/purple-2/log_reader.so
Reading symbols from /usr/lib64/purple-2/libmsn.so...Reading symbols from
/usr/lib/debug/usr/lib64/purple-2/libmsn.so.debug...done.
done.


I am not sure what specific problem would you like to solve - the debuginfos are
not so large for the current network bandwidth and with all the application
debugging help they provide they should be there for any inexperienced user who
did not explicitely disable the messages (which I would never do myself anyway).


Automatic integration with the package management (PackageKit?) did not happen
for F9 which could, hopefully it should get fixed for F10.


The messages reduction noted in the Comment 1 here sure would not apply to a
locally built custom application debugging.
Comment 4 Jan Kratochvil 2008-03-02 14:52:14 EST
In fact no one wants the build-id numbers by default.
There are two different problems:

(1) debuginfo could be installed but its version does not match.
    In this case the build-id should be displayed but such case usually
    does not happen.

(2) Suggesting the user to install debuginfos in general.
    The message
      Getting all the debuginfos: debuginfo-install coreutils
    would work for the system applications but not for the compiled ones as
    they do not have a single debuginfo dependency package to install.
    A single-line with all the package names collected should be sufficient
    for the compiled applications (if it should be present at all as
    the real developers are usually more aware of the debuginfos existence).

I hope the (1) + (2) solution would satisfy all the needs.
Sure most of the users will continue to ignore the warning message.
Comment 5 Sam Steingold 2008-03-02 22:35:47 EST
1. the warning message should never be more than 1 or 2 lines. no exceptions.
2. the message should clearly indicate how how disable it.
3. the message should say what to do to get the debuginfos.

E.g.:
no debug info for some libraries (gdb --debug-libraries for more information,
"echo 'set build-id-verbose 0' >>~/.gdbinit" to disable this warning).

and then gdb --debug-libraries should print all the warnings I complained about
in the original report.
alternatively, you can skip [2], i.e., "echo > ~/.gdbinit", if "man gdb" clearly
says that when documenting the --debug-libraries option.
Comment 6 Jan Kratochvil 2008-03-03 01:38:17 EST
1. You are right the list of the libraries should get collected into a single
   line, such as: yum-install /usr/lib/...hash1 /usr/lib/...hash2 ...
   I tried such patch before but the current GDB execution is unfriendly where
   to insert the final list flush/printing.  It should get improved/implemented.

2. Not all the GDB behavior is documented during its execution.  I agree it is
   not right but it is the GDB style, there are GDB GUIs for a more intuitive
   behavior.  There is the info GDB manual for documenting GDB itself.
   The `build-id-verbose' option is already documented in the GDB manual.

3. Already done - it suggests either `debuginfo-install' or `yum install'.

It is more a different view of the problem.
I find the debuginfo packages essential to start using GDB and so it should not
require restarting GDB with an extra option --debug-libraries.

But we match in my Comment 4 point (2) and your Comment 5 point 1. so I hope it
will be acceptable afterwards.
Comment 7 Sam Steingold 2008-03-03 09:18:39 EST
(In reply to comment #6)
> It is more a different view of the problem.
> I find the debuginfo packages essential to start using GDB and so it should not
> require restarting GDB with an extra option --debug-libraries.

I find debuginfo completely useless: I have never missed the ability to debug
system libraries and I find the current behavior (pages of useless messages) to
render gdb extremely inconvenient.

Most people debug their own code and the man pages provide enough information to
explain a failed library call by bad arguments. 
Urging - with PAGES of garbage - the user to install USELESS packages on EACH
invocation of a common utility (such as gdb) is ABSURD.
Comment 8 Jan Kratochvil 2008-03-10 08:18:57 EDT
I hope the current release being pushed for updates-testing and later updates
resolves the issue:

gdb-6.6-44.fc8 at http://koji.fedoraproject.org/koji/buildinfo?buildID=42325
/tmp/emptydir$ gdb /bin/ls
GNU gdb Red Hat Linux (6.6-44.fc8rh)
Copyright (C) 2006 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for details.
This GDB was configured as "x86_64-redhat-linux-gnu"...
(no debugging symbols found)
Using host libthread_db library "/lib64/libthread_db.so.1".
(gdb) run
Starting program: /bin/ls 
[Thread debugging using libthread_db enabled]

Program exited normally.
Missing separate debuginfos, use: debuginfo-install coreutils.x86_64
(gdb) quit

Libraries packages get listed for the locally built binaries but it is still a
single-line advice (and printed only on the executable change, it was printed
more often before).
The full former build-id messages still may get printed if you have installed a
matching debuginfo version but the separate .debug files still cannot be accessed.


(In reply to comment #7)
> Most people debug their own code and the man pages provide enough information
> to explain a failed library call by bad arguments.

I am curious how would you find the application has sent too long ORB identifier
to CORBA_ORB_string_to_object of ORBit2 which exceeded its internal limitation
and there is no such limit documented:
http://developer.gnome.org/doc/guides/corba/html/corba-module-orb-interface.html
One may consider it already a library bug but I find this type of improper
library use to be common enough to find the debuginfos useful.  (Another point
is that it may be faster to check the problem in the library sources than
reading the documentation.  YMMV.)
Comment 9 Fedora Update System 2008-03-10 08:20:02 EDT
gdb-6.6-44.fc8 has been submitted as an update for Fedora 8
Comment 10 Fedora Update System 2008-03-16 09:18:09 EDT
gdb-6.6-45.fc8 has been submitted as an update for Fedora 8
Comment 11 Fedora Update System 2008-03-16 15:28:37 EDT
gdb-6.6-45.fc8 has been pushed to the Fedora 8 stable repository.  If problems still persist, please make note of it in this bug report.
Comment 12 Sam Steingold 2008-03-16 22:03:07 EDT
with gdb-6.6-45.fc8, the problem is gone.
thanks.
Comment 13 Jan Kratochvil 2008-03-17 09:22:45 EDT
Thanks as your bugreport was right despite my initial complaints.

Note You need to log in before you can comment on or make changes to this bug.