ECS大优惠点我点我!!!红包+折扣,阿里云上云大礼包!!!
一、安装telnet-server
yum install telnet-server
二、启动telnet服务
编辑/etc/xinetd.d/telnet, 将其中的 disable = yes 的yes改为no.
# default: on
# description: The telnet server serves telnet sessions; it uses \
# unencrypted username/password pairs for authentication.
service telnet
{disable = noflags = REUSEsocket_type = streamwait = nouser = rootserver = /usr/sbin/in.telnetdlog_on_failure += USERID
}
三、重启xinetd服务
service xinetd restart
Stopping xinetd: [ OK ]
Starting xinetd: [ OK ]
四、测试服务
xshell使用telnet 方式连接主机,如下图:

注:默认的telnet不允许root用户登录,若需要使用root用户登录则通过以下方法:
修改/etc/pam.d/remote,注释掉:auth required pam_securetty.so
#%PAM-1.0#auth required pam_securetty.soauth include system-auth


















