Remote Shell Login

In this page the various ways that you can make a remote shell login to your system through Webmin are explained.

The SSH/Telnet Login module

If your system is running either an SSH or telnet server (as most do by default), you can use Webmin's built-in SSH and telnet client module to do a normal shell login. Because the module uses a Java applet, when you use it to login the connection is coming from the client host that your web browser is running on, just as if you ran a normal telnet client program. This means that if there is any firewall blocking telnet or SSH access from the client, this Webmin module will not be able to get around it.

To use the module, click on its icon under the Others category in Webmin. The main page simply contains a Java applet that will by default make a telnet connection to the server running Webmin. If your browser does not support Java, an error message will be displayed instead. If the applet loads and is able to connect, it should display a login prompt �� just click on the applet and enter your username and password to log in. Figure 24-1 shows an example.


The SSH/Telnet Login module

Not all versions of Linux have a telnet server running by default. Many new distributions include an SSH server instead, which means that the applet will be unable to make a telnet connection. If this happens, you need to re-configure it as explained in the section below.

Configuring the SSH/Telnet Login module

This module has several configuration options that control its user interface and connection. To edit them, click on the Module Config link in the top-left corner of the main page. The editable options that will be displayed are :

The Command Shell module

One problem with the SSH/Telnet Login module is its inability to connect if there is a firewall of some kind blocking telnet or SSH connections to your system. Even though the rest of Webmin may work fine using HTTP connections, the ports used by the applet may not be available. Even though it is possible to do almost everything in Webmin that you can do at the command line, sometimes it is useful to have a shell prompt for executing Unix commands.

To get around firewall restrictions that prevent an SSH or telnet connection, you can use the Command Shell module, found under the Others category. It allows you to enter shell commands into the field next to the *Execute command *button, which are run when the button is clicked or the return key pressed. All output from the command is displayed in the Command history section at the top of the page.

You can re-run old commands by selecting them from the menu next to the Execute previous command button and then clicking it. If the command history becomes too large, it can be wiped using the Clear history button. This will not effect the menu of previously run commands though.

The module's biggest limitation is that interactive commands like vi, passwd and telnet cannot be run. There is no support for providing input to a command once it has started, so you are limited to non-interactive programs like cp, ls and rm.

The Shell In A Box module

This module combines the best features of both SSH/Telnet Login and Command Shell - it allows you to make a fully interactive login that is tunneled though an HTTP connection, thus avoiding any firewall restrictions. It is not included as one of the standard Webmin modules, but you can download it from http://www.webmin.com/download/modules/shellinabox.wbm.gz. See chapter WebminConfiguration for instructions on how to install it.

When you enter the module, its main page is taken up entirely by a Java applet. To start the login process, click the Connect button in the lower right-hand corner. A normal login: prompt should appear at the top of the window, allowing you to enter a username and password to login and get a shell prompt. When you are done, just click the Disconnect button to logout.

The module's biggest disadvantage is that it uses compiled Linux x86 code, and so cannot be run on other Unix systems or on non-PC hardware. It also uses up a lot of CPU time on the server due to the high number and frequency of HTTP requests that it makes.

Edit | Attach | Printable | Raw View | Backlinks: Web, All Webs | History: r2 < r1 | More topic actions
Topic revision: r2 - 09 Apr 2007 - 23:27:55 - JamieCameron
 
This site is powered by the TWiki collaboration platformCopyright © by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding TWiki? Send feedback