The pidof utility was originally written by Werner Almesberger as a part of linux psmisc package (it's avaible via sysutils/psmisc port). I don't enjoy installing some outdated stuff like old linux killall(1) or ps(1) tools, that's why I wrote new pidof. It is written to work under FreeBSD (probably, other BSDs would be ok, not sure about their makefile layout) and use kvm(3) to access data.

Differences between original pidof: Installation:

cd /usr/ports/sysutils/pidof; make install clean

Sources:

pidof.tar.gz (2 KB)

Note:

The pgrep(1) utility appaired in FreebSD 5.3 provides the same features and is much more powerful than pidof, so you might consider using it instead.


June 26, 2005, Roman Bogorodskiy

Valid XHTML 1.0!