问题: telnet: connect to address 192.168.1.103: Connection refused

总结:{

  1. 需要开启telnet服务, /etc/xinetd.d/krb5-telnet

  2.telnet登录不能使用root用户,但是可以使用普通用户telnet登录之后,使用su切换到root用户.

}

 

解决问题:

ssh 192.168.1.103

# netstat -tnl |grep 23

rpm -qa telnet-server

# vi /etc/xinetd.d/telnet (我的CentOS release 5.11 (Final)是 vi /etc/xinetd.d/krb5-telnet ;  )

把disable         = yes

修改为:

disable         = no

# service xinetd restart# netstat -tnl |grep 23
tcp        0      0 0.0.0.0:23                  0.0.0.0:*                   LISTEN

再次尝试远程登录

# telnet 192.168.1.103

Trying 192.168.1.103...
Connected to localhost (192.168.1.103).
Escape character is '^]'.
Red Hat Enterprise Linux AS release 4 (Nahant Update 8)
Kernel 2.6.9-89.EL on an x86_64
login: root
Password:
Login incorrect

总是提示密码不正确

主机 192.168.1.103,添加一个普通用户,尝试使用普通用户登录

[root@rac3 ~]# useradd fei
[root@rac3 ~]# passwd fei

[oracle@localhost ~]$ telnet 192.168.1.103
Trying 192.168.1.103...
Connected to localhost (192.168.1.103).
Escape character is '^]'.
Red Hat Enterprise Linux AS release 4 (Nahant Update 8)
Kernel 2.6.9-89.EL on an x86_64
login: root
Password:
Login incorrect

login: fei
Password:

[fei@rac3 ~]$

使用普通用户登录后,再切换到root

[fei@rac3 ~]$ su -

Password:
[root@rac3 ~]#

原来是为了安全,限制了root用户登录。

相关文章:

  • 2021-08-02
  • 2022-02-08
  • 2022-02-08
  • 2022-02-03
猜你喜欢
  • 2021-11-27
  • 2021-07-18
  • 2021-11-29
  • 2021-11-29
  • 2021-11-29
  • 2021-11-29
  • 2021-09-14
相关资源
相似解决方案