Welcome to the most active Linux Forum on the web.
Go Back > Forums > Linux Forums > Linux - Networking
User Name
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.


  Search this Thread
Old 08-24-2006, 12:12 PM   #1
LQ Newbie
Registered: Jul 2006
Posts: 1

Rep: Reputation: 0
proftpd "dir" command hangs


I'm encountering the following peculiarity and have not yet found any other instances in my web travels, and certainly not any that would aid me in resolving the problem.

When ftp'ing to the remote server, login is accepted, cwd is accepted, get is accepted, but 'dir' does nothing. Here's what it does:

ftp> dir
200 PORT command successful
<sits here for 60 seconds or so>
Connection closed by remote host.

Oddly enough, when I ftp to localhost -on- the remote server, everything works perfectly.
Here's what happens:

ftp> dir
227 Entering Passive Mode (127,0,0,1,58,247).
150 Opening ASCII mode data connection for file list
<list of files>
226-Transfer complete.
226 Quotas off

Since passive mode never works when attempting to login, I'm reasonably certain that the problem with the directory listing is that proftpd (or the clients?) switches to a passive connection for the directory listing. Something is preventing passive mode from working.

My proftpd.conf is as follows:

# This is a basic ProFTPD configuration file (rename it to
# 'proftpd.conf' for actual use. It establishes a single server
# and a single anonymous login. It assumes that you have a user/group
# "nobody" and "ftp" for normal operation and anon.

ServerName "ProFTPD"
ServerType inetd
ServerType inetd
DefaultServer on
DefaultRoot ~ psacln
AllowOverwrite on
DefaultTransferMode binary
UseFtpUsers on

# Port 21 is the standard FTP port.
Port 21
PassivePorts 15000 20000
# Umask 022 is a good standard umask to prevent new dirs and files
# from being group and world writable.
Umask 022

# To prevent DoS attacks, set the maximum number of child processes
# to 30. If you need to allow more than 30 concurrent connections
# at once, simply increase this value. Note that this ONLY works
# in standalone mode, in inetd mode you should use an inetd server
# that allows you to limit maximum number of processes per service
# (such as xinetd)
MaxInstances 30

#Following part of this config file were generate by PSA automatically
#Any changes in this part will be overwritten by next manipulation
#with Anonymous FTP feature in PSA control panel.

#Include directive should point to place where FTP Virtual Hosts configurations

ScoreboardFile /var/run/proftpd/scoreboard

# Primary log file mest be outside of system logrotate province

TransferLog /usr/local/psa/var/log/xferlog

#Change default group for new files and directories in vhosts dir to psacln

<Directory /var/www/vhosts>
GroupOwner psacln

# Enable PAM authentication
AuthPAM on
AuthPAMConfig proftpd

IdentLookups off
UseReverseDNS off

AuthGroupFile /etc/group

Include /etc/proftpd.include

Any assistance at all will be greatly appreciated!

Last edited by annamonster; 08-24-2006 at 12:34 PM.
Old 08-25-2006, 04:50 AM   #2
LQ Guru
Registered: Jul 2003
Location: Los Angeles
Distribution: Ubuntu
Posts: 9,870

Rep: Reputation: 380Reputation: 380Reputation: 380Reputation: 380
does your firewall log show any packets getting filtered when this happens??
Old 08-28-2006, 02:29 PM   #3
Registered: Aug 2002
Location: St Louis, MO
Distribution: Xubuntu, RHEL, Solaris 10
Posts: 929

Rep: Reputation: 30
Oddly enough, I have this exact problem - and have it with both vsftpd and proftpd, so the chances of it being a networking problem are getting greater and greater. Unfortunately I have a router with the world's worst configuration utility, so I can't trace blocked packets or anything of that nature.

If I come up with something, I'll post it back here. 'Til then, it all works as long as I'm using a client where I an explicitly turn off passive mode, i.e. any linux commandline client. WinXP's commandline client doesn't recognize any of 'pasv', 'PASV' or 'passive', so it's altogether useless except for further testing.


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
ProFTPD hangs on "227 Entering Passive Mode" VirusHater Linux - Newbie 4 06-30-2010 05:26 PM
[B]"wireless network" config from "system" hangs[/B] dauphinfay Ubuntu 0 03-04-2006 03:16 PM
ProFTPd- "Illegal PORT Command" JCdude2525 Linux - Networking 5 12-06-2004 05:42 AM
Tiny Sofa 2.0 - I thought "halt", "reboot" were only root command ?? sorcerer Linux - Distributions 1 08-21-2004 03:28 PM
System hangs when using "rpm" command doncrawley Red Hat 5 09-03-2003 01:34 AM > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 01:10 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration