原文

FTP sessions use two network connections:

  1. The control channel is for user authentication and sending commands and ...

  2. The data channel is for transferring files and directory listings.

If you can connect to an FTP server but not transfer files or directory listings, the most likely cause is a blocked data channel.

More About FTP Control Channels

FTP sessions are established on the FTP control channel. If you are able to connect and authenticate then your control channel is probably fine. The default port is 21 for most control channels except for FTPS Implicit connections for which 990 is the default. Use the /port=x option of the FTPLOGON command to make Robo-FTP attempt a control channel connection on a specific port.

More About FTP Data Channels

FTP data channels are opened and closed as needed during an FTP session. There are two methods or opening a data channel:

  1. Passive Mode is the preferred data channel method for modern FTP clients because, in this mode, the client opens an outbound connection to a port specified by the server. A client sends the PASV command to request that a server allow an inbound data channel connection. The server responds with an IP address and port number on which it will be waiting for the client to open a connection.

  2. Active Mode is falling out of favor because it requires that the server make an inbound connection to the client computer. When a client requests an active mode connection, it sends the PORT command along with its IP address and the port where it will be waiting for the server to open a connection.

Beginning with version 3.7 Robo-FTP defaults to passive mode because, in our experience, the chances of making a successful outbound connection are higher than those of accepting a successful inbound connection.

Troubleshooting

When you can connect but not list or transfer files, the first troubleshooting step should be to try the opposite data channel mode. In Robo-FTP, add the /pasv=false option to the FTPLOGON command line to use active mode or remove it to revert to the default passive mode.

If you are using passive mode data connections:

  1. Contact the owner of the FTP server and ask "What is your passive port range?" then ask your network administrator to allow outboundconnections to the FTP server on that port range.

  2. Decode the port number from the server's PASV response (see below) and then use the Classic TCP-only Javascript Client onwww.firebind.com to test outbound connectivity on that port.

If you are using active mode data connections:

  1. Ask your network administrator to allow inbound connections to your computer and then use the /minport/maxport and /myipaddroptions of the FTPLOGON command to force Robo-FTP to send a public IP address in an allowed port range.

Decoding port numbers

Examine the Trace Log and find the PORT or PASV command. There should be six digits separated by commas. To decode the port number, take the 5th number and multiple by 256 then add the 6th number. For example, if your Trace Log contains this:

->- PASV
-<- 227 Entering Passive Mode (209,198,133,148,170,225)

This means that the server is waiting for an incoming passive mode data channel connection on port 43745

43745 = (170 * 256) + 225

I can connect to an FTP site but I can't list or transfer files.的更多相关文章

  1. iis 7.5 ftp site用户名不能是 'ftp'?

    在windows server 2008 r2上配置一个iis ftp site,创建了一个名为 ftp 的账号,并添加到允许规则中,可总是出现: Connected to ***.***.***.* ...

  2. ftp上传文件出现553 Could not creat files 严重文件传输错误

    之前上传文件到云服务器上一直出错,发现可以下载但是不能上传和编辑,后来终于找到原因了,是因为上传文件所在文件夹默认只有root用户才有写权限,所以我们还要将写权限赋予给其他用户.可以用Xshell 5 ...

  3. 在Window的IIS中创建FTP的Site并用C#进行文件的上传下载

    文件传输协议 (FTP) 是一个标准协议,可用来通过 Internet 将文件从一台计算机移到另一台计算机. 这些文件存储在运行 FTP 服务器软件的服务器计算机上. 然后,远程计算机可以使用 FTP ...

  4. 创建FTP的Site并用C#进行文件的上传下载

    创建FTP的Site并用C#进行文件的上传下载 文件传输协议 (FTP) 是一个标准协议,可用来通过 Internet 将文件从一台计算机移到另一台计算机. 这些文件存储在运行 FTP 服务器软件的服 ...

  5. RedHat6.2搭建FTP服务器

    我的环境: A:Red Hat Enterprise 6.2 IP:192.168.16.12 此机作测试端 B:Red Hat Enterprise 6.2 IP:192.168.16.13 此机做 ...

  6. ftp 操作,支持断点续传或者继续下载。

    1.ftpclient 类 public class FTPClient:IDisposable { public static object _obj = new object(); #region ...

  7. Android中FTP服务器、客户端搭建以及SwiFTP、ftp4j介绍

    本文主要内容: 1.FTP服务端部署---- 基于Android中SwiFTP开源软件介绍: 2.FTP客户端部署 --- 基于ftp4j开源jar包的客户端开发 : 3.使用步骤 --- 如何测试我 ...

  8. ftp中ftpClient类的API

    org.apache.commons.NET.ftp  Class FTPClient类FTPClient java.lang.Object java.lang.Object继承 org.apache ...

  9. org.apache.commons.net.ftp

    org.apache.commons.NET.ftp Class FTPClient类FTPClient java.lang.Object Java.lang.Object继承 org.apache. ...

随机推荐

  1. ubuntu 常用命令

    此处为使用ubuntu中常用的命令,不会全面深入讲解命令,仅供日常使用查看,以备遗忘. 不定时更新! 1.远程传输文件(小文件) scp [user@源文件地址:/目录/.../file] [目的地址 ...

  2. 构建一个简单的WCF应用——WCF学习笔记(1)

    通过<WCF全面解析>来知识分享....感谢蒋金楠老师@Artech 一.VS中构建解决方案   Client一个控制台程序模拟的客户端,引用Service.ServiceModel.dl ...

  3. LintCode Singleton

    Singleton 3 大要素: 1.有private static的句柄(成员变量即field) 2. constructor 必须为private 3.有public static的getInst ...

  4. jdbc 配置

    jdbc 配置 Class.forName("com.mysql.jdbc.Driver")  ;//加载数据库驱动 Connection conn=null; String ur ...

  5. Codeforces Round #160 (Div. 2)

    A. Roma and Lucky Numbers 暴力计算. B. Roma and Changing Signs 每次取最小值改变正负,优先队列维护. C. Maxim and Discounts ...

  6. 深入解读Linux与Android的相互关系(转-lining)

    大家都知道Android是基于Linux内核的操作系统,也曾经和Linux基金会因为内核问题产生过分歧,本文将开始对Android的内核进行剖析,主要介绍Android和Linux之间的关系,后续还会 ...

  7. android之OptionMenu

    一.现在我给大家介绍两个不同版本的模拟器(2.3.3和4.0.3) 1.布局文件 (1)打开“res/layout/activity_main.xml”文件. 先看mian布局文件 <Relat ...

  8. kuangbin_SegTree E (HDU 1698)

    POJ服务器炸了 还没好呢 然后就只能跳掉一些题目了 这题也是成段更新模板题 本来lazy标记不是很明白 后来学长上课讲了一下就知道原理了 回去看看代码很容易就理解了 #include <cst ...

  9. 数迹学——Asp.Net MVC4入门指南(4):添加一个模型

    一.添加模型类 二.添加MovieDBContext类,连接数据库 DbContext类继承自 System.Data.Entity; 负责在数据库中获取,存储,更新,处理实例 MovieDBCont ...

  10. 数迹学——Asp.Net MVC4入门指南(3):添加一个视图

    方法返回值  ActionResult(方法执行后的结果) 例子1 public ActionResult methordName() { return "string"; } 例 ...