实验环境:
centos7 x2
server-vsftp:192.168.1.32
client:192.168.95
客户端测试访问 ftp服务器
报错:ftp: connect: No route to host,
排除思路:
1、服务器与客户端是否互通,
2、防火墙是否启用
解决:
1、在/etc/sysconfig/iptables-config 文件中
更改 IPTABLES_MODULES=”” 为 IPTABLES_MODULES=”ip_nat_ftp ip_conntrack_ftp”
重启 iptables 服务
2、直接加载模块
modprobe ip_nat_ftp
modprobe ip_conntrack_ftp
3、直接清除规则
iptables -F
总结:
此环境因启用了防火墙规则,所导致的报错,所以为了节约时间直接清除防火墙规则 !!!
扫码关注腾讯云开发者
领取腾讯云代金券
Copyright © 2013 - 2025 Tencent Cloud. All Rights Reserved. 腾讯云 版权所有
深圳市腾讯计算机系统有限公司 ICP备案/许可证号:粤B2-20090059 深公网安备号 44030502008569
腾讯云计算(北京)有限责任公司 京ICP证150476号 | 京ICP备11018762号 | 京公网安备号11010802020287
Copyright © 2013 - 2025 Tencent Cloud.
All Rights Reserved. 腾讯云 版权所有