Comment 27 for bug 1537125

Revision history for this message
Tom Jakubowski (tjakubowski) wrote :

I see that symtab compile error when building a systemtap module which uses userspace stack traces. A minimal example:

    probe process.syscall {
      print_usyms(ubacktrace());
    }

Yields the following results when building:

username@mysecrethost:~/stap$ sudo stap -v -c /bin/ls clock.stp
Pass 1: parsed user script and 111 library script(s) using 116848virt/44096res/6504shr/37808data kb, in 110usr/20sys/131real ms.
Pass 2: analyzed script: 1 probe(s), 5 function(s), 1 embed(s), 0 global(s) using 117640virt/45008res/6632shr/38600data kb, in 0usr/0sys/3real ms.
Pass 3: translated to C into "/tmp/stapxZlvnX/stap_ff2e2515c14e3a3266f293b9620dcd18_2586_src.c" using 117904virt/46404res/7584shr/38864data kb, in 10usr/70sys/80real ms.
In file included from /usr/share/systemtap/runtime/transport/control.c:14:0,
                 from /usr/share/systemtap/runtime/transport/transport.c:76,
                 from /usr/share/systemtap/runtime/linux/print.c:17,
                 from /usr/share/systemtap/runtime/print.c:17,
                 from /usr/share/systemtap/runtime/runtime_context.h:22,
                 from /tmp/stapxZlvnX/stap_ff2e2515c14e3a3266f293b9620dcd18_2586_src.c:120:
/usr/share/systemtap/runtime/transport/symbols.c: In function ‘_stp_module_update_self’:
/usr/share/systemtap/runtime/transport/symbols.c:243:44: error: ‘struct module’ has no member named ‘symtab’
    if (attr->address == (unsigned long) mod->symtab)
                                            ^
/usr/share/systemtap/runtime/transport/symbols.c:245:9: error: ‘struct module’ has no member named ‘num_symtab’
      mod->num_symtab * sizeof(mod->symtab[0]);
         ^
/usr/share/systemtap/runtime/transport/symbols.c:245:34: error: ‘struct module’ has no member named ‘symtab’
      mod->num_symtab * sizeof(mod->symtab[0]);
                                  ^
scripts/Makefile.build:258: recipe for target '/tmp/stapxZlvnX/stap_ff2e2515c14e3a3266f293b9620dcd18_2586_src.o' failed
make[1]: *** [/tmp/stapxZlvnX/stap_ff2e2515c14e3a3266f293b9620dcd18_2586_src.o] Error 1
Makefile:1403: recipe for target '_module_/tmp/stapxZlvnX' failed
make: *** [_module_/tmp/stapxZlvnX] Error 2
WARNING: kbuild exited with status: 2
Pass 4: compiled C into "stap_ff2e2515c14e3a3266f293b9620dcd18_2586.ko" in 440usr/100sys/882real ms.
Pass 4: compilation failed. [man error::pass4]
Tip: /usr/share/doc/systemtap/README.Debian should help you get started.