This is the mail archive of the
systemtap@sourceware.org
mailing list for the systemtap project.
Re: undefined system symbol error
- From: Josh Stone <jistone at redhat dot com>
- To: systemtap at sourceware dot org
- Date: Mon, 9 May 2016 09:40:27 -0700
- Subject: Re: undefined system symbol error
- Authentication-results: sourceware.org; auth=none
- References: <CAHBSL5BBhHnZgX=nu_+FCA5CrsYGKVM6Aqi9+rNZxBps0s6YQQ at mail dot gmail dot com>
On 05/09/2016 04:32 AM, åéå wrote:
> After install systemtap, i run a script. And i get some error. I can't
> ensure i had upload all the info you need, if you need more info, just let
> me know.
This looks like PR16884. Even though you're not probing tracepoints
directly, we use them internally for process tracking to enable those
backtrace functions. The tracepoint API changed in kernel 3.15, and we
caught up to those changes in systemtap 2.5.
https://sourceware.org/bugzilla/show_bug.cgi?id=16844
You can either file a bug with Ubuntu to backport those fixes, or
compile a newer release of systemtap yourself.
> **The script:**
>
> global s;
> global quit = 0;
> probe timer.profile {
> if (pid() == target()) {
> if (quit) {
> foreach (i in s-) {
> print_ustack(i);
> printf("\t%d\n", @count(s[i]));
> }
> exit()
> } else {
> s[ubacktrace()] <<< 1;
> }
> }
> }
> probe timer.s(20) {
> quit = 1
> }
>
>
>
> **Error Info is :**
>
> WARNING: "__tracepoint_sched_process_fork"
> [/tmp/stapH5cHsd/stap_958d0ff0e571c9357f1e193511d8baa3_269311.ko]undefined!
> WARNING: "__tracepoint_sys_exit"
> [/tmp/stapH5cHsd/stap_958d0ff0e571c9357f1e193511d8baa3_269311.ko]
> undefined!
> WARNING: "__tracepoint_sys_enter"
> [/tmp/stapH5cHsd/stap_958d0ff0e571c9357f1e193511d8baa3_269311.ko]
> undefined!
> WARNING: "__tracepoint_sched_process_exec"
> [/tmp/stapH5cHsd/stap_958d0ff0e571c9357f1e193511d8baa3_269311.ko]
> undefined!
> WARNING: "__tracepoint_sched_process_exit"
> [/tmp/stapH5cHsd/stap_958d0ff0e571c9357f1e193511d8baa3_269311.ko]
> undefined!
> ERROR: Couldn't insert module
> '/tmp/stapH5cHsd/stap_958d0ff0e571c9357f1e193511d8baa3_269311.ko':
> Unknown symbol in module
> WARNING: /usr/bin/staprun exited with status: 1
> Pass 5: run failed. [man error::pass5]
> Tip: /usr/share/doc/systemtap/README.Debian should help you get started.
>
> **Some info of my env:**
>
> # cat /proc/version
> Linux version 3.16.0-70-generic (buildd@lgw01-01) (gcc version
> 4.8.2 (Ubuntu 4.8.2-19ubuntu1) ) #90~14.04.1-Ubuntu SMP Wed Apr 6
> 22:56:34 UTC 2016
>
> # stap -V
> Systemtap translator/driver (version 2.3/0.158, Debian version
> 2.3-1ubuntu1.4 (trusty))
> Copyright (C) 2005-2013 Red Hat, Inc. and others
> This is free software; see the source for copying conditions.
> enabled features: AVAHI LIBSQLITE3 NSS TR1_UNORDERED_MAP NLS
>
> # dpkg --list | grep `uname -r`
>
> ii linux-headers-3.16.0-70-generic
> 3.16.0-70.90~14.04.1 amd64 Linux
> kernel headers for version 3.16.0 on 64 bit x86 SMP
> ii linux-image-3.16.0-70-generic
> 3.16.0-70.90~14.04.1 amd64 Linux
> kernel image for version 3.16.0 on 64 bit x86 SMP
> ii linux-image-3.16.0-70-generic-dbgsym
> 3.16.0-70.90~14.04.1 amd64 Linux
> kernel debug image for version 3.16.0 on 64 bit x86 SMP
> ii linux-image-extra-3.16.0-70-generic
> 3.16.0-70.90~14.04.1 amd64 Linux
> kernel extra modules for version 3.16.0 on 64 bit x86 SMP
> ii linux-signed-image-3.16.0-70-generic
> 3.16.0-70.90~14.04.1 amd64
> Signed kernel image generic
>
>
> # sudo cat /proc/kallsyms | grep __tracepoint_sched_process_fork
> ffffffff81cecbe0 D __tracepoint_sched_process_fork
Yes, the tracepoints symbols do exist, but they lack EXPORT_SYMBOL, so
modules are not able to directly access them.
> Think you for pay attention to my puzzled.
>