Thanks, Monthadar. I'll check that and post what I find.

From: Monthadar Al Jaberi <>
To: John Koshi <>
Sent: Saturday, April 18, 2009 2:11:06 AM
Subject: Re: Oprofile on an embedded system

> Thereafter, it built correctly, but when the image is transferred to the
> target, and I
> run any opcontrol command (for example: opcontrol --no-vmlinux), I get:
>     /usr/bin/opcontrol: line 1: dirname: command not found
>     FATAL: Module oprofile not found.
>     FATAL: Module oprofile not found.
>     Kernel doesn't support oprofile.

opcontrol is a script, and it is complaining that dirname command not
found. A quick search on the net and I found this, maybe it helps:

"3. Your problem is very likely related to a bogus value for PATH. If
dirname is not found, the script, called when running
shell commands, will go into infinite recursion. Since dirname should
be on any system, I’d say we need to figure out why it is not found on
yours." (

You should fix this error first.

When I cross compiled oprofile to arm, I also got script problem, but
that was along time ago, I don't really remember, but I think I cross
compiled binutils and only used what opcontrol needed =)


//Monthadar Al Jaberi