处理ftp服务器 在重启后ftp客户端不能连接访问的问题
1:环境:centos7
2:当在重启centos7 linux服务器后,再连接ftp客户端不能链接

此时需要检查以下几点:
2-1:核查ftp服务是否启动正常:
[root@localhost ~]# service vsftpd status
Redirecting to /bin/systemctl status vsftpd.service
● vsftpd.service - Vsftpd ftp daemon
Loaded: loaded (/usr/lib/systemd/system/vsftpd.service; enabled; vendor preset: disabled)
Active: active (running) since Fri 2017-08-25 09:20:59 CST; 30s ago
Process: 4517 ExecStart=/usr/sbin/vsftpd /etc/vsftpd/vsftpd.conf (code=exited, status=0/SUCCESS)
Main PID: 4520 (vsftpd)
CGroup: /system.slice/vsftpd.service
└─4520 /usr/sbin/vsftpd /etc/vsftpd/vsftpd.conf Aug 25 09:20:59 localhost.localdomain systemd[1]: Starting Vsftpd ftp daemon...
Aug 25 09:20:59 localhost.localdomain systemd[1]: Started Vsftpd ftp daemon.
如果是ftp服务没有启动起来:则需要执行启动命令
service vsftpd restart
或者是设置ftp服务开机自动启动;如何设置请参考《CentOS7 搭建FTP服务器》的“七:解决 linux系统重启后 用ftp工具无法访问的问题”的内容
2-2:核查firewall防火墙是否启动正常:
[root@localhost ~]# systemctl status firewalld.service
● firewalld.service - firewalld - dynamic firewall daemon
Loaded: loaded (/usr/lib/systemd/system/firewalld.service; enabled; vendor preset: enabled)
Active: active (running) since Fri 2017-08-25 09:00:20 CST; 25min ago
Docs: man:firewalld(1)
Main PID: 803 (firewalld)
CGroup: /system.slice/firewalld.service
└─803 /usr/bin/python -Es /usr/sbin/firewalld --nofork --nopid Aug 25 09:00:13 localhost.localdomain systemd[1]: Starting firewalld - dynamic firewall daemon...
Aug 25 09:00:20 localhost.localdomain systemd[1]: Started firewalld - dynamic firewall daemon.
如果是firewall 服务没有启动起来,则需要手动启动
[root@localhost ~]# systemctl restart firewalld.service
#并核查下 启动的端口情况
[root@localhost ~]# firewall-cmd --zone=public --list-ports
80/tcp 8080/tcp
#如果没有自己想要的端口,则添加端口,然后在重启firewall
[root@localhost ~]# firewall-cmd --zone=public --add-port=21/tcp --permanent
success
[root@localhost ~]# systemctl restart firewalld.service
[root@localhost ~]# firewall-cmd --zone=public --list-ports
21/tcp 80/tcp 8080/tcp
2-3:核查iptables 的状态是否启动正常。
[root@localhost ~]# service iptables status
Redirecting to /bin/systemctl status iptables.service
● iptables.service - IPv4 firewall with iptables
Loaded: loaded (/usr/lib/systemd/system/iptables.service; enabled; vendor preset: disabled)
Active: inactive (dead)
[root@localhost ~]#
如果 没有正常启动,则需要手动启动该服务。
[root@localhost ~]# service iptables restart
设置正常开机启动该服务:
[root@localhost ~]# cd /etc/rc.d
[root@localhost rc.d]# ls
init.d rc0.d rc1.d rc2.d rc3.d rc4.d rc5.d rc6.d rc.local
[root@localhost rc.d]# cat rc.local
#!/bin/bash
# THIS FILE IS ADDED FOR COMPATIBILITY PURPOSES
#
# It is highly advisable to create own systemd services or udev rules
# to run scripts during boot instead of using this file.
#
# In contrast to previous versions due to parallel execution during boot
# this script will NOT be run after all other services.
#
# Please note that you must run 'chmod +x /etc/rc.d/rc.local' to ensure
# that this script will be executed during boot. touch /var/lock/subsys/local /etc/init.d/nginx start
[root@localhost rc.d]# vi rc.local
在rc.loal 文件中添加 service iptables restart 确定命令
以下是 红色标注的内容是 添加的启动iptables服务的内容
[root@localhost ~]# cd /etc/rc.d/
[root@localhost rc.d]# ls
init.d rc0.d rc1.d rc2.d rc3.d rc4.d rc5.d rc6.d rc.local
[root@localhost rc.d]# cat rc.local
#!/bin/bash
# THIS FILE IS ADDED FOR COMPATIBILITY PURPOSES
#
# It is highly advisable to create own systemd services or udev rules
# to run scripts during boot instead of using this file.
#
# In contrast to previous versions due to parallel execution during boot
# this script will NOT be run after all other services.
#
# Please note that you must run 'chmod +x /etc/rc.d/rc.local' to ensure
# that this script will be executed during boot. touch /var/lock/subsys/local #开机默认启动nginx服务
/etc/init.d/nginx start
#开机重启 ip 防火墙
service iptables restart
[root@localhost rc.d]#
如果以上3个服务都启动正常,则ftp客户端连接应该是正常的。若还有问题,则需要仔细核查

