* pthread_db innitializing error
@ 2003-06-25 17:01 nak26
2003-06-25 18:30 ` Daniel Jacobowitz
0 siblings, 1 reply; 6+ messages in thread
From: nak26 @ 2003-06-25 17:01 UTC (permalink / raw)
To: gdb
Hi:
I am fighting problems I have when trying to remotely debug multithreaded
applications.
The host machine's solib-absolute-prefix is messed up, so when I start I set
the solib search path to look for libraries at the right places (it was
looking at /lib/i686 instead of just in /lib). Then after hitting a breakpoint
I need to issue shared to load the libararies.
At this point on the target terminal I see this (the application is a
multithreaded toy example):
[localhost ~/src/c/threads]$ ~/.local/src/gdb-5.3/gdb/gdbserver/gdbserver
:7000 hello_world_thread
Process hello_world_thread created; pid = 2486
Remote debugging from host 192.168.66.59
gdb: error initializing thread_db library.
gdb: error initializing thread_db library.
gdb: error initializing thread_db library.
Anybody with ideas why I am getting the error?
Both host and target are IA32 RedHat 8.0s.
Thanks,
Nik
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: pthread_db innitializing error
2003-06-25 17:01 pthread_db innitializing error nak26
@ 2003-06-25 18:30 ` Daniel Jacobowitz
0 siblings, 0 replies; 6+ messages in thread
From: Daniel Jacobowitz @ 2003-06-25 18:30 UTC (permalink / raw)
To: nak26; +Cc: gdb
On Wed, Jun 25, 2003 at 12:38:44PM -0400, nak26 wrote:
> Hi:
>
> I am fighting problems I have when trying to remotely debug multithreaded
> applications.
>
> The host machine's solib-absolute-prefix is messed up, so when I start I set
> the solib search path to look for libraries at the right places (it was
> looking at /lib/i686 instead of just in /lib). Then after hitting a breakpoint
> I need to issue shared to load the libararies.
Eh? It sounds like you're not using the right libraries at all.
solib-absolute-prefix should point to a copy of the target filesystem
layout - the target's versions of libraries. It shouldn't search /lib
at all.
> At this point on the target terminal I see this (the application is a
> multithreaded toy example):
>
> [localhost ~/src/c/threads]$ ~/.local/src/gdb-5.3/gdb/gdbserver/gdbserver
> :7000 hello_world_thread
> Process hello_world_thread created; pid = 2486
> Remote debugging from host 192.168.66.59
> gdb: error initializing thread_db library.
> gdb: error initializing thread_db library.
> gdb: error initializing thread_db library.
>
> Anybody with ideas why I am getting the error?
>
> Both host and target are IA32 RedHat 8.0s.
Probably symbol resolution is not working; most likely because you have
the wrong libpthread on the host.
--
Daniel Jacobowitz
MontaVista Software Debian GNU/Linux Developer
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: pthread_db innitializing error
2003-06-26 14:34 nak26
@ 2003-06-26 14:44 ` Daniel Jacobowitz
0 siblings, 0 replies; 6+ messages in thread
From: Daniel Jacobowitz @ 2003-06-26 14:44 UTC (permalink / raw)
To: nak26; +Cc: gdb
On Thu, Jun 26, 2003 at 10:34:37AM -0400, nak26 wrote:
> >
> >Is GDB on the host finding the _host's_ libpthread, or the _target's_
> >libpthread copied to the host?
> >
> >It must be the latter if you want it to work.
> >
>
> It finds the latter, but errors when trying to load it automatically.
> I guess the warning that comes out after the connection is made points to
> why this is happening.
>
> ----------------------------------
> GDB console's output
> ----------------------------------
> (gdb) b main
> Breakpoint 1 at 0x82a2cc2: file ../cp/tlpcp.cxx, line 332.
> (gdb) target remote 192.168.139.14:7000
> Remote debugging using 192.168.139.14:7000
> 0x40001390 in ?? ()
> warning: Unable to find dynamic linker breakpoint function.
> GDB will be unable to debug shared library initializers
> and track explicitly loaded dynamic code.
> (gdb) c
> Continuing.
> Error while mapping shared library sections:
> /lib/libnsl.so.1: No such file or directory.
> Error while mapping shared library sections:
> /lib/librt.so.1: No such file or directory.
> Error while mapping shared library sections:
> /lib/libpthread.so.0: No such file or directory.
> Error while mapping shared library sections:
> /opt/intel/mkl/lib/32/libmkl_p4.so: No such file or directory.
> Error while mapping shared library sections:
> /opt/intel/mkl/lib/32/libguide.so: No such file or directory.
> Error while mapping shared library sections:
> /usr/lib/libstdc++.so.5: No such file or directory.
> Error while mapping shared library sections:
> /lib/libm.so.6: No such file or directory.
> Error while mapping shared library sections:
> /lib/libgcc_s.so.1: No such file or directory.
> Error while mapping shared library sections:
> /lib/libc.so.6: No such file or directory.
> Error while mapping shared library sections:
> /lib/ld-linux.so.2: No such file or directory.
> --------------------------------------------
> GDBSERVER's console output
> --------------------------------------------
> Process tlpSim created; pid = 2884
> Remote debugging from host 192.168.66.59
> gdb: Unable to set global thread event mask: generic error
> gdb: Unable to set global thread event mask: generic error
> gdb: Unable to set global thread event mask: generic error
> gdb: Unable to set global thread event mask: generic error
> gdb: Unable to set global thread event mask: generic error
> gdb: Unable to set global thread event mask: generic error
> gdb: Unable to set global thread event mask: generic error
> gdb: Unable to set global thread event mask: generic error
>
> Is this a (_remote_) linker issue or gdbserver issue or (_local_)
> gdb issue?
> Furthermore, does gdb load the shared libraries from the remote
> machine over the network or they need to reside locally?
They need to reside locally, and this is a local gdb issue.
From the error message above, GDB is not finding the library -
otherwise you wouldn't get "No such file or directory". Please take
another look at the documentation for solib-absolute-prefix.
--
Daniel Jacobowitz
MontaVista Software Debian GNU/Linux Developer
^ permalink raw reply [flat|nested] 6+ messages in thread
* RE: pthread_db innitializing error
@ 2003-06-26 14:34 nak26
2003-06-26 14:44 ` Daniel Jacobowitz
0 siblings, 1 reply; 6+ messages in thread
From: nak26 @ 2003-06-26 14:34 UTC (permalink / raw)
To: Daniel Jacobowitz; +Cc: gdb
>
>Is GDB on the host finding the _host's_ libpthread, or the _target's_
>libpthread copied to the host?
>
>It must be the latter if you want it to work.
>
It finds the latter, but errors when trying to load it automatically.
I guess the warning that comes out after the connection is made points to
why this is happening.
----------------------------------
GDB console's output
----------------------------------
(gdb) b main
Breakpoint 1 at 0x82a2cc2: file ../cp/tlpcp.cxx, line 332.
(gdb) target remote 192.168.139.14:7000
Remote debugging using 192.168.139.14:7000
0x40001390 in ?? ()
warning: Unable to find dynamic linker breakpoint function.
GDB will be unable to debug shared library initializers
and track explicitly loaded dynamic code.
(gdb) c
Continuing.
Error while mapping shared library sections:
/lib/libnsl.so.1: No such file or directory.
Error while mapping shared library sections:
/lib/librt.so.1: No such file or directory.
Error while mapping shared library sections:
/lib/libpthread.so.0: No such file or directory.
Error while mapping shared library sections:
/opt/intel/mkl/lib/32/libmkl_p4.so: No such file or directory.
Error while mapping shared library sections:
/opt/intel/mkl/lib/32/libguide.so: No such file or directory.
Error while mapping shared library sections:
/usr/lib/libstdc++.so.5: No such file or directory.
Error while mapping shared library sections:
/lib/libm.so.6: No such file or directory.
Error while mapping shared library sections:
/lib/libgcc_s.so.1: No such file or directory.
Error while mapping shared library sections:
/lib/libc.so.6: No such file or directory.
Error while mapping shared library sections:
/lib/ld-linux.so.2: No such file or directory.
--------------------------------------------
GDBSERVER's console output
--------------------------------------------
Process tlpSim created; pid = 2884
Remote debugging from host 192.168.66.59
gdb: Unable to set global thread event mask: generic error
gdb: Unable to set global thread event mask: generic error
gdb: Unable to set global thread event mask: generic error
gdb: Unable to set global thread event mask: generic error
gdb: Unable to set global thread event mask: generic error
gdb: Unable to set global thread event mask: generic error
gdb: Unable to set global thread event mask: generic error
gdb: Unable to set global thread event mask: generic error
Is this a (_remote_) linker issue or gdbserver issue or (_local_)
gdb issue?
Furthermore, does gdb load the shared libraries from the remote
machine over the network or they need to reside locally?
Thanks,
--Nik
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: pthread_db innitializing error
2003-06-25 18:31 nak26
@ 2003-06-26 4:58 ` Daniel Jacobowitz
0 siblings, 0 replies; 6+ messages in thread
From: Daniel Jacobowitz @ 2003-06-26 4:58 UTC (permalink / raw)
To: nak26; +Cc: gdb
On Wed, Jun 25, 2003 at 01:42:18PM -0400, nak26 wrote:
> >
> >Eh? It sounds like you're not using the right libraries at all.
> >solib-absolute-prefix should point to a copy of the target filesystem
> >layout - the target's versions of libraries. It shouldn't search /lib
> >at all.
> >
>
> I meant to say solib-search-path...
>
> >
> >Probably symbol resolution is not working; most likely because you have
> >the wrong libpthread on the host.
> >
>
> What do you mean by "you have the wrong libpthread on the host"?
> How can I doctor this?
Is GDB on the host finding the _host's_ libpthread, or the _target's_
libpthread copied to the host?
It must be the latter if you want it to work.
--
Daniel Jacobowitz
MontaVista Software Debian GNU/Linux Developer
^ permalink raw reply [flat|nested] 6+ messages in thread
* RE: pthread_db innitializing error
@ 2003-06-25 18:31 nak26
2003-06-26 4:58 ` Daniel Jacobowitz
0 siblings, 1 reply; 6+ messages in thread
From: nak26 @ 2003-06-25 18:31 UTC (permalink / raw)
To: Daniel Jacobowitz; +Cc: gdb
>
>Eh? It sounds like you're not using the right libraries at all.
>solib-absolute-prefix should point to a copy of the target filesystem
>layout - the target's versions of libraries. It shouldn't search /lib
>at all.
>
I meant to say solib-search-path...
>
>Probably symbol resolution is not working; most likely because you have
>the wrong libpthread on the host.
>
What do you mean by "you have the wrong libpthread on the host"?
How can I doctor this?
Thanks,
--Nik
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2003-06-26 14:44 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-06-25 17:01 pthread_db innitializing error nak26
2003-06-25 18:30 ` Daniel Jacobowitz
2003-06-25 18:31 nak26
2003-06-26 4:58 ` Daniel Jacobowitz
2003-06-26 14:34 nak26
2003-06-26 14:44 ` Daniel Jacobowitz
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).