linux – telnet

telnet comes in 2 parts,


You can find all my latest posts on medium.


– telnet (client)

– telnet-server (daemon, that will by default listen on port 23)


How to Install Telnet in CentOS / RHEL / Scientific Linux 6.4


Telnet is also really useful to check if a certain port on a remote machine is open, here’s the format:

$ telnet {ip number} {port number}

For example, to check port 22, we do:

telnet 22
Connected to home-directories.
Escape character is '^]'.

This shows port 22 is open, whereas if we check a port that is closed, e.g. in my case 21, then we get:

[root@openldap-client01 ~]# telnet 21
telnet: connect to address Connection refused


also install nmap:


yum install nmap


after that you can check if telnet daemon is listenning on the correct port:

[bash][root@puppetagent1 ~]# nmap localhost

Starting Nmap 5.51 ( ) at 2014-08-04 02:08 BST
Nmap scan report for localhost (
Host is up (0.000019s latency).
Other addresses for localhost (not scanned):
Not shown: 995 closed ports
22/tcp   open   ssh
23/tcp   open   telnet
25/tcp   open   smtp
111/tcp open   rpcbind
631/tcp open   ipp [/bash]