Thursday, March 22, 2012

Bash your web server for system info.

A while back I wanted a way to find information about a remote machine without per se logging in. Also did not want to use some fancy or expensive software to do it. Thinking about the machine, what could I use. Ah! Apache2 web server/cgi-bin and bash. That's the ticket. This project could be very easily adapted for OS/X also. MSWindows machines might be more of a project. May experiment on an MSXP machine to see what can be done. Already done home automation with MSXP ( and Linux ( which is what had me thinking about doing this to begin with. Remotely control hardware. so why not do the server also. You remember the good old oesrvr1.

Did not need that fancy of a page but, I could link to the tools page from the main page. The page in it's current form looks like this:

So all you really have to do is to click on an option add the additional information if needed and click submit.  You could click on "Memory info" and press submit. You will get the current memory usage. Great for determining a decision for a memory upgrade. Always adding new commands. One caveat though. This was done on a private server not accessible from the net. You definitely would want additional security on a live system. Even a non-techie manager should be able to handle this.

This little project can also be used to teach the results of certain bash commands in the classroom without getting all tied up in the typing of the commands.  More information at:

No comments:

Post a Comment