CentOS:
[root@clovem ~]# yum install telnet-server -y //安裝telnet服務(wù)端
[root@clovem ~]# cat /etc/xinetd.d/telnet //開啟telnet的托管服務(wù)
# default: on
# description: The telnet server serves telnet sessions; it uses \
#unencrypted username/password pairs for authentication.
service telnet
{
flags= REUSE
socket_type= stream
wait= no
user= root
server= /usr/sbin/in.telnetd
log_on_failure+= USERID
disable= no //將yes改為no
}
[root@clovem ~]# service xinetd restart //重啟托管服務(wù)使配置文件生效
如下操作使root用戶登錄生效
[root@clovem ~]# mv /etc/securetty /etc/securetty.bak
這樣, root 就可以直接進(jìn)入 Linux 主機(jī)了。不過,建議不要這樣做。也可以在普通用戶進(jìn)入后,切換到root用戶,擁有root的權(quán)限。
Red Hat Enterprise Linux AS release 4
需要修改:krb5-telnet
[root@rawlnx ~]# cat /etc/xinetd.d/krb5-telnet
# default: off
# description: The kerberized telnet server accepts normal telnet sessions, \
# but can also use Kerberos 5 authentication.
service telnet
{
flags= REUSE
socket_type= stream
wait= no
user= root
server= /usr/kerberos/sbin/telnetd
log_on_failure+= USERID
disable= no
}
配置完成,重啟xinetd 服務(wù)
solaris:將本文件的CONSOLE一行注釋,直接生效
-bash-3.00# cat /etc/default/login |grep CONSOLE
# If CONSOLE is set, root can only login on that device.
#CONSOLE=/dev/console