telnet: connect to address 127.0.0.1: Connection refused
telnet协议是TCP/IP协议族中的一员,是Internet远程登陆服务的标准协议和主要方式。它为用户提供了在本地计算机上完成远程主机工作的能力。在终端使用者的电脑上使用telnet程序,用它连接到服务器。
一、检测telnet-server的rpm包是否安装
OS:RedHat9
[root@locahost ~]#rpm -qa telnet-server
//出于安全考虑telnet-server.rpm是默认没有安装的,而telnet的客户端是标配。即下面的软件是默认安装的,为了方便测试,也确认一下//
[root@locahost ~]#rpm -qa telnet
telnet-0.17-25
如果没有安装,请安装telnet-server
第3张盘上有telnet-server-0.17-25.i386.rpm,进入Server目录下执行
[root@locahost ~]#rpm -ivh telnet-server*.i386.rpm
二、重新启动xinetd守护进程
由于telnet服务也是由xinetd守护的,所以安装完telnet-server,要启动telnet服务就必须重新启动xinetd
[root@locahost ~]#service xinetd restart
三、测试一下
我们先来查看TCP的23端口是否开启正常
[root@locahost ~]#netstat -tnl |grep 23
tcp 0 0 0.0.0.0:23 0.0.0.0:* LISTEN
如果上面的一行存在就说明服务已经运行了
这时我们可以本机通过进一步确认一下
[root@locahost ~]# telnet localhost 23
Trying telnet 127.0.0.1…
Connected to localhost.localdomain (127.0.0.1)..
Escape character is ‘^]’.
Red Hat Linux release 9 (Shrike)
Kernel 2.4.20-8 on an i686
login:
如果netstat命令没有返回内容,我们就只好继续进行更深入的配置了。
四、排除可能出现的问题
修改telnet服务配置文件
vi /etc/xinetd.d/telnet
service telnet
{
disable = yes
flags = REUSE
socket_type = stream
wait = no
user = root
server = /usr/sbin/in.telnetd
log_on_failure += USERID
}
将disable=yes行前加#注释掉,或者把yes改为no,之后重新启动xinetd扩展守护进程
[root@localhost ~]# service xinetd restart
停止 xinetd: [确定]
启动 xinetd: [确定]
注意关闭系统防火墙对23端口的限制。
[root@localhost ~]# system-config-securitylevel
在这里我们可以开启或关闭防火墙,也可以配置防火墙
或者:
[root@locahost ~]# setup
Connection refused
有可能服务没开,有可能防火墙禁了端口。
你自己排查吧。
可以参考下这里
http://blog.csdn.net/CenturyMagus/archive/2007/09/12/1782819.aspx
http://topic.csdn.net/u/20090520/16/496930da-cd37-485e-a5ee-2e4303e1bc98.html
原文:http://blog.csdn.net/naughty610/article/details/5724181
telnet: connect to address 127.0.0.1: Connection refused的更多相关文章
- centos解决bash: telnet: command not found...&& telnet: connect to address 127.0.0.1: Connection refused拒绝连接
检查telnet是否已安装: [root@hostuser src]# rpm -q telnet-serverpackage telnet-server is not installed[root@ ...
- 解决telnet: connect to address 127.0.0.1: Connection refused的错误信息问题
1.检查telnet是否已安装: rpm -qa telnet 2.有输出说明已安装,如果没有输出则没有安装,使用yum install telnet进行安装 3.检查telnet-server是否已 ...
- rndc: connect failed: 127.0.0.1#953: connection refused
[root@localhost sbin]# ./named -v bind 9.5.1-p3-v3.0.9 问题现象: [root@localhost sbin]# ./rndc flush -p ...
- connect failed: 127.0.0.1#953: connection refused
Problem1 : root@jeremy-VirtualBox:/etc/bind# /etc/init.d/bind9 restart * Stopping domain name servic ...
- Redis 服务端配置——Could not connect to Redis at 127.0.0.1:6379: Connection refused
[root@centoszang 桌面]# redis-cli Could : Connection refused Could : Connection refused not connected& ...
- 在 Linux redis 验证交互连接过程中遇到 redis Could not connect to Redis at 127.0.0.1:6379: Connection refused 的解决方法
Could not connect to Redis at 127.0.0.1:6379: Connection refused 1.找到redis.conf 并修改 daemonize no 为 d ...
- redis Could not connect to Redis at 127.0.0.1:6379: Connection refused 问题解决
1.启动redis 客户端 redis-cli 报错 redis Could not connect to Redis at 127.0.0.1:6379: Connection refused 是因 ...
- Could not connect to Redis at 127.0.0.1:6379: Connection refused
启动redis: redis-server ../redis.conf redis启动成功后 执行命令行redis-cli报:Could not connect to Redis at 127.0. ...
- [Redis-CentOS7]Redis打开远程连接(十) Could not connect to Redis at 127.0.0.1:6379: Connection refused
通过网络无法访问Redis redis-cli 172.16.1.111 Could not connect to Redis at 127.0.0.1:6379: Connection refuse ...
随机推荐
- 我总结的js性能优化的小知识
前言 一直在学习javascript,也有看过<犀利开发Jquery内核详解与实践>,对这本书的评价只有两个字犀利,可能是对javascript理解的还不够透彻异或是自己太笨,更多的是自己 ...
- centos 搭建git服务器
centos 6搭建git服务器 安装 rpm -ivh http://mirrors.aliyun.com/epel/epel-release-latest-6.noarch.rpm yum ins ...
- Objective-C学习笔记类目、协议
不是所有的方法都可以被覆盖的!比如:intValue就不能被覆盖!! 原因正在查找中! 别人的电脑上却可以! 类目.h件 #import <Foundation/Foundation.h> ...
- uC/OS-II测试(TEST)块
/*************************************************************************************************** ...
- C#中字符串的操作
1.Replace(替换字符):public string Replace(char oldChar,char newChar);在对象中寻找oldChar,如果寻找到,就用newChar将oldCh ...
- EasyUI学习笔记之panel
<easyUI panel 属性:> <!--引入easyUI panel 组件 设置宽,高,定义标题(默认在左上角),设置图标iconCls:'icon-ok',引入工具tools ...
- IP-Address TextBox
http://www.codeproject.com/Articles/4693/IP-Address-TextBox 可以下载试用效果.个人感觉功能很强大,但输入时让人不太舒服.可以参考. ntro ...
- 《深入理解bootstrap》读书笔记:第一章 入门准备
一.bootstrap框架简介 Bootstrap是最流行的前端开发框架. 什么是框架:开发过程的半成品. bootstrap具有以下重要特性: (1)完整的CSS样式插件 (2)丰富的预定义样式表 ...
- 隔离click事件
有一些应用,不需要我们自己的定义的click函数,例如: $(document).on('click', '#inp', function(e){ alert('hello world!'); }); ...
- Google Guava14.0 瓜娃学习笔记
Guava 是java api的增强与扩展,提供复杂的java 数据结构,使你的代码更简短精炼,具有良好的可读性.看看guava给我们提供了哪些很酷的功能: 集合创建: Map<String, ...