Htop on freebsd

From banana_wiki
Jump to: navigation, search

This tool must be so good that people will install a whole linux compatibility layer just to use it in FreeBSD.

First we must load the Linux binary compatibility module

kldload linux

Install the Linux base port

cd /usr/ports/emulators/linux_base-f10 && make install clean

And enable it at startup

echo linux_enable=\"YES\" >> /etc/rc.conf

Add linproc to fstab

linproc /compat/linux/proc   linprocfs   rw   0  0" >> /etc/fstab 
mkdir -p /usr/compat/linux/proc; ln -s /usr/compat /compat; mount linproc

We also must pull in kernel source in order to configure lsof

svnlite checkout /usr/src

Now we can finally build htop

cd /usr/ports/sysutils/htop && make install clean