#688 closed defect (invalid)

FTP frontend doesn't work when behind NAT (debian)

Reported by: arthur Owned by: nobody
Priority: major Milestone: undecided
Component: unknown Version: 1.4.1
Keywords: Cc:
Launchpad Bug:

Description (last modified by zooko)

I followed the patches in twisted in the following document : http://allmydata.org/source/tahoe/trunk/docs/frontends/FTP-and-SFTP.txt

First odd thing : I don't have the twisted/vfs/adapters/ftp.py on a debian install which seems to work correctly.

I did the FTP front end on two nodes of my grid. One inside my home network, and the other on a public IP on a hosted machine. The FTP works on the internal network machine but not on the other one (setup differs also as the internal one is ubuntu and the external is debian, but both are missing the vfs ftp.py file).

On the external one I get (sorry some of it is french)::

Commande: LIST Réponse: 550 Requested action not taken: internal server error Erreur: Échec lors de la lecture du contenu du dossier Réponse: 503 Incorrect sequence of commands: must send PORT or PASV before RETR

In the twisted log I get ::

2009-04-30 19:06:45+0200 [ProtocolWrapper?,0,86.69.160.55] twisted.protocols.ftp.DTPFactory starting on 40749 2009-04-30 19:06:45+0200 [ProtocolWrapper?,0,86.69.160.55] Starting factory <twisted.protocols.ftp.DTPFactory instance at 0x92d678c> 2009-04-30 19:06:45+0200 [-] (Port 44070 Closed) 2009-04-30 19:06:45+0200 [-] Stopping factory <twisted.protocols.ftp.DTPFactory instance at 0x906b02c> 2009-04-30 19:06:45+0200 [-] dtpFactory.stopFactory 2009-04-30 19:06:55+0200 [-] timed out waiting for DTP connection 2009-04-30 19:06:55+0200 [-] Unexpected FTP error 2009-04-30 19:06:55+0200 [-] Unhandled Error

Traceback (most recent call last): Failure: twisted.internet.defer.TimeoutError?:

2009-04-30 19:06:55+0200 [-] dtpFactory.stopFactory

Change History (3)

comment:1 Changed at 2009-05-05T20:29:36Z by arthur

  • Resolution set to fixed
  • Status changed from new to closed

I found the solution. The problem was that it is running on a non standard port (not 21) so the firewall (shorewall) was not tracking the ports openning for passive FTP correctly.

If you're having the same problem, read this : http://www.shorewall.net/FTP.html and configure your modules correctly. Works for me now.

comment:2 Changed at 2009-06-10T16:33:21Z by zooko

  • Description modified (diff)
  • Resolution fixed deleted
  • Status changed from closed to reopened

Let's mark this as not-our-bug rather than "fixed" when we close it. Thanks for opening this and tracking it down, arthur!

comment:3 Changed at 2009-06-10T16:33:27Z by zooko

  • Description modified (diff)
  • Resolution set to invalid
  • Status changed from reopened to closed
Note: See TracTickets for help on using tickets.