Iftop

From DD-WRT Wiki

(Difference between revisions)
Jump to: navigation, search
Revision as of 00:49, 14 October 2005 (edit)
24.6.255.74 (Talk)

← Previous diff
Revision as of 23:28, 14 October 2005 (edit) (undo)
24.6.255.74 (Talk)

Next diff →
Line 8: Line 8:
This will install all the necessary packages to run '''iftop'''. All these packages may not be needed, but I am listing it here exactly the way I did it. This will install all the necessary packages to run '''iftop'''. All these packages may not be needed, but I am listing it here exactly the way I did it.
-These packages will install under ''/jffs'', so you need to inform your system about the location of these newly-installed libraries in these non-standard paths. Under ''/jffs/usr/bin/'', I created a file named ''set_path'', which contains the following:+These packages will install under ''/jffs'', so you need to inform your system about the location of these newly-installed libraries in these non-standard paths. Under ''/jffs/'', I created a file named ''set_path'', which contains the following:
#!/usr/bin/env sh #!/usr/bin/env sh
Line 18: Line 18:
I've made it executable, but it's probably not necessary I've made it executable, but it's probably not necessary
- /jffs/usr/bin # ls -al set_path+ /jffs # ls -al set_path
-rwxr-xr-x 1 root root 192 Oct 13 17:26 set_path -rwxr-xr-x 1 root root 192 Oct 13 17:26 set_path
'''Every time you log in''', you need to source this file as follows '''Every time you log in''', you need to source this file as follows
- . /jffs/usr/bin/set_path+ . /jffs/set_path
and you should now be able to run '''iftop''' on the interface of your choice. (For me, ''vlan1'' is WAN and ''br0'' is LAN+WLAN). and you should now be able to run '''iftop''' on the interface of your choice. (For me, ''vlan1'' is WAN and ''br0'' is LAN+WLAN).

Revision as of 23:28, 14 October 2005

I got iftop working on my DD-WRT (WRT54GS) and this is my Dakshina to the DD-WRT/OpenWRT Gurus and Community - Thanks.

OpenWRT Tracker - very good list of available packages for OpenWRT - since OpenWRT and DD-WRT are in the process of merging, this list should only get more and more useful.

ipkg install iftop (or iftop-bangless if you wish)
ipkg install libpcap libncurses libpthread
ipkg install terminfo
ipkg install ncurses ncurses-term

This will install all the necessary packages to run iftop. All these packages may not be needed, but I am listing it here exactly the way I did it.

These packages will install under /jffs, so you need to inform your system about the location of these newly-installed libraries in these non-standard paths. Under /jffs/, I created a file named set_path, which contains the following:

#!/usr/bin/env sh

export LD_LIBRARY_PATH=`cat /etc/ld.so.conf  | tr '\012' ':'`
export LD_LIBRARY_PATH="${LD_LIBRARY_PATH}:/jffs/lib:/jffs/usr/lib"

export TERMINFO=/jffs/usr/share/terminfo

I've made it executable, but it's probably not necessary

/jffs # ls -al set_path
-rwxr-xr-x    1 root     root          192 Oct 13 17:26 set_path

Every time you log in, you need to source this file as follows

. /jffs/set_path

and you should now be able to run iftop on the interface of your choice. (For me, vlan1 is WAN and br0 is LAN+WLAN).