2.修改telnet服务配置文件 [root@secDB ~]# vi /etc/xinetd.d/telnet # 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” } ~ ~
3.重启xinetd守护进程 [root@secDB ~]# service xinetd restart Stopping xinetd: [ OK ] Starting xinetd: [ OK ]
或使用如下的方法重启 [root@secDB ~]# /etc/init.d/xinetd restart Stopping xinetd: [ OK ] Starting xinetd: [ OK ]
确认是否为随开机启动 [root@secDB ~]# chkconfig --list telnet telnet on
OK,调整完毕。
5.测试telnet登录数据库服务器 C:\>telnet 172.17.193.211 Trying 172.17.193.211... Connected to 172.17.193.211. Escape character is '^]'. Red Hat Enterprise Linux Server release 5.3 (Tikanga) Kernel 2.6.18-128.el5 on an x86_64 login: oracle Password: Last login: Thu Mar 4 12:38:11 from 10.142.8.207 ora10g@secDB /home/oracle$ sqlplus / as sysdba
SQL*Plus: Release 10.2.0.3.0 - Production on Thu Mar 4 12:56:13 2010
Copyright (c) 1982, 2006, Oracle. All Rights Reserved.
Connected to: Oracle Database 10g Enterprise Edition Release 10.2.0.3.0 - 64bit Production With the Partitioning, Oracle Label Security, OLAP and Data Mining Scoring Engine options
sys@ora10g> select * from v$version;
BANNER ---------------------------------------------------------------- Oracle Database 10g Enterprise Edition Release 10.2.0.3.0 - 64bi PL/SQL Release 10.2.0.3.0 - Production CORE 10.2.0.3.0 Production TNS for Linux: Version 10.2.0.3.0 - Production NLSRTL Version 10.2.0.3.0 - Production
成功。
6.去除无法telnet到root用户的限制 1)默认情况下是不允许telnet到root用户的 C:\>telnet 172.17.193.211 Trying 172.17.193.211... Connected to 172.17.193.211. Escape character is '^]'. Red Hat Enterprise Linux Server release 5.3 (Tikanga) Kernel 2.6.18-128.el5 on an x86_64 login: root Password: Login incorrect
3)再次测试 C:\>telnet 172.17.193.211 Trying 172.17.193.211... Connected to 172.17.193.211. Escape character is '^]'. Red Hat Enterprise Linux Server release 5.3 (Tikanga) Kernel 2.6.18-128.el5 on an x86_64 login: root Password: Last login: Thu Mar 4 12:39:19 from 10.142.8.207 [root@secDB ~]# id uid=0(root) gid=0(root) groups=0(root),1(bin),2(daemon),3(sys),4(adm),6(disk),10(wheel),105(pkcs11)