• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 239
  • Last Modified:

Configuring unix machines via web using Java and/or Perl

I am working on a website designed to remotely connect to different unix boxes (ssh) and perform different command line tasks.

What does Java give us regarding connecting, processing command line args, etc.  Does Java offer anything similar to Expect scripting?

What is the best way (preferably Java, but we can do Perl too) to:

1) Get user login credentials via web and remotely connect (ssh) to the boxes.
2) Process CLI commands from Java app (servlet)

3 Solutions
I'm a bit confused as to what you're looking to accomplish.  It almost sounds like ssh through a website?  If so, there are plenty of ssh applets out there.

I presume you're aware of Webmin.  It's a fairly robust browser based remote administration tool:


krussell222Author Commented:
Basically that is pretty much it.  

I need a way to do identical configuration of apps over a series of boxes (dozens) without the need to log into each box and run the config (which is run via a series of CLI commands).  The closest example would probably be adding an identical firewall rule to 10 different firewalls running on 10 different boxes.  I'll check out webmin and see if it offers what I'm looking for.
krussell222Author Commented:
I guess I should add... this needs to happen without user interaction.  Basically I'll upload a file with the CLI commands and submit it.  Then I want my web app to login in to each server and run the commands.
Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

This sounds like it could be done with perl
If you want a web-based interface, you can use the CGI module.
To SSH to a bunch of machines, you can use the Net::SSH module.
krussell222Author Commented:
Yeah.. I am leaning toward Perl.  However, I don't think I'll be able to use Net::SSH since it requires using DSA/RSA keys and that isn't an option on these boxes.
One of the other Net::SSH::* modules might work.
Forced accept.

EE Admin

Featured Post

Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now