centos7 离线安装telnet服务

1.检查是否安装telnet服务

[root@localhost ~]# ps -ef | grep telnet
root     10806 10790  0 20:22 pts/0    00:00:00 grep --color=auto telnet
[root@localhost ~]# rpm -qa | grep telnet
[root@localhost ~]# 

2.下载telnet-server的telnet-server-0.17-64.el7.x86_64.rpm包,使用rpm安装

http://www.rpmfind.net/linux/rpm2html/search.php?query=telnet-server(x86-64)

3.添加启动项服务,启动服务

[root@localhost ~]# systemctl enable telnet.socket
Created symlink from /etc/systemd/system/sockets.target.wants/telnet.socket to /usr/lib/systemd/system/telnet.socket.
[root@localhost ~]# 
[root@localhost ~]# systemctl start telnet.socket

[root@localhost ~]# systemctl status telnet.socket
● telnet.socket - Telnet Server Activation Socket
   Loaded: loaded (/usr/lib/systemd/system/telnet.socket; enabled; vendor preset: disabled)
   Active: active (listening) since Wed 2017-05-03 20:26:04 EDT; 11s ago
     Docs: man:telnetd(8)
   Listen: [::]:23 (Stream)
 Accepted: 0; Connected: 0

May 03 20:26:04 localhost.localdomain systemd[1]: Listening on Telnet Server Activation Socket.
May 03 20:26:04 localhost.localdomain systemd[1]: Starting Telnet Server Activation Socket.
[root@localhost ~]# 

4.开启防火墙23端口

firewall-cmd --permanent --add-port=23/tcp

firewall-cmd --zone=public --list-ports

5.使用客户端测试

你可能感兴趣的:(linux)