6.2.2. OProfile の使用
oprofile パッケージおよびその依存関係は、OProfile 実行に必要なすべてのユーティリティーをインストールします。OProfile にシステム上で実行中の全アプリケーションのプロファイルを行い、ライブラリーを使用しているアプリケーションで共有ライブラリーのサンプルをグループ化するように指示するには、以下のコマンドを実行します。
# opcontrol --no-vmlinux --separate=library --start--start-daemon を使用します。--stop オプションはデータ収集を中止し、--shutdown は OProfile デーモンを終了します。
opreport か opannotate、opgprof を使用します。デフォルトでは、OProfile デーモンが収集したデータは /var/lib/oprofile/samples/ に保存されます。
OProfile と Performance Counters for Linux (PCL) は同じハードウェアの Performance Monitoring Unit (PMU) を使用します。PCL もしくは NMI ウォッチドッグタイマーがハードウェア PMU を使用している場合、OProfile 開始時に以下のようなメッセージが表示されます。
# opcontrol --start Using default event: CPU_CLK_UNHALTED:100000:0:1:1 Error: counter 0 not available nmi_watchdog using this resource ? Try: opcontrol --deinit echo 0 > /proc/sys/kernel/nmi_watchdog
perf コマンドを停止し、NMI ウォッチドッグをオフにして以下のコマンドで OProfile カーネルドライバーをリロードします。
# opcontrol --deinit# echo 0 > /proc/sys/kernel/nmi_watchdog
Where did the comment section go?
Red Hat's documentation publication system recently went through an upgrade to enable speedier, more mobile-friendly content. We decided to re-evaluate our commenting platform to ensure that it meets your expectations and serves as an optimal feedback mechanism. During this redesign, we invite your input on providing feedback on Red Hat documentation via the discussion platform.