man tleds (Commandes) - Blinks keyboard LEDs indicating incoming and outgoing network packets.

NAME

tleds - Blinks keyboard LEDs indicating incoming and outgoing network packets.

SYNOPSIS

tleds [-bchkqv ] [-d N ] interface_name

DESCRIPTION

These programs help you monitor network traffic. They blink Scroll-Lock LED (Light Emitting Diode) when a network packet leaves the machine, and Num-Lock LED when one is received.

tleds can be started on Virtual Terminal (VT) without X-libraries (Xlib) installed. After started, the user can switch to X and tleds will be able to blink LEDs if there is "Xleds 2 3" in the Keyboard section of the /etc/X11/XF86Config.

tleds when started from VT, and run as non root, need their tty to do ioctl(2) to change LEDs, so also when running in the background and ignoring SIGHUP, one cannot exit from the VT or tleds will exit itself.

When run as EUID root, tleds can run in the background without tty. Will use ioctl(2) of /dev/console and therefore can be started for example in boot-up script, eg. in /etc/rc.d/rc.local (see the last EXAMPLE)

If you want to have correct CapsLockLED in VTs, or if you mainly use Virtual Terminals, use the -c option. This will keep the LEDs blinking also after the VT is reset.

PARAMETER

interface_name is the name of your interface which you want to monitor. You can check your interface devices simply with cat(1).

cat /proc/net/dev

OPTIONS

-b
Don't run on the background. Usefull when debugging and profiling.
-c
Can be set only when running EUID root. Will fix CapsLock LEDs in VTs. Without this also the CapsLock LED is detached from actual keyboard flags (see setleds(1) why). Processing CapsLock will take little more CPU time. If you mainly use X, you won't need this. Also when VT is reset, for example when there has been logout and mingetty has been restarted, the LEDs get reattached automaticly. With -c option LEDs are detached again about after 20 seconds. So if you don't use X, you probably want to run tleds as root and use -c option.
-d {N}
Set update delay in milliseconds. N must be between 1 and 10000 ms. Without -d the default for eth* (ethernet) device is 50 ms and 200 ms for others like: ppp* (Point to Point Protocol), sl* (SLIP) and lo (loopback).
-h
Gives short help.
-k
Kills an old tleds process running.
-q
Is pretty quiet. Doesn't tell you in the start what it will do.
-v
Gives version information.

EXAMPLES

tleds ppp0
Starts tleds in the background and with 200 ms (default) update delay. PPP (Point to Poing Protocol) interface #0 is monitored.
tleds -d 100 ppp0
Starts monitoring the interface ppp0 updating every 100 ms.
tleds -qd 100 eth0
Blinks LEDs looking what comes and goes from eth0 (ethernet) every 100 ms. Starts quietly.
tleds -c eth1
On eth1 and update delay is 50 ms (default). Will be able to indicate correct CapsLock state in VTs because the -c flag, and keeps LEDs detached even over VT resets, IF started as EUID root.
tleds -k
Kills the beast, tleds, runnning if there is such.
echo "/usr/bin/tleds -qcd 100 eth0" >>/etc/rc.d/rc.local
(Done as EUID root) Will start tleds in the boot-up, running always in the backgroud. Starts quietly. Shows correct CapsLock state with CapsLock LED in VTs. Will monitor eth0 with 100 ms update delays.

FILES

/proc/net/dev

/tmp/tleds.pid

/var/run/tleds.pid

/etc/X11/XF86Config

AUTHOR

tleds was made by Jouni Lohikoski <Jouni.Lohikoski@iki.fi>.

COPYRIGHT

Copyrighted and released under GNU General Public License (GPL).

URL

<URL:http://www.iki.fi/Jouni.Lohikoski/tleds.html>

SEE ALSO

BUGS

I hope not. Please e-mail me when you find them. Will get SIGSEGV if tried to monitor network device which doesn't support /proc filesystem, eg. dummy. If you disconnect keyboard and are running tleds, it takes more CPU time I've heard. Buy an extra keyboard or email me how to detect this in run time.

One comment: kernel should enable deattach LEDs separately. Now it's all or none, and these programs has to do some hacks with -c option.

DATE



Version 1.00 released on The Judgment Day, 29th August 1997