Segmentation Fault: Task died at uprobe probepoint
Srikar Dronamraju
srikar@linux.vnet.ibm.com
Mon Jun 14 12:55:00 GMT 2010
Hi,
>
> probe process("/home/gdhiman/tests/uprobe-test").begin
> {
> printf("uprobe-test begin!!\n")
> }
>
> probe process("/home/gdhiman/tests/uprobe-test").function("test_func")
> {
> printf("test_func called!\n");
> log($$parms);
> }
>
> The uprobe-test code is as follows:
>
> int test_func(int i)
> {
> printf("%d\n", i);
> return j;
^^^^^
Guess you meant "return i;"
> }
>
> int main()
> {
> int i;
> i = test_func(5);
> return 0;
> }
>
>
> Then I ran the script as root using stap -v test.stp; it is compiled
> and inserted successfully. I see the following message if I do dmesg:
> [ 1694.148460] stap_9736f2321b446f9fc03126194f89aac2_1643: systemtap:
> 1.2/0.131, base: ffffffffa0010000, memory
> 136data/29text/10ctx/13net/34alloc kb, probes: 2
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?
> However, when i actually run uprobe-test, although both the probes
> fire successfully, the task generates a segmentation fault and dies on
> the 'test_func' probe. I see the following message on doing dmesg:
> [ 1709.650827] Task died at uprobe probepoint: pid/tgid = 3934/3934,
> probepoint = 0x400517
This means that the process died before the uprobe operation completed.
i.e either it was still running the handler or singlestep operation
hadnt occurred.
- Did you try using the core with gdb? Does address in bt and
disassemble output of test_func show the same address?
I am not able to see this problem. (I am running on a different kernel)
--
Regards
Srikar
More information about the Systemtap
mailing list