处理ftp服务器 在重启后ftp客户端不能连接访问的问题的更多相关文章
- 【转】Linux环境搭建FTP服务器与Python实现FTP客户端的交互介绍
Linux环境搭建FTP服务器与Python实现FTP客户端的交互介绍 FTP 是File Transfer Protocol(文件传输协议)的英文简称,它基于传输层协议TCP建立,用于Interne ...
- 在虚拟机上安装redis集群,redis使用版本为4.0.5,本机通过命令客户端可以连接访问,外部主机一直访问不了
在虚拟机上安装了redis 4 ,启动后本机客户端可以连接访问,但是外部主机一直访问不了,在使用java代码连接redis集群时报:no reachable node in cluster,原因:在r ...
- 映射内网ftp服务器到公网后内网访问出错问题
上文说道映射后外网无法访问解决:https://www.cnblogs.com/Dev0ps/p/9073048.html 添加了ftp的pasv_address的地址 ,内网客户端要设置主动模式(a ...
- ftp服务器终端登录后乱码处理方法
首先在windows上用资源管理器登录看看会不会乱码,如果不会,说明是GBK编码 因为windows默认是GBK(936),linux默认(UTF-8) 因为FTP服务器我们修改不了,如果用linux ...
- Linux上的ftp服务器vsftpd之配置满天飞--设置匿名用户访问(不弹出用户名密码框)以及其他用户可正常上传
一.问题背景 没事谁折腾这鬼玩意哦...还不是因为bug. 我们的应用,用户头像是存在ftp上的.之前的ftp服务器是一台windows,我们后台服务器程序收到用户上传头像的请求时,会用一个ROOT/ ...
- 服务器部署网站后,公网ip可以访问,域名不能访问问题(稳)
出现问题 这几天我网站已经部署到vps上,域名也备好案,想使用域名指向我们公网ip.指完发现用域名访问不了网站,但是公网ip可以.于是看了网上资料,好像是要清除浏览器DNS缓存,我清完没用.然后发现我 ...
- Redis Cluster集群搭建后,客户端的连接研究(Spring/Jedis)(待实践)
说明:无论是否已经搭建好集群,还是使用什么样的客户端去连接,都是必须把全部IP列表集成进去,然后随机往其中一个IP写. 这样做的好处: 1.随机IP写入之后,Redis Cluster代理层会自动根据 ...
- 【大话QT之十】实现FTP断点续传(需要设置ftp服务器为“PASV”被动接收方式)
应用需求: 网盘开发工作逐步进入各部分的整合阶段,当用户在客户端修改或新增加一个文件时,该文件要同步上传到服务器端对应的用户目录下,因此针对数据传输(即:上传.下载)这一块现在既定了三种传输方式,即: ...
- 外网访问内网的FTP服务器
转自 外网访问内网的FTP服务器 首先感谢作者给出的总结,原文是介绍Serv-U的,我针对FileZilla Server进行了稍微修改,仅看操作可直接跳到分割线后第3部分. 1. 背景简介最近研究如 ...
随机推荐
- 本地测试使用Tomcat,生产环境使用GlassFish。
总结:Tomcat8 = javaee7规范(servlet3.1 + jsp2.3 + el3.0 + websocket1.0) + java7 [配置初始化参数使用jdk8编译]conf/web ...
- 【核心】project(idea文件)、module(iml文件)到SSM集成、热部署、Tomcat启动、MAVEN依赖冲突
http://wiki.jikexueyuan.com/project/intellij-idea-tutorial/project-composition-introduce.html 在 Inte ...
- 第26月第13天 hibernate导包
1. https://yq.aliyun.com/ziliao/386827
- 第25月第22日 django channels
1. https://github.com/andrewgodwin/channels-examples/ https://channels.readthedocs.io/en/latest/
- Spring+thymeleaf
1.导入jar包 2.配置 3.标签使用 th:text th:utext th:object th:if th:switch th:case th:each="person:userlis ...
- VUX调用例子
首先创建一个vue项目 vue init webpack Vue-Project <1>. 在项目里安装vuxnpm install vux --save <2>. 安 ...
- A Simple Problem with Integers POJ - 3468 (分块)
题目链接:https://cn.vjudge.net/problem/POJ-3468 题目大意:区间加减+区间查询操作. 具体思路:本来是一个线段树裸题,为了学习分块就按照分块的方法做吧. 分块真的 ...
- mongodb 系列 ~ mongo的副本集(2)
一 简介:来试试更改副本集的oplog问题二 背景: oplog的作用类似于mysql的binlog,传递增量操作到从节点 三 oplog介绍 1 oplog在local库: 1 mas ...
- CSS-联合选择器
深层布局,逐级进去,指向某一个标签,叫:关联选择器 - 设置嵌套标签的样式 div p {} day02 昨天内容回顾 1.html的操作思想 ** 使用标签把要操作的数据包起来,通过修改标签的属性值 ...
- 强网杯2018 Web签到
Web签到 比赛链接:http://39.107.33.96:10000 比赛的时候大佬对这题如切菜一般,小白我只能空流泪,通过赛后看别人的wp,我知道了还有这种操作. 这个赛题分为3层 第一层 Th ...