You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@commons.apache.org by luan xl <he...@hotmail.com> on 2005/12/07 07:39:20 UTC

[Net] slow ftp pasv connection

Hi, I hava just written some code to traverse the ftp site using the 
commons-net 1.4.
I tested it on Windows(XP SP2) and Linux(Debian 3.0), they both work 
correctly. But one
thing just make me confused.

On my Windows platform, when I issue the command LIST in passive mode, the 
data 
connection is very slow to make, usually takes 5 to 10 seconds.However if I 
issue
the command LIST in port mode, the connection is made very quickly. On the 
Linux 
platform, both passive and port are very quickly.

On both platform firewalls are closed, the ftp server is same for tests. 
what is the
possible cause for this?



---------------------------------------------------------------------
To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-user-help@jakarta.apache.org


Re: [Net] slow ftp pasv connection

Posted by Leo Sutic <le...@inspireinfrastructure.com>.
Do this:

Go to the FTP server.

IF THE FTP SERVER IS RUNNING LINUX:

Issue the command:

time nslookup <ip address of linux client>
time nslookup <ip address of windows client>


ELSE:

nslookup <ip address of linux client>
nslookup <ip address of windows client>

I think the lookup of the windows client will be much much slower.

/LS

On 12/7/05, luan xl <he...@hotmail.com> wrote:
> no, I use the ip address directly, both server and clients are in a 100mbit
> LAN.
>
>
> >From: Leo Sutic <le...@inspireinfrastructure.com>
> >Reply-To: "Jakarta Commons Users List" <co...@jakarta.apache.org>
> >To: Jakarta Commons Users List <co...@jakarta.apache.org>
> >Subject: Re: [Net] slow ftp pasv connection
> >Date: Wed, 7 Dec 2005 09:12:38 +0100
> >
> >Could be related to nameserver lookups. When you connect to the FTP
> >server, does it have both forward (name -> ip) and reverse (ip ->
> >name) dns entries?
> >
> >/LS
> >
> >On 12/7/05, luan xl <he...@hotmail.com> wrote:
> > > Hi, I hava just written some code to traverse the ftp site using the
> > > commons-net 1.4.
> > > I tested it on Windows(XP SP2) and Linux(Debian 3.0), they both work
> > > correctly. But one
> > > thing just make me confused.
> > >
> > > On my Windows platform, when I issue the command LIST in passive mode,
> the
> > > data
> > > connection is very slow to make, usually takes 5 to 10 seconds.However
> if I
> > > issue
> > > the command LIST in port mode, the connection is made very quickly. On
> the
> > > Linux
> > > platform, both passive and port are very quickly.
> > >
> > > On both platform firewalls are closed, the ftp server is same for
> tests.
> > > what is the
> > > possible cause for this?
> > >
> > >
> > >
> > > ---------------------------------------------------------------------
> > > To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org
> > > For additional commands, e-mail: commons-user-help@jakarta.apache.org
> > >
> > >
> >
> >---------------------------------------------------------------------
> >To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org
> >For additional commands, e-mail: commons-user-help@jakarta.apache.org
> >
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: commons-user-help@jakarta.apache.org
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-user-help@jakarta.apache.org


Re: [Net] slow ftp pasv connection

Posted by luan xl <he...@hotmail.com>.
no, I use the ip address directly, both server and clients are in a 100mbit 
LAN.


>From: Leo Sutic <le...@inspireinfrastructure.com>
>Reply-To: "Jakarta Commons Users List" <co...@jakarta.apache.org>
>To: Jakarta Commons Users List <co...@jakarta.apache.org>
>Subject: Re: [Net] slow ftp pasv connection
>Date: Wed, 7 Dec 2005 09:12:38 +0100
>
>Could be related to nameserver lookups. When you connect to the FTP
>server, does it have both forward (name -> ip) and reverse (ip ->
>name) dns entries?
>
>/LS
>
>On 12/7/05, luan xl <he...@hotmail.com> wrote:
> > Hi, I hava just written some code to traverse the ftp site using the
> > commons-net 1.4.
> > I tested it on Windows(XP SP2) and Linux(Debian 3.0), they both work
> > correctly. But one
> > thing just make me confused.
> >
> > On my Windows platform, when I issue the command LIST in passive mode, 
the
> > data
> > connection is very slow to make, usually takes 5 to 10 seconds.However 
if I
> > issue
> > the command LIST in port mode, the connection is made very quickly. On 
the
> > Linux
> > platform, both passive and port are very quickly.
> >
> > On both platform firewalls are closed, the ftp server is same for 
tests.
> > what is the
> > possible cause for this?
> >
> >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org
> > For additional commands, e-mail: commons-user-help@jakarta.apache.org
> >
> >
>
>---------------------------------------------------------------------
>To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org
>For additional commands, e-mail: commons-user-help@jakarta.apache.org
>



---------------------------------------------------------------------
To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-user-help@jakarta.apache.org


Re: [Net] slow ftp pasv connection

Posted by Leo Sutic <le...@inspireinfrastructure.com>.
Could be related to nameserver lookups. When you connect to the FTP
server, does it have both forward (name -> ip) and reverse (ip ->
name) dns entries?

/LS

On 12/7/05, luan xl <he...@hotmail.com> wrote:
> Hi, I hava just written some code to traverse the ftp site using the
> commons-net 1.4.
> I tested it on Windows(XP SP2) and Linux(Debian 3.0), they both work
> correctly. But one
> thing just make me confused.
>
> On my Windows platform, when I issue the command LIST in passive mode, the
> data
> connection is very slow to make, usually takes 5 to 10 seconds.However if I
> issue
> the command LIST in port mode, the connection is made very quickly. On the
> Linux
> platform, both passive and port are very quickly.
>
> On both platform firewalls are closed, the ftp server is same for tests.
> what is the
> possible cause for this?
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: commons-user-help@jakarta.apache.org
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-user-help@jakarta.apache.org