- 论坛徽章:
- 0
|
在redhat9下用的proftpd,原来一切正常。但是现在在外网不能登陆ftp服务器了,在内网可以。请耐心看完问题,我把详细情况能写得都写了~~~谢谢大家!!
我服务器有2个网卡,1个连内部的switch上,ip:192.168.0.201。比如用我本地机器192.168.0.1,ftp登陆192.168.0.201没有问题
另一个网卡ip10.0.0.1,直接连接到router的猫上。~~~~~
现在只能在内网里ftp://192.168.0.1(比如这是server内网地址)可以登陆上去
在外网ftp://83.123.0.52(比如说这是server外网地址),提示输入用户名和密码后,出错,说timeout。
今天看了看routeur的配置,NAT已经配置了,默认10.0.0.1就是服务器地址。就是说由端口都指向10.0.0.1。 测试
FTP 如果在本地连接,
connect socket #592 to 192.168.0.201(/*括号内是我自己注释的,这是本地服务器地址*/), port 21...
220 ProFTPD 1.2.10rc3 Server (ProFTPD Default Installation) [localhost.localdomain]
USER test
331 Anonymous login ok, send your complete email address as your password.
PASS **********
230 Anonymous access granted, restrictions apply.
SYST
215 UNIX Type: L8
Keep alive off...
PWD
257 "/" is current directory.
PASV
227 Entering Passive Mode (192,168,0,201(这里指服务器上第1个网卡),179,244).
LIST
Connect socket #608 to 192.168.0.201, port 46068...
150 Opening ASCII mode data connection for file list
226 Transfer complete.
Transferred 1,380 bytes in 0.016 seconds
连接成功
在试试用外网域名连接
Resolving www.mydomaine.fr... (/*服务器域名*/)
Connect socket #552 to 83.214.*.*(/*DNS解析成router modem的外网地址*/), port 21...
220 ProFTPD 1.2.10rc3 Server (ProFTPD Default Installation) [localhost.localdomain]
USER test
331 Anonymous login ok, send your complete email address as your password.
PASS **********
30 Anonymous access granted, restrictions apply.
SYST
215 UNIX Type: L8
Keep alive off...
PWD
57 "/" is current directory.
PASV
227 Entering Passive Mode (10,0,0,1(这里NAT已经解析成内部地址-第2个网卡,指到服务器上了),179,224).
LIST
Connect socket #596 to 10.0.0.1, port 46048...
timeout
最后因为timeout没连接成功?!
这是在redhat上的2个进程,第一个是我用外网联的,连不上
第2个使用内网联的,连上了
5438 ? S 0:00 proftpd: test - ASt-Lambert-152-1-24-220.w82-120.abo.wanadoo.fr: anonymous/****: LIST
5443 ? S 0:00 proftpd: test - 192.168.0.79: anonymous/****: IDLE
这个list和idle是什么?
为什么出现外网不能登陆呢!?什么问题啊?! |
|