SMaRT
[ Simple Monitoring and Reporting Tool ]
About five years ago I wrote a shell script for personal use that I could
use to keep tabs on who was logged onto the system at any given time. It was
simple, fast, and did the job at the time. Upon reviewing it, I recently
decided to rewrite it to include the users' processes and to support a larger
variety of Unix/Linux/BSD systems. The result is a script called SMaRT: Simple
Monitoring and Reporting Tool.
SMaRT has been modified to work with FreeBSD, SunOS, Slackware, and Redhat.
However, you may find that one of the script versions will work with another
variant of Unix/Linux, as I discovered with the Slackware/Redhat script. It all
depends on the command-line options and output format of the commands "w" and
"ps". The SunOS script is by far the least efficient because I ended up
resorting to file I/O, but it does the job nevertheless!
Why did I write SMaRT? Yes, I realize there are a few programs written in C
that perform the same kind of task and probably do a better job of it, but
these scripts were written mostly for the fun of it. They may come in useful
for anyone finding themselves on a shell account without access to a compiler.
So, enjoy this tool and remember to 'chmod 700' the script you plan to use.