Install DTrace for Linux その1

概要

102回のKernel読書会で見て面白そうと思ったのでLinux環境にて準備。
ちなみに失敗しています。。とりあえずメモ。

インストール

環境はCentOS系。
ダウンロードしたアーカイブを解凍し、READMEを確認すると下記の記述。

Installation
============

Very simple:

$ make all
$ make install
$ make load (need to be root or have sudo access)

一瞬で終わりそうだが、このファイルの末尾に下記の記述有り。

For AS4/Centos
==============
yum install elfutils-libelf-devel

これをインストールしておかないとmakeのしょっぱなでコケる。
さて、インストール後に $ make clean した後で Very simple な手順を実行するのであるが、

(中略)
symlink ../../driver/intr_x86-64.S build-2.6.18.8-linode19/driver/intr_x86-64.S
Executing: /hoge/dtrace-20091010/tools/make-me
make -C /usr/src/linux/ M=/hoge/dtrace-20091010/build-2.6.18.8-linode19/driver
make: *** /usr/src/linux/: No such file or directory. Stop.
make[1]: *** [all0] Error 2
tools/bug.sh
======================
== Sorry - but dtrace failed to compile on your system.
== Please forward the following file to:
==
== file: /tmp/dtrace-bug.21540
== mail: dtrace@crisp.demon.co.uk
==
== and the information provided will be used to help
== enhance the tool and fix the underlying issue.
==
== Latest news and blog updates on dtrace available here. Please
== check for latest problem reports.
==
== http://www.crisp.demon.co.uk/blog/
==
== Latest downloads available from here:
==
== ftp://crisp.dynalias.com/pub/release/website/dtrace
== ======================
(generating a make run - this may take a few moments...)
make: *** [all] Error 1

と言われる。
CentOSの場合/usr/src/linux/ は /usr/src/readhat/ になっているためシンボリック貼ってみたりするが、

Executing: /hoge/dtrace-20091010/tools/make-me
make -C /usr/src/linux/ M=/hoge/dtrace-20091010/build-2.6.18.8-linode19/driver
make[2]: *** No targets specified and no makefile found. Stop.
make[1]: *** [all0] Error 2

# ここまで書いて ./configure も通らなければ make test も通らないことに気づく。oops。

どーにもハマりそうなので、Linux向けはまたの機会にする...
ちなみにMacBook上では、威力のほどは確認できました。こういうツールがデフォルトであるかどうかで、後々違ってくるよなぁ。