主题 : 板子使用telnet 可以登录BBS 为什么不可以登录我的主机呢? 复制链接 | 浏览器收藏 | 打印
级别: 新手上路
UID: 4875
精华: 0
发帖: 32
金钱: 325 两
威望: 321 点
综合积分: 64 分
注册时间: 2009-04-01
最后登录: 2010-03-02
楼主  发表于: 2009-04-04 10:47

 板子使用telnet 可以登录BBS 为什么不可以登录我的主机呢?

主机可以telnet可以登录板子,可是反过来怎么都不可以。显示错误
[root@FriendlyARM /]# telnet 10.21.12.34                                       
telnet: Unable to connect to remote host (10.21.12.34): Connection refused

感觉是主机的teknet配置有问题,可是不知道怎么改

请大家帮忙~~~~

*無鈳取玳
级别: 论坛版主
UID: 27
精华: 12
发帖: 5398
金钱: 40120 两
威望: 17929 点
综合积分: 11036 分
注册时间: 2008-01-16
最后登录: 2014-11-22
1楼  发表于: 2009-04-04 11:28
主机有telnet server吗?
"If you have an apple and I have an apple and we exchange apples, then you and I will
still each have one apple. But if you have an idea and I have an idea and we exchange
these ideas, then each of us will have two ideas."
级别: 新手上路
UID: 4875
精华: 0
发帖: 32
金钱: 325 两
威望: 321 点
综合积分: 64 分
注册时间: 2009-04-01
最后登录: 2010-03-02
2楼  发表于: 2009-04-04 15:04
多谢楼上的提醒,终于搞好了

具体步骤是这样的


如果遇到这样的问题:
试图直接启动telnet。
#in.telnetd
telnetd: getpeername: Socket operation on non-socket

是因为telnet这个服务只能够被inetd启动。
你要确保在/etc/inetd.conf里面有这一行:
telnet stream tcp nowait root /usr/sbin/tcpd /usr/sbin/in.telnetd
各个字段的含义是:
<service_name> <sock_type> <proto> <flags> <user> <server_path> <args>
这里的<user>为root,也可以是其它用户名,不过保证次用户是存在的。

然后运行/etc/init.d/inetutils-inetd restart
接着运行netstat -vat查看。如果有
tcp6 0 0 *:telnet *:* LISTEN
这一行,那telnet服务端就配置成功啦。(转贴)