This is the mail archive of the systemtap@sourceware.org mailing list for the systemtap project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Segmentation Fault: Task died at uprobe probepoint


On Tue, Jun 15, 2010 at 2:11 AM, Mark Wielaard <mjw@redhat.com> wrote:
> On Mon, 2010-06-14 at 17:43 -0700, Gaurav Dhiman wrote:
>> > Looks to me that you are using a pretty recent systemtap with a pretty
>> > old elfutils. Is is possible to try building systemtap with a later
>> > version of elfutils?
>> >
>> I have version 0.13a installed on my system. Is that too old? I can
>> give it a shot with latter versions.
>
> That is pretty old. Some versions before 0.142 had bugs that could
> result in us misplacing probes. But that isn't the issue you are seeing
> here, since even if the probe was misplaced it should still not crash
> the binary you are inspecting.
>
> If possible, please do try using elfutils-0.142+ (latest is 0.147). Even
> though that shouldn't matter in your case.

I have now upgraded to elfutils 0.143, and now the SIGSEGV is not
happening anymore. But now it gives a Trace/breakpoint trap instead
and the probe is removed just like it was happening before. The binary
now likes like this:

0000000000400550 <test_func>:
  400550:       53                      push   %rbx
  400551:       89 fa                   mov    %edi,%edx
  400553:       89 fb                   mov    %edi,%ebx
  400555:       be 7c 06 40 00          mov    $0x40067c,%esi
  40055a:       bf 01 00 00 00          mov    $0x1,%edi
  40055f:       31 c0                   xor    %eax,%eax
  400561:       e8 da fe ff ff          callq  400440 <__printf_chk@plt>
  400566:       89 d8                   mov    %ebx,%eax
  400568:       5b                      pop    %rbx
  400569:       c3                      retq
  40056a:       66 0f 1f 44 00 00       nopw   0x0(%rax,%rax,1)

And the systemtap debug messages that I see now are:

stap_uprobe_change_plus:67: +uprobe spec 0 idx 0 process
uprobe-test[13414] addr 0000000000400550 pp
process("/home/gdhiman/tests/uprobe-test").function("test_func@/home/gdhiman/tests/uprobe-test.c:3")
stap_uprobe_change_minus:220: -uprobe spec 0 idx 0 process
uprobe-test[13414] reloc 0000000000400550 pp
process("/home/gdhiman/tests/uprobe-test").function("test_func@/home/gdhiman/tests/uprobe-test.c:3")


>> > I am not able to see this problem. (I am running on a different kernel)
>> >
>>
>> Which versions (systemtap and kernel) are you using? I might give them
>> a shot as well.
>
> I was also unable to replicate. Using systemtap 1.2 or current git tip.
> elfutils 0.147. kernel 2.6.32-33.el6.x86_64 or 2.6.33.5-112.fc13.i686
>

I am using kernel 2.6.29, which has the corresponding utrace patch.
Can it be the reason that the older version is not compatible with the
latest version of systemtap? Another thing that I forgot to mention in
my previous emails is that I am running this kernel and systemtap
inside a Xen DomU. Does that make a difference?

Thanks,
-Gaurav


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]