A terminal emulation program for TCP/IP networks such as the Internet. The Telnet program runs on your computer and connects your PC to a server on the network. You can then enter commands through the Telnet program and they will be executed as if you were entering them directly on the server console. This enables you to control the server and communicate with other servers on the network. To start a Telnet session, you must log in to a server by entering a valid username and password. Telnet is a common way to remotely control Web servers.
Install Telnet Server in Ubuntu
You will find the Telnet server installation packages in Synaptic under the telnetd package.If you want to install telnet server package you can also use the following command
sudo apt-get install telnetd
This will complete the installation.Now you Restart inetd service using the following command
sudo /etc/init.d/inetd restart
Once installed, select Administration, Services and enable Telnet
you can now fire up your other Linux box and type telnet . You are prompted to enter your username and password. The whole conversation should look like this
Connected to 192.168.0.1 (192.168.0.1)
Escape character is ‘^]’.
Welcome to telnetserver
Running Ubuntu LAMP server
* All access is logged *
Last login: Sat Dec 25 1:05:1 from 192.168.0.1
If you are using windows machine you can download telnet clients if you like like putty and teraterm to connect.
Note that the server responds with Welcome to telnetserver, running Ubuntu LAMP server, which is a customized message. Your machine will probably respond with Ubuntu and some version information. This is insecure: giving away version numbers is never a smart move. In fact, even saying Ubuntu is questionable. Edit the issue and issue.net files in your /etc directory to change these messages.
Running the w command now shows you as connecting from the external IP address.
Telnet is fast but also insecure. It sends all your text, including your password, in plain text that can be read by anyone with the right tools. SSH, on the other hand, encrypts all your communication and so is more resource-intensive but secureeven a government security agency sniffing your packets for some reason would still have a hard time cracking the encryption.
3 thoughts on “Setting Up a Telnet Server in Ubuntu”
Thanks for this post.
Could you write something on installing and working with LAMP in your next post?
I believe the best way to automate telnet commands is using “Expect”
this also a better way