Open s914211 opened 9 years ago
same issue, any update for this?....
Noupdate. Can u send me a copy of /proc/kallsyms?
Thanks On 11 Aug 2015 07:05, "raygush" notifications@github.com wrote:
same issue, any update for this?....
— Reply to this email directly or view it on GitHub https://github.com/dtrace4linux/linux/issues/113#issuecomment-129718607.
Facing same issue in ubuntu 13.04(kernel version: 3.8.0.19-generic)
Same here with kernel-4.1.10-200.fc22.x86_64 I'll send over the /proc/kallsyms
Same here.
Might that be related to me trying to install dtrace
in a Docker container on a Mac OS X host?
did you pick up the latest release of dtrace?
On 15 November 2015 at 17:12, Volkan Özçelik notifications@github.com wrote:
Same here.
Might that be related to me trying to install dtrace in a Docker container on a Mac OS X host?
— Reply to this email directly or view it on GitHub https://github.com/dtrace4linux/linux/issues/113#issuecomment-156831402.
Thanks, the new version compiles fine for me now on 4.2.5-300.fc23.x86_64
Similar issue with Archlinux 4.2.5-1 and 4.3.1. Using commit fbd8847
same issue: Ubuntu 4.2.0-18-generic Distributor ID: Ubuntu Description: Ubuntu 15.10 Release: 15.10 Codename: wily
getfree@LifeBookC:~/PycharmProjects/dtrace4linux/linux$ tools/get-deps.pl [sudo] password for getfree: Reading package lists... Done Building dependency tree Reading state information... Done bison is already the newest version. flex is already the newest version. make is already the newest version. 0 upgraded, 0 newly installed, 0 to remove and 3 not upgraded. Reading package lists... Done Building dependency tree Reading state information... Done libelf-dev is already the newest version. 0 upgraded, 0 newly installed, 0 to remove and 3 not upgraded. Reading package lists... Done Building dependency tree Reading state information... Done libc6-dev is already the newest version. 0 upgraded, 0 newly installed, 0 to remove and 3 not upgraded. Reading package lists... Done Building dependency tree Reading state information... Done Note, selecting 'libc6-dev' instead of 'libc-dev' binutils-dev is already the newest version. elfutils is already the newest version. libc6-dev is already the newest version. libelf-dev is already the newest version. libiberty-dev is already the newest version. zlib1g-dev is already the newest version. linux-headers-4.2.0-18-generic is already the newest version. linux-libc-dev is already the newest version. The following packages will be REMOVED: libdw-dev The following NEW packages will be installed: libdwarf-dev 0 upgraded, 1 newly installed, 1 to remove and 3 not upgraded. Need to get 0 B/693 kB of archives. After this operation, 361 kB of additional disk space will be used. Do you want to continue? [Y/n] y (Reading database ... 416943 files and directories currently installed.) Removing libdw-dev:i386 (0.163-4ubuntu1) ... Selecting previously unselected package libdwarf-dev. (Reading database ... 416935 files and directories currently installed.) Preparing to unpack .../libdwarf-dev_20120410-2_i386.deb ... Unpacking libdwarf-dev (20120410-2) ... Setting up libdwarf-dev (20120410-2) ... Reading package lists... Done Building dependency tree Reading state information... Done g++-multilib is already the newest version. 0 upgraded, 0 newly installed, 0 to remove and 3 not upgraded.
make all
BUILD_DIR=build-4.2.0-18-generic \
tools/mkdriver.pl driver-kmem ; \
tools/build.pl build-4.2.0-18-generic uname -m
Executing: /home/getfree/PycharmProjects/dtrace4linux/linux/tools/make-me
make -C /lib/modules/4.2.0-18-generic/build M=/home/getfree/PycharmProjects/dtrace4linux/linux/build-4.2.0-18-generic/driver-kmem
Building modules, stage 2.
MODPOST 1 modules
gcc -o build-4.2.0-18-generic/kcore tools/kcore.c
tools/check_dep.pl
tools/mkport.pl
/usr/bin/ld: cannot find -ldw
collect2: error: ld returned 1 exit status
Failed to find stub_execve
Use of uninitialized value $old_rsp in concatenation (.) or string at tools/mkport.pl line 144.
old_rsp=
We cannot find old_rsp or per_cpu__old_rsp in your kernel.
Additionally, it looks like /proc/kcore is broken on your kernel,
meaning we cannot poke to find this variable, which helps identify
kernel thread offsets.
FATAL ERROR: cannot find old_rsp
FATAL ERROR: build.pl aborting
makefile:67: recipe for target 'all' failed
make: *\ [all] Error 25
Looks to me like libdw is missing in the output - so "stuff" isnt going to work. The get-deps.pl script is a good start for deps, but maybe I missed one. Can you install that?
On 2 December 2015 at 00:59, bitfree notifications@github.com wrote:
same issue: Ubuntu 4.2.0-18-generic Distributor ID: Ubuntu Description: Ubuntu 15.10 Release: 15.10 Codename: wily
getfree@LifeBookC:~/PycharmProjects/dtrace4linux/linux$ tools/get-deps.pl [sudo] password for getfree: Reading package lists... Done Building dependency tree Reading state information... Done bison is already the newest version. flex is already the newest version. make is already the newest version. 0 upgraded, 0 newly installed, 0 to remove and 3 not upgraded. Reading package lists... Done Building dependency tree Reading state information... Done libelf-dev is already the newest version. 0 upgraded, 0 newly installed, 0 to remove and 3 not upgraded. Reading package lists... Done Building dependency tree Reading state information... Done libc6-dev is already the newest version. 0 upgraded, 0 newly installed, 0 to remove and 3 not upgraded. Reading package lists... Done Building dependency tree Reading state information... Done Note, selecting 'libc6-dev' instead of 'libc-dev' binutils-dev is already the newest version. elfutils is already the newest version. libc6-dev is already the newest version. libelf-dev is already the newest version. libiberty-dev is already the newest version. zlib1g-dev is already the newest version. linux-headers-4.2.0-18-generic is already the newest version. linux-libc-dev is already the newest version. The following packages will be REMOVED: libdw-dev The following NEW packages will be installed: libdwarf-dev 0 upgraded, 1 newly installed, 1 to remove and 3 not upgraded. Need to get 0 B/693 kB of archives. After this operation, 361 kB of additional disk space will be used. Do you want to continue? [Y/n] y (Reading database ... 416943 files and directories currently installed.) Removing libdw-dev:i386 (0.163-4ubuntu1) ... Selecting previously unselected package libdwarf-dev. (Reading database ... 416935 files and directories currently installed.) Preparing to unpack .../libdwarf-dev_20120410-2_i386.deb ... Unpacking libdwarf-dev (20120410-2) ... Setting up libdwarf-dev (20120410-2) ... Reading package lists... Done Building dependency tree Reading state information... Done g++-multilib is already the newest version. 0 upgraded, 0 newly installed, 0 to remove and 3 not upgraded.
make all BUILD_DIR=build-4.2.0-18-generic \ tools/mkdriver.pl driver-kmem ; \ tools/build.pl build-4.2.0-18-generic uname -m Executing: /home/getfree/PycharmProjects/dtrace4linux/linux/tools/make-me make -C /lib/modules/4.2.0-18-generic/build M=/home/getfree/PycharmProjects/dtrace4linux/linux/build-4.2.0-18-generic/driver-kmem Building modules, stage 2. MODPOST 1 modules gcc -o build-4.2.0-18-generic/kcore tools/kcore.c tools/check_dep.pl tools/mkport.pl /usr/bin/ld: cannot find -ldw collect2: error: ld returned 1 exit status Failed to find stub_execve Use of uninitialized value $old_rsp in concatenation (.) or string at tools/mkport.pl line 144. old_rsp= We cannot find old_rsp or per_cpu__old_rsp in your kernel. Additionally, it looks like /proc/kcore is broken on your kernel, meaning we cannot poke to find this variable, which helps identify kernel thread offsets. FATAL ERROR: cannot find old_rsp FATAL ERROR: build.pl aborting makefile:67: recipe for target 'all' failed make: *\ [all] Error 25
— Reply to this email directly or view it on GitHub https://github.com/dtrace4linux/linux/issues/113#issuecomment-161145423.
getfree@LifeBookC:~/down/dtrace4linux$ sudo apt-get install libdw-dev Reading package lists... Done Building dependency tree Reading state information... Done The following packages will be REMOVED: libdwarf-dev The following NEW packages will be installed: libdw-dev 0 upgraded, 1 newly installed, 1 to remove and 3 not upgraded. Need to get 0 B/176 kB of archives. After this operation, 361 kB disk space will be freed. Do you want to continue? [Y/n]y
getfree@LifeBookC:~/down/dtrace4linux$ make all
BUILD_DIR=build-4.2.0-18-generic \
tools/mkdriver.pl driver-kmem ; \
tools/build.pl build-4.2.0-18-generic uname -m
Executing: /home/getfree/Downloads/dtrace4linux/tools/make-me
make -C /lib/modules/4.2.0-18-generic/build M=/home/getfree/Downloads/dtrace4linux/build-4.2.0-18-generic/driver-kmem
Building modules, stage 2.
MODPOST 1 modules
gcc -o build-4.2.0-18-generic/kcore tools/kcore.c
tools/check_dep.pl
tools/mkport.pl
Failed to find stub_execve
Use of uninitialized value $old_rsp in concatenation (.) or string at tools/mkport.pl line 144.
old_rsp=
We cannot find old_rsp or per_cpu__old_rsp in your kernel.
Additionally, it looks like /proc/kcore is broken on your kernel,
meaning we cannot poke to find this variable, which helps identify
kernel thread offsets.
FATAL ERROR: cannot find old_rsp
FATAL ERROR: build.pl aborting
makefile:67: recipe for target 'all' failed
make: *\ [all] Error 25
same issue ?
getfree@LifeBookC:~/down/dtrace4linux$ sudo grep old_rsp /proc/kallsyms getfree@LifeBookC:~/down/dtrace4linux$
any news here?
Did you download the latest dtrace release? On 10 Dec 2015 08:56, "Marcus Alvares" notifications@github.com wrote:
any news here?
— Reply to this email directly or view it on GitHub https://github.com/dtrace4linux/linux/issues/113#issuecomment-163537000.
yes. here I am running 3.16.0-38-generic 14.04.1-Ubuntu SMP
of course. I downloaded latest..
2015-12-10 21:07 GMT+09:00 dtrace4linux notifications@github.com:
Did you download the latest dtrace release? On 10 Dec 2015 08:56, "Marcus Alvares" notifications@github.com wrote:
any news here?
— Reply to this email directly or view it on GitHub <https://github.com/dtrace4linux/linux/issues/113#issuecomment-163537000 .
— Reply to this email directly or view it on GitHub https://github.com/dtrace4linux/linux/issues/113#issuecomment-163592097.
mailto : bitfree@gmail.com mobile : 82-10-6449-2031
there are no problems in 3.x kernel there is no problem old_rsp in 64bit linux machine only in 32bit machines
same issue: Ubuntu 4.2.0-18-generic Distributor ID: Ubuntu Description: Ubuntu 15.10 Release: 15.10 Codename: wily
2015-12-10 21:51 GMT+09:00 Marcus Alvares notifications@github.com:
yes. here I am running 3.16.0-38-generic #52 https://github.com/dtrace4linux/linux/issues/52~14.04.1-Ubuntu SMP
— Reply to this email directly or view it on GitHub https://github.com/dtrace4linux/linux/issues/113#issuecomment-163602147.
mailto : bitfree@gmail.com mobile : 82-10-6449-2031
Well, they renamed _oldrsp into _rspscratch at kernel version 4.2. But then removed _rspscratch at version 4.20 (this patch). So, as for kernels 4.20+ it fails to get rsp. We need to get rsp value somehow according to this patch.
I have the same problem on Kernel 5.8.16_1
Well, they renamed old_rsp into rsp_scratch at kernel version 4.2. But then removed rsp_scratch at version 4.20 (this patch). So, as for kernels 4.20+ it fails to get rsp. We need to get rsp value somehow according to this patch.
I can get the symbol cpu_tss_rw
by get_symbol("cpu_tss_rw")
.
TSS_sp2 is the offset to sp2
member of struct x86_hw_tss
of cpu_tss_rw
from my understanding.
So, I guess that adding some lines like the following will work, but I dont' know how to get the offset to sp2
in perl.
if (!$old_rsp) {
$old_rsp = get_symbol("rsp_scratch");
}
sp2
>;
I have the same problem on Kernel 5.4.0, Ubuntu 20.04.1
Facing the same issue on 5.15.12-arch1-1. Any temporary fix?
Same problem on Kernel 5.10.0, Debian 11
I have the same problem on Linux version 5.15.0-105-generic (buildd@lcy02-amd64-007) (gcc (Ubuntu 11.4.0-1ubuntu1~22.04) 11.4.0, GNU ld (GNU Binutils for Ubuntu) 2.38) #115-Ubuntu SMP Mon Apr 15 09:52:04 UTC 2024
Hello! I try a lot to use Dtrace for my project, but this time I found another error. Please give me some advice to solve these two problems. Thank you!
Below is the error message:
BUILD_DIR=build-3.16.0-38-generic \ tools/mkdriver.pl driver-kmem ; \ tools/build.pl build-3.16.0-38-generic
uname -m
symlink ../../driver-kmem/Makefile build-3.16.0-38-generic/driver-kmem/Makefile symlink ../../driver-kmem/dtrace_kmem.c build-3.16.0-38-generic/driver-kmem/dtrace_kmem.c Executing: /home/tommy/dtrace-20150521/tools/make-me make -C /lib/modules/3.16.0-38-generic/build M=/home/tommy/dtrace-20150521/build-3.16.0-38-generic/driver-kmem LD /home/tommy/dtrace-20150521/build-3.16.0-38-generic/driver-kmem/built-in.o CC [M] /home/tommy/dtrace-20150521/build-3.16.0-38-generic/driver-kmem/dtrace_kmem.o /home/tommy/dtrace-20150521/build-3.16.0-38-generic/driver-kmem/dtrace_kmem.c: In function 'kmem_read': /home/tommy/dtrace-20150521/build-3.16.0-38-generic/driver-kmem/dtrace_kmem.c:44:24: warning: cast to pointer from integer of different size [-Wint-to-pointer-cast] n = copy_touser(buf, (char ) off2, len); ^ Building modules, stage 2. MODPOST 1 modules CC /home/tommy/dtrace-20150521/build-3.16.0-38-generic/driver-kmem/dtrace_kmem.mod.o LD [M] /home/tommy/dtrace-20150521/build-3.16.0-38-generic/driver-kmem/dtrace_kmem.ko gcc -o build-3.16.0-38-generic/kcore tools/kcore.c tools/check_dep.pl tools/mkport.pl /usr/bin/ld: cannot find -ldw collect2: error: ld returned 1 exit status Failed to find stub_execve old_rsp= We cannot find old_rsp or per_cpu__old_rsp in your kernel. Additionally, it looks like /proc/kcore is broken on your kernel, meaning we cannot poke to find this variable, which helps identify kernel thread offsets. FATAL ERROR: cannot find oldrsp FATAL ERROR: build.pl aborting make: ** [all] Error 25