From: Brendan Miller <catphive@catphive.net>
To: gdb@sourceware.org
Subject: problem remote debugging
Date: Tue, 24 Feb 2009 00:59:00 -0000 [thread overview]
Message-ID: <ef38762f0902231659s1f0ac09bx6c590a8797b7b131@mail.gmail.com> (raw)
I'm having a problem with remote debugging where when debugging
locally I will launch fine, but when remotely debugging my program
will fail to open a certain text file, then segfault.
Both the host and client are running x86 RHEL4. The gdb version is
6.3.0.0-1.153.el4rh.
In the example below, I am trying to remote debug a fairly complicated
service that has it's own user "a_user".
On the remote machine I start gdbserver with:
sudo -u a_user gdbserver host:4000 my_binary
On the local machine I run:
gdb my_binary
Then within gdb I type:
target remote my_remote_machine:4000
run
Then I get the "failed to open file error" followed by a segfault.
On the other hand if I run this on the remote machine:
sudo -u a_user gdb my_binary
run
everything is fine.
Is one of my steps for remote debugging wrong? Would permissions be
different under remote debugging for some reason, and that would
explain why I can't open that file under remote debugging?
The service I"m trying to debug is heavily multithreaded, if that
makes a difference.
next reply other threads:[~2009-02-24 0:59 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-02-24 0:59 Brendan Miller [this message]
2009-02-24 2:25 ` teawater
2009-02-24 2:33 ` Daniel Jacobowitz
2009-02-24 17:01 ` Brendan Miller
2009-02-24 17:08 ` Daniel Jacobowitz
2009-02-24 19:52 ` Brendan Miller
2009-02-25 6:07 ` Paul Pluzhnikov
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=ef38762f0902231659s1f0ac09bx6c590a8797b7b131@mail.gmail.com \
--to=catphive@catphive.net \
--cc=gdb@sourceware.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox