Discussion:
[Proftpd-user] LIST command stalled - proftpd not listing content
Lista Unx
2016-12-07 12:07:01 UTC
Permalink
Hello all,

Trying to isolate a global problem which I have on another system, I've installed proftpd on centos 7 box, standalone. From the beginning Selinux and firewall has been disabled!

When trying to connect locally and LIST content in current path, nothing is displayed and the process is still running in loop.

So I've started proftpd in debug mode.
All the time (anonymous or valid user) I've got the same message: "added timer ID 4 ('TimeoutStalled', for module '[none]'), triggering in 3600 seconds" ...

What does module NONE mean and how can be solved? Seems proftpd is not loading correct module ... See below:

[***@ftpd alex]# telnet localhost 21
Trying 127.0.0.1...
Connected to localhost.
Escape character is '^]'.
220 FTP Server ready.
user alex
331 Password required for alex
pass
230 User alex logged in
pasv
227 Entering Passive Mode (192,168,13,104,194,82).
stat
211-Status of 'ProFTPD server'
Connected from 127.0.0.1 (127.0.0.1)
Logged in as alex
TYPE: ASCII, STRUcture: File, Mode: Stream
No data connection
211 End of status
list
^]
telnet> quit
Connection closed.

Proftpd has been started as following:
[***@ftpd alex]# proftpd -4 -c /etc/proftpd.conf -d 10 -n
...
2016-12-07 13:28:58,656 ftpd.rhce.local proftpd[24781] 192.168.13.104 (127.0.0.1[127.0.0.1]): dispatching PRE_CMD command 'LIST' to mod_tls
2016-12-07 13:28:58,656 ftpd.rhce.local proftpd[24781] 192.168.13.104 (127.0.0.1[127.0.0.1]): dispatching PRE_CMD command 'LIST' to mod_core
2016-12-07 13:28:58,656 ftpd.rhce.local proftpd[24781] 192.168.13.104 (127.0.0.1[127.0.0.1]): dispatching PRE_CMD command 'LIST' to mod_core
2016-12-07 13:28:58,656 ftpd.rhce.local proftpd[24781] 192.168.13.104 (127.0.0.1[127.0.0.1]): dispatching CMD command 'LIST' to mod_ls
2016-12-07 13:30:35,926 ftpd.rhce.local proftpd[24705] 192.168.13.104 (127.0.0.1[127.0.0.1]): ProFTPD terminating (signal 2)
2016-12-07 13:30:35,926 ftpd.rhce.local proftpd[24705] 192.168.13.104 (127.0.0.1[127.0.0.1]): FTP session closed.

and in tracelog:

2016-12-07 13:28:52,746 [24781] <response:1>: Logged in as alex
2016-12-07 13:28:52,746 [24781] <response:1>: TYPE: ASCII, STRUcture: File, Mode: Stream
2016-12-07 13:28:52,746 [24781] <response:1>: No data connection
2016-12-07 13:28:52,746 [24781] <response:1>: 211 End of status

2016-12-07 13:28:58,171 [24779] <signal:5>: signals blocked
2016-12-07 13:28:58,371 [24779] <signal:5>: signals unblocked
2016-12-07 13:28:58,371 [24779] <signal:9>: handling SIGALRM (signal 14)
2016-12-07 13:28:58,371 [24779] <timer:4>: 10 seconds for timer ID 24075 ('Controls polling', for module 'ctrls') elapsed, invoking callback (0x7ff9987c2530)
2016-12-07 13:28:58,372 [24779] <timer:6>: restarting timer ID 24075 ('Controls polling'), as per callback
2016-12-07 13:28:58,372 [24779] <fsio:8>: using system lstat() for path '/etc/shutmsg'
2016-12-07 13:28:58,656 [24781] <timer:7>: reset timer ID 2 ('TimeoutIdle', for module '[none]')
2016-12-07 13:28:58,656 [24781] <response:9>: clearing response lists before dispatching command 'list'
2016-12-07 13:28:58,656 [24781] <encode:5>: decoded 'LIST' into 'LIST'
2016-12-07 13:28:58,656 [24781] <command:7>: dispatching PRE_CMD command 'LIST' to mod_tls.c
2016-12-07 13:28:58,656 [24781] <command:7>: dispatching PRE_CMD command 'LIST' to mod_core.c
2016-12-07 13:28:58,656 [24781] <command:7>: dispatching PRE_CMD command 'LIST' to mod_core.c
2016-12-07 13:28:58,656 [24781] <scoreboard:3>: updating scoreboard entry
2016-12-07 13:28:58,656 [24781] <lock:9>: attempting to write-lock scoreboard fd 14 entry, offset 32
2016-12-07 13:28:58,656 [24781] <lock:9>: write-lock of scoreboard fd 14 entry, offset 32 succeeded
2016-12-07 13:28:58,656 [24781] <lock:9>: attempting to unlock scoreboard fd 14 entry, offset 32
2016-12-07 13:28:58,656 [24781] <lock:9>: unlock of scoreboard fd 14 entry, offset 32 succeeded
2016-12-07 13:28:58,656 [24781] <scoreboard:3>: finished updating scoreboard entry
2016-12-07 13:28:58,656 [24781] <scoreboard:3>: updating scoreboard entry
2016-12-07 13:28:58,656 [24781] <lock:9>: attempting to write-lock scoreboard fd 14 entry, offset 32
2016-12-07 13:28:58,656 [24781] <lock:9>: write-lock of scoreboard fd 14 entry, offset 32 succeeded
2016-12-07 13:28:58,656 [24781] <lock:9>: attempting to unlock scoreboard fd 14 entry, offset 32
2016-12-07 13:28:58,656 [24781] <lock:9>: unlock of scoreboard fd 14 entry, offset 32 succeeded
2016-12-07 13:28:58,656 [24781] <scoreboard:3>: finished updating scoreboard entry
2016-12-07 13:28:58,656 [24781] <command:7>: dispatching CMD command 'LIST' to mod_ls.c
2016-12-07 13:28:58,656 [24781] <encode:5>: decoded '' into ''
2016-12-07 13:28:58,656 [24781] <fsio:8>: using system stat() for path ''
2016-12-07 13:28:58,656 [24781] <data:8>: allocated data transfer buffer of 16384 bytes
2016-12-07 13:28:58,656 [24781] <timer:7>: added timer ID 4 ('TimeoutStalled', for module '[none]'), triggering in 3600 seconds
and jump again to beginning: "<signal:5>: signals blocked" forever if not stopped manually.
^C
[***@ftpd ~]#

See below my proftpd.conf

[***@ftpd alex]# cat /etc/proftpd.conf
ServerName "ProFTPD server"
ServerIdent on "FTP Server ready."
ServerAdmin ***@localhost
DefaultServer on

DefaultRoot ~ !adm

AuthPAMConfig proftpd
AuthOrder mod_auth_pam.c* mod_auth_unix.c

UseReverseDNS off

User nobody
Group nobody

MaxInstances 20

UseSendfile off

LogFormat default "%h %l %u %t \"%r\" %s %b"
LogFormat auth "%v [%P] %h %t \"%r\" %s"

LoadModule mod_ctrls_admin.c
LoadModule mod_vroot.c
LoadModule mod_ls.c

ModuleControlsACLs insmod,rmmod allow user root
ModuleControlsACLs lsmod allow user *

ControlsEngine on
ControlsACLs all allow user root
ControlsSocketACL allow user *
ControlsLog /var/log/proftpd/controls.log

<IfModule mod_ctrls_admin.c>
AdminControlsEngine on
AdminControlsACLs all allow user root
</IfModule>

<Global>

Umask 022

# Allow users to overwrite files and change permissions
AllowOverwrite yes
<Limit ALL SITE_CHMOD>
AllowAll
</Limit>
<Limit LIST>
AllowAll
</Limit>

</Global>

<Anonymous ~ftp>
User ftp
Group ftp
AccessGrantMsg "Anonymous login ok, restrictions apply."

UserAlias anonymous ftp
MaxClients 10 "Sorry, max %m users -- try again later"

DefaultChdir /pub

DisplayLogin /welcome.msg
DisplayChdir .message
DisplayReadme README*

DirFakeUser on ftp
DirFakeGroup on ftp

# Limit WRITE everywhere in the anonymous chroot
<Limit WRITE SITE_CHMOD>
DenyAll
</Limit>
# Allow read, list
<Limit READ LIST>
AllowAll
</Limit>

# Don't write anonymous accesses to the system wtmp file (good idea!)
WtmpLog off

# Logging for the anonymous transfers
ExtendedLog /var/log/proftpd/access.log WRITE,READ default
ExtendedLog /var/log/proftpd/auth.log AUTH auth

</Anonymous>

MasqueradeAddress 192.168.13.104
PassivePorts 49152 65534

<IfModule mod_facts.c>
FactsAdvertise off
</IfModule>

TraceLog /var/log/proftpd/trace.log
Trace DEFAULT:10

ScoreboardScrub off
[***@ftpd alex]#

What is missing or what is wrong in my proftpd.conf (proftpd-1.3.5b-2.el7.x86_64)?


Thank you in advance for help.
Alex
Matus UHLAR - fantomas
2016-12-07 13:57:18 UTC
Permalink
Post by Lista Unx
When trying to connect locally and LIST content in current path, nothing is displayed and the process is still running in loop.
So I've started proftpd in debug mode.
All the time (anonymous or valid user) I've got the same message: "added timer ID 4 ('TimeoutStalled', for module '[none]'), triggering in 3600 seconds" ...
Trying 127.0.0.1...
Connected to localhost.
Escape character is '^]'.
220 FTP Server ready.
user alex
331 Password required for alex
pass
230 User alex logged in
pasv
227 Entering Passive Mode (192,168,13,104,194,82).
MasqueradeAddress 192.168.13.104
is the address 192.168.13.104 configured on your local machine?
--
Matus UHLAR - fantomas, ***@fantomas.sk ; http://www.fantomas.sk/
Warning: I wish NOT to receive e-mail advertising to this address.
Varovanie: na tuto adresu chcem NEDOSTAVAT akukolvek reklamnu postu.
M$ Win's are shit, do not use it !

------------------------------------------------------------------------------
Developer Access Program for Intel Xeon Phi Processors
Access to Intel Xeon Phi processor-based developer platforms.
With one year of Intel Parallel Studio XE.
Training and support from Colfax.
Order your platform today.http://sdm.link/xeonphi
_______________________________________________
ProFTPD Users List <proftpd-***@proftpd.org>
Unsubscribe problems?
http://www.proftpd.org/list-unsub.html
Lista Unx
2016-12-07 19:48:02 UTC
Permalink
Yes, of course. 192.168.13.104 is the address assigned to ens160 interface
which is up and running!

----- Original Message -----
From: "Matus UHLAR - fantomas" <***@fantomas.sk>
To: <proftp-***@lists.sourceforge.net>
Sent: Wednesday, December 07, 2016 3:57 PM
Subject: Re: [Proftpd-user] LIST command stalled - proftpd not
listingcontent
Post by Matus UHLAR - fantomas
Post by Lista Unx
When trying to connect locally and LIST content in current path, nothing
is displayed and the process is still running in loop.
So I've started proftpd in debug mode.
All the time (anonymous or valid user) I've got the same message: "added
timer ID 4 ('TimeoutStalled', for module '[none]'), triggering in 3600
seconds" ...
What does module NONE mean and how can be solved? Seems proftpd is not
Trying 127.0.0.1...
Connected to localhost.
Escape character is '^]'.
220 FTP Server ready.
user alex
331 Password required for alex
pass
230 User alex logged in
pasv
227 Entering Passive Mode (192,168,13,104,194,82).
MasqueradeAddress 192.168.13.104
is the address 192.168.13.104 configured on your local machine?
--
Warning: I wish NOT to receive e-mail advertising to this address.
Varovanie: na tuto adresu chcem NEDOSTAVAT akukolvek reklamnu postu.
M$ Win's are shit, do not use it !
------------------------------------------------------------------------------
Developer Access Program for Intel Xeon Phi Processors
Access to Intel Xeon Phi processor-based developer platforms.
With one year of Intel Parallel Studio XE.
Training and support from Colfax.
Order your platform today.http://sdm.link/xeonphi
_______________________________________________
Unsubscribe problems?
http://www.proftpd.org/list-unsub.html
------------------------------------------------------------------------------
Developer Access Program for Intel Xeon Phi Processors
Access to Intel Xeon Phi processor-based developer platforms.
With one year of Intel Parallel Studio XE.
Training and support from Colfax.
Order your platform today.http://sdm.link/xeonphi
_______________________________________________
ProFTPD Users List <proftpd-***@proftpd.org>
Unsubscribe problems?
http://www.proftpd.org/list-unsub.html
TJ Saunders
2016-12-07 16:19:00 UTC
Permalink
Post by Lista Unx
Hello all,
Trying to isolate a global problem which I have on another system, I've
installed proftpd on centos 7 box, standalone. From the beginning Selinux
and firewall has been disabled!
When trying to connect locally and LIST content in current path, nothing
is displayed and the process is still running in loop.
Trying 127.0.0.1...
Connected to localhost.
Here you contact your FTP server on 127.0.0.1 for the control
connection.
Post by Lista Unx
pasv
227 Entering Passive Mode (192,168,13,104,194,82).
And here you requested a passive data transfer. The server responded
with
address 192.168.13.104, instructing the FTP client to contact that
address
for the requested data. This is a little odd, since normally the FTP
server
should tell the client to connect to the same IP address for data
transfers
as for the initial control connection...
Post by Lista Unx
See below my proftpd.conf
MasqueradeAddress 192.168.13.104
And here, with this MasqueradeAddress, we see WHY your server is telling
your client to use the "wrong" IP address.

I suspect that you will need to use a <VirtualHost> section for your WAN
address -- and in that <VirtualHost> section, that's where you would use
that
MasqueradeAddress directive, so that it applied only to connections
which used
the WAN address.

For LAN connections, you probably do NOT want to use a
MasqueradeAddress; this
might help:

http://www.proftpd.org/docs/howto/NAT.html

Cheers,
TJ

------------------------------------------------------------------------------
Developer Access Program for Intel Xeon Phi Processors
Access to Intel Xeon Phi processor-based developer platforms.
With one year of Intel Parallel Studio XE.
Training and support from Colfax.
Order your platform today.http://sdm.link/xeonphi
_______________________________________________
ProFTPD Users List <proftpd-***@proftpd.org>
Unsubscribe problems?
http://www.proftpd.org/list-unsub.html
Lista Unx
2016-12-07 19:49:49 UTC
Permalink
I removed Masquerade, which has been just a try. I can confir, Behaviour is
the same: with or WITHOUT masquerade address. LIST command is stalled!

----- Original Message -----
From: "TJ Saunders" <***@castaglia.org>
To: "Lista Unx" <***@gmail.com>; <proftp-***@lists.sourceforge.net>
Sent: Wednesday, December 07, 2016 6:19 PM
Subject: Re: [Proftpd-user] LIST command stalled - proftpd not listing
content
Post by TJ Saunders
Post by Lista Unx
Hello all,
Trying to isolate a global problem which I have on another system, I've
installed proftpd on centos 7 box, standalone. From the beginning Selinux
and firewall has been disabled!
When trying to connect locally and LIST content in current path, nothing
is displayed and the process is still running in loop.
Trying 127.0.0.1...
Connected to localhost.
Here you contact your FTP server on 127.0.0.1 for the control
connection.
Post by Lista Unx
pasv
227 Entering Passive Mode (192,168,13,104,194,82).
And here you requested a passive data transfer. The server responded
with
address 192.168.13.104, instructing the FTP client to contact that
address
for the requested data. This is a little odd, since normally the FTP
server
should tell the client to connect to the same IP address for data
transfers
as for the initial control connection...
Post by Lista Unx
See below my proftpd.conf
MasqueradeAddress 192.168.13.104
And here, with this MasqueradeAddress, we see WHY your server is telling
your client to use the "wrong" IP address.
I suspect that you will need to use a <VirtualHost> section for your WAN
address -- and in that <VirtualHost> section, that's where you would use
that
MasqueradeAddress directive, so that it applied only to connections
which used
the WAN address.
For LAN connections, you probably do NOT want to use a
MasqueradeAddress; this
http://www.proftpd.org/docs/howto/NAT.html
Cheers,
TJ
------------------------------------------------------------------------------
Developer Access Program for Intel Xeon Phi Processors
Access to Intel Xeon Phi processor-based developer platforms.
With one year of Intel Parallel Studio XE.
Training and support from Colfax.
Order your platform today.http://sdm.link/xeonphi
_______________________________________________
ProFTPD Users List <proftpd-***@proftpd.org>
Unsubscribe problems?
http://www.proftpd.org/list-unsub.html
lista unx
2016-12-08 10:09:00 UTC
Permalink
To be simple for everyone, I've changed configuration file with one very
simple (few lines) and repeat tests. The problem remain. LIST is stalled!

[***@ftpd alex]# telnet 192.168.13.104 21
Trying 192.168.13.104...
Connected to 192.168.13.104.
Escape character is '^]'.
220 ProFTPD 1.3.5b Server (ProFTPD Default Installation) [192.168.13.104]
user ftp
331 Anonymous login ok, send your complete email address as your password
pass ftp
230- Anonymous access granted, restrictions apply
pasv
227 Entering Passive Mode (192,168,13,104,132,2).
stat
211-Status of 'ProFTPD Default Installation'
Connected from ftpd.rhce.local (192.168.13.104)
Logged in as ftp
TYPE: ASCII, STRUcture: File, Mode: Stream
No data connection
211 End of status
list
^]
telnet> quit
Connection closed.
[***@ftpd alex]#

[***@ftpd ~]# proftpd -4 -c /etc/proftpd.conf -d 10 -n
...
2016-12-08 12:00:48,266 ftpd.rhce.local proftpd[4968] ftpd.rhce.local
(ftpd.rhce.local[192.168.13.104]): FTP session closed.
2016-12-08 12:02:40,338 ftpd.rhce.local proftpd[4991] ftpd.rhce.local
(ftpd.rhce.local[192.168.13.104]): ProFTPD terminating (signal 2)
2016-12-08 12:02:40,338 ftpd.rhce.local proftpd[4991] ftpd.rhce.local
(ftpd.rhce.local[192.168.13.104]): FTP session closed.
2016-12-08 12:04:03,491 ftpd.rhce.local proftpd[5012] ftpd.rhce.local
(ftpd.rhce.local[192.168.13.104]): Client session idle timeout, disconnected
2016-12-08 12:04:03,491 ftpd.rhce.local proftpd[5012] ftpd.rhce.local
(ftpd.rhce.local[192.168.13.104]): FTP session closed.

and in tracelog

2016-12-08 11:53:59,858 [5012] <response:1>: Logged in as ftp
2016-12-08 11:53:59,858 [5012] <response:1>: TYPE: ASCII, STRUcture: File,
Mode: Stream
2016-12-08 11:53:59,858 [5012] <response:1>: No data connection
2016-12-08 11:53:59,858 [5012] <response:1>: 211 End of status
2016-12-08 11:54:03,290 [5012] <timer:7>: reset timer ID 2 ('TimeoutIdle',
for module '[none]')
2016-12-08 11:54:03,290 [5012] <response:9>: clearing response lists before
dispatching command 'list'
2016-12-08 11:54:03,290 [5012] <encode:5>: decoded 'LIST' into 'LIST'
2016-12-08 11:54:03,290 [5012] <command:7>: dispatching PRE_CMD command
'LIST' to mod_tls.c
2016-12-08 11:54:03,290 [5012] <command:7>: dispatching PRE_CMD command
'LIST' to mod_core.c
2016-12-08 11:54:03,290 [5012] <command:7>: dispatching PRE_CMD command
'LIST' to mod_core.c
2016-12-08 11:54:03,290 [5012] <scoreboard:3>: updating scoreboard entry
2016-12-08 11:54:03,290 [5012] <lock:9>: attempting to write-lock
scoreboard fd 10 entry, offset 32
2016-12-08 11:54:03,290 [5012] <lock:9>: write-lock of scoreboard fd 10
entry, offset 32 succeeded
2016-12-08 11:54:03,290 [5012] <lock:9>: attempting to unlock scoreboard fd
10 entry, offset 32
2016-12-08 11:54:03,290 [5012] <lock:9>: unlock of scoreboard fd 10 entry,
offset 32 succeeded
2016-12-08 11:54:03,290 [5012] <scoreboard:3>: finished updating scoreboard
entry
2016-12-08 11:54:03,290 [5012] <scoreboard:3>: updating scoreboard entry
2016-12-08 11:54:03,290 [5012] <lock:9>: attempting to write-lock
scoreboard fd 10 entry, offset 32
2016-12-08 11:54:03,290 [5012] <lock:9>: write-lock of scoreboard fd 10
entry, offset 32 succeeded
2016-12-08 11:54:03,290 [5012] <lock:9>: attempting to unlock scoreboard fd
10 entry, offset 32
2016-12-08 11:54:03,290 [5012] <lock:9>: unlock of scoreboard fd 10 entry,
offset 32 succeeded
2016-12-08 11:54:03,290 [5012] <scoreboard:3>: finished updating scoreboard
entry




*2016-12-08 11:54:03,290 [5012] <command:7>: dispatching CMD command 'LIST'
to mod_ls.c2016-12-08 11:54:03,290 [5012] <encode:5>: decoded '' into
''2016-12-08 11:54:03,290 [5012] <fsio:8>: using system stat() for path
''2016-12-08 11:54:03,290 [5012] <data:8>: allocated data transfer buffer
of 16384 bytes2016-12-08 11:54:03,290 [5012] <timer:7>: added timer ID 4
('TimeoutStalled', for module '[none]'), triggering in 3600 seconds*
2016-12-08 11:54:04,496 [5009] <signal:5>: signals blocked
2016-12-08 11:54:04,697 [5009] <signal:5>: signals unblocked
2016-12-08 11:54:04,697 [5009] <signal:9>: handling SIGALRM (signal 14)
2016-12-08 11:54:04,697 [5009] <timer:4>: 10 seconds for timer ID 24075
('Controls polling', for module 'ctrls') elapsed, invoking callback
(0x7fa2bb6f0530)
2016-12-08 11:54:04,697 [5009] <timer:6>: restarting timer ID 24075
('Controls polling'), as per callback
2016-12-08 11:54:04,697 [5009] <fsio:8>: using system lstat() for path
'/etc/shutmsg'
^C

So, LIST is stalled!

Where could be the problem?

Does anyone can post here a valid config file which is working on
Rhel/Centos 7 with LIST command in a telnet session?

Thanks in advance,
Alex
Post by Lista Unx
I removed Masquerade, which has been just a try. I can confir, Behaviour
is the same: with or WITHOUT masquerade address. LIST command is stalled!
Sent: Wednesday, December 07, 2016 6:19 PM
Subject: Re: [Proftpd-user] LIST command stalled - proftpd not listing
content
Post by TJ Saunders
Post by Lista Unx
Hello all,
Trying to isolate a global problem which I have on another system, I've
installed proftpd on centos 7 box, standalone. From the beginning Selinux
and firewall has been disabled!
When trying to connect locally and LIST content in current path, nothing
is displayed and the process is still running in loop.
Trying 127.0.0.1...
Connected to localhost.
Here you contact your FTP server on 127.0.0.1 for the control
connection.
pasv
Post by Lista Unx
227 Entering Passive Mode (192,168,13,104,194,82).
And here you requested a passive data transfer. The server responded
with
address 192.168.13.104, instructing the FTP client to contact that
address
for the requested data. This is a little odd, since normally the FTP
server
should tell the client to connect to the same IP address for data
transfers
as for the initial control connection...
See below my proftpd.conf
MasqueradeAddress 192.168.13.104
And here, with this MasqueradeAddress, we see WHY your server is telling
your client to use the "wrong" IP address.
I suspect that you will need to use a <VirtualHost> section for your WAN
address -- and in that <VirtualHost> section, that's where you would use
that
MasqueradeAddress directive, so that it applied only to connections
which used
the WAN address.
For LAN connections, you probably do NOT want to use a
MasqueradeAddress; this
http://www.proftpd.org/docs/howto/NAT.html
Cheers,
TJ
Matus UHLAR - fantomas
2016-12-08 18:27:41 UTC
Permalink
Post by lista unx
To be simple for everyone, I've changed configuration file with one very
simple (few lines) and repeat tests. The problem remain. LIST is stalled!
Trying 192.168.13.104...
Connected to 192.168.13.104.
Escape character is '^]'.
220 ProFTPD 1.3.5b Server (ProFTPD Default Installation) [192.168.13.104]
user ftp
331 Anonymous login ok, send your complete email address as your password
pass ftp
230- Anonymous access granted, restrictions apply
pasv
227 Entering Passive Mode (192,168,13,104,132,2).
stat
211-Status of 'ProFTPD Default Installation'
Connected from ftpd.rhce.local (192.168.13.104)
Logged in as ftp
TYPE: ASCII, STRUcture: File, Mode: Stream
No data connection
211 End of status
list
tried localhost?
Post by lista unx
...
2016-12-08 12:00:48,266 ftpd.rhce.local proftpd[4968] ftpd.rhce.local
(ftpd.rhce.local[192.168.13.104]): FTP session closed.
any firewall on the local machine?
--
Matus UHLAR - fantomas, ***@fantomas.sk ; http://www.fantomas.sk/
Warning: I wish NOT to receive e-mail advertising to this address.
Varovanie: na tuto adresu chcem NEDOSTAVAT akukolvek reklamnu postu.
Linux is like a teepee: no Windows, no Gates and an apache inside...

------------------------------------------------------------------------------
Developer Access Program for Intel Xeon Phi Processors
Access to Intel Xeon Phi processor-based developer platforms.
With one year of Intel Parallel Studio XE.
Training and support from Colfax.
Order your platform today.http://sdm.link/xeonphi
_______________________________________________
ProFTPD Users List <proftpd-***@proftpd.org>
Unsubscribe problems?
http://www.proftpd.org/list-unsub.html
Dieter Bloms
2016-12-08 20:01:16 UTC
Permalink
Hi,
Post by lista unx
To be simple for everyone, I've changed configuration file with one very
simple (few lines) and repeat tests. The problem remain. LIST is stalled!
telnet is not a ftp client.
For file listing or file transfer a data connections is needed.
So please try a real ftp client and then the LIST should work.
--
Regards

Dieter Bloms

--
I do not get viruses because I do not use MS software.
If you use Outlook then please do not put my email address in your
address-book so that WHEN you get a virus it won't use my address in the
Post by lista unx
From field.
------------------------------------------------------------------------------
Developer Access Program for Intel Xeon Phi Processors
Access to Intel Xeon Phi processor-based developer platforms.
With one year of Intel Parallel Studio XE.
Training and support from Colfax.
Order your platform today.http://sdm.link/xeonphi
_______________________________________________
ProFTPD Users List <proftpd-***@proftpd.org>
Unsubscribe problems?
http://www.proftpd.org/list-unsub.html
Tom Brown
2016-12-08 18:08:41 UTC
Permalink
what you show is perfectly normal... and is why most folks don't try to
mess with data connections over telnet. FTP uses two connections, and it
is "stalled" waiting for the second connection.

main connection:
230 User tbrown logged in.
pasv
227 Entering Passive Mode (67,223,102,138,161,81).

go calculate port: 161 * 256 + 81 = 41297


ok, setup connection to that other port

[***@puppet ~]# telnet am5 41297
Trying 67.223.102.138...
Connected to am5.
Escape character is '^]'.

run the list command
list

and voila, data on the second connection

drwxr-x--x 24 tbrown tbrown 4096 Dec 8 00:00 .
drwxr-x--x 24 tbrown tbrown 4096 Dec 8 00:00 ..
-rw-r--r-- 1 tbrown tbrown 0 Dec 31 1995 .addressbook
-rw-r--r-- 1 tbrown tbrown 1257 Dec 31 1995 .addressbook.lu
-rw-r--r-- 1 tbrown tbrown 13843 Dec 7 00:50 .bash_history
-rw-r--r-- 1 root root 190 Jul 15 2015 .bashrc
-rw------- 1 tbrown tbrown 55 Feb 20 2003 .cvspass
...
-rw-r--r-- 1 tbrown tbrown 5922791 Jun 10 2003 whoisservice-lookup.log
Connection closed by foreign host.

and feedback on the normal (control) connection


150 Opening ASCII mode data connection for file list
226 Transfer complete
quit
221 Goodbye.

#

... but you've gotta do TWO telnet sessions and you gotta calculate the
port number from the pasv resposne.

-Tom
Post by Lista Unx
Hello all,
Trying to isolate a global problem which I have on another system, I've installed proftpd on centos 7 box, standalone. From the beginning Selinux and firewall has been disabled!
When trying to connect locally and LIST content in current path, nothing is displayed and the process is still running in loop.
So I've started proftpd in debug mode.
All the time (anonymous or valid user) I've got the same message: "added timer ID 4 ('TimeoutStalled', for module '[none]'), triggering in 3600 seconds" ...
Trying 127.0.0.1...
Connected to localhost.
Escape character is '^]'.
220 FTP Server ready.
user alex
331 Password required for alex
pass
230 User alex logged in
pasv
227 Entering Passive Mode (192,168,13,104,194,82).
stat
211-Status of 'ProFTPD server'
Connected from 127.0.0.1 (127.0.0.1)
Logged in as alex
TYPE: ASCII, STRUcture: File, Mode: Stream
No data connection
211 End of status
list
^]
telnet> quit
Connection closed.
...
2016-12-07 13:28:58,656 ftpd.rhce.local proftpd[24781] 192.168.13.104 (127.0.0.1[127.0.0.1]): dispatching PRE_CMD command 'LIST' to mod_tls
2016-12-07 13:28:58,656 ftpd.rhce.local proftpd[24781] 192.168.13.104 (127.0.0.1[127.0.0.1]): dispatching PRE_CMD command 'LIST' to mod_core
2016-12-07 13:28:58,656 ftpd.rhce.local proftpd[24781] 192.168.13.104 (127.0.0.1[127.0.0.1]): dispatching PRE_CMD command 'LIST' to mod_core
2016-12-07 13:28:58,656 ftpd.rhce.local proftpd[24781] 192.168.13.104 (127.0.0.1[127.0.0.1]): dispatching CMD command 'LIST' to mod_ls
2016-12-07 13:30:35,926 ftpd.rhce.local proftpd[24705] 192.168.13.104 (127.0.0.1[127.0.0.1]): ProFTPD terminating (signal 2)
2016-12-07 13:30:35,926 ftpd.rhce.local proftpd[24705] 192.168.13.104 (127.0.0.1[127.0.0.1]): FTP session closed.
2016-12-07 13:28:52,746 [24781] <response:1>: Logged in as alex
2016-12-07 13:28:52,746 [24781] <response:1>: TYPE: ASCII, STRUcture: File, Mode: Stream
2016-12-07 13:28:52,746 [24781] <response:1>: No data connection
2016-12-07 13:28:52,746 [24781] <response:1>: 211 End of status
2016-12-07 13:28:58,171 [24779] <signal:5>: signals blocked
2016-12-07 13:28:58,371 [24779] <signal:5>: signals unblocked
2016-12-07 13:28:58,371 [24779] <signal:9>: handling SIGALRM (signal 14)
2016-12-07 13:28:58,371 [24779] <timer:4>: 10 seconds for timer ID 24075 ('Controls polling', for module 'ctrls') elapsed, invoking callback (0x7ff9987c2530)
2016-12-07 13:28:58,372 [24779] <timer:6>: restarting timer ID 24075 ('Controls polling'), as per callback
2016-12-07 13:28:58,372 [24779] <fsio:8>: using system lstat() for path '/etc/shutmsg'
2016-12-07 13:28:58,656 [24781] <timer:7>: reset timer ID 2 ('TimeoutIdle', for module '[none]')
2016-12-07 13:28:58,656 [24781] <response:9>: clearing response lists before dispatching command 'list'
2016-12-07 13:28:58,656 [24781] <encode:5>: decoded 'LIST' into 'LIST'
2016-12-07 13:28:58,656 [24781] <command:7>: dispatching PRE_CMD command 'LIST' to mod_tls.c
2016-12-07 13:28:58,656 [24781] <command:7>: dispatching PRE_CMD command 'LIST' to mod_core.c
2016-12-07 13:28:58,656 [24781] <command:7>: dispatching PRE_CMD command 'LIST' to mod_core.c
2016-12-07 13:28:58,656 [24781] <scoreboard:3>: updating scoreboard entry
2016-12-07 13:28:58,656 [24781] <lock:9>: attempting to write-lock scoreboard fd 14 entry, offset 32
2016-12-07 13:28:58,656 [24781] <lock:9>: write-lock of scoreboard fd 14 entry, offset 32 succeeded
2016-12-07 13:28:58,656 [24781] <lock:9>: attempting to unlock scoreboard fd 14 entry, offset 32
2016-12-07 13:28:58,656 [24781] <lock:9>: unlock of scoreboard fd 14 entry, offset 32 succeeded
2016-12-07 13:28:58,656 [24781] <scoreboard:3>: finished updating scoreboard entry
2016-12-07 13:28:58,656 [24781] <scoreboard:3>: updating scoreboard entry
2016-12-07 13:28:58,656 [24781] <lock:9>: attempting to write-lock scoreboard fd 14 entry, offset 32
2016-12-07 13:28:58,656 [24781] <lock:9>: write-lock of scoreboard fd 14 entry, offset 32 succeeded
2016-12-07 13:28:58,656 [24781] <lock:9>: attempting to unlock scoreboard fd 14 entry, offset 32
2016-12-07 13:28:58,656 [24781] <lock:9>: unlock of scoreboard fd 14 entry, offset 32 succeeded
2016-12-07 13:28:58,656 [24781] <scoreboard:3>: finished updating scoreboard entry
2016-12-07 13:28:58,656 [24781] <command:7>: dispatching CMD command 'LIST' to mod_ls.c
2016-12-07 13:28:58,656 [24781] <encode:5>: decoded '' into ''
2016-12-07 13:28:58,656 [24781] <fsio:8>: using system stat() for path ''
2016-12-07 13:28:58,656 [24781] <data:8>: allocated data transfer buffer of 16384 bytes
2016-12-07 13:28:58,656 [24781] <timer:7>: added timer ID 4 ('TimeoutStalled', for module '[none]'), triggering in 3600 seconds
and jump again to beginning: "<signal:5>: signals blocked" forever if not stopped manually.
^C
See below my proftpd.conf
ServerName "ProFTPD server"
ServerIdent on "FTP Server ready."
DefaultServer on
DefaultRoot ~ !adm
AuthPAMConfig proftpd
AuthOrder mod_auth_pam.c* mod_auth_unix.c
UseReverseDNS off
User nobody
Group nobody
MaxInstances 20
UseSendfile off
LogFormat default "%h %l %u %t \"%r\" %s %b"
LogFormat auth "%v [%P] %h %t \"%r\" %s"
LoadModule mod_ctrls_admin.c
LoadModule mod_vroot.c
LoadModule mod_ls.c
ModuleControlsACLs insmod,rmmod allow user root
ModuleControlsACLs lsmod allow user *
ControlsEngine on
ControlsACLs all allow user root
ControlsSocketACL allow user *
ControlsLog /var/log/proftpd/controls.log
<IfModule mod_ctrls_admin.c>
AdminControlsEngine on
AdminControlsACLs all allow user root
</IfModule>
<Global>
Umask 022
# Allow users to overwrite files and change permissions
AllowOverwrite yes
<Limit ALL SITE_CHMOD>
AllowAll
</Limit>
<Limit LIST>
AllowAll
</Limit>
</Global>
<Anonymous ~ftp>
User ftp
Group ftp
AccessGrantMsg "Anonymous login ok, restrictions apply."
UserAlias anonymous ftp
MaxClients 10 "Sorry, max %m users -- try again later"
DefaultChdir /pub
DisplayLogin /welcome.msg
DisplayChdir .message
DisplayReadme README*
DirFakeUser on ftp
DirFakeGroup on ftp
# Limit WRITE everywhere in the anonymous chroot
<Limit WRITE SITE_CHMOD>
DenyAll
</Limit>
# Allow read, list
<Limit READ LIST>
AllowAll
</Limit>
# Don't write anonymous accesses to the system wtmp file (good idea!)
WtmpLog off
# Logging for the anonymous transfers
ExtendedLog /var/log/proftpd/access.log WRITE,READ default
ExtendedLog /var/log/proftpd/auth.log AUTH auth
</Anonymous>
MasqueradeAddress 192.168.13.104
PassivePorts 49152 65534
<IfModule mod_facts.c>
FactsAdvertise off
</IfModule>
TraceLog /var/log/proftpd/trace.log
Trace DEFAULT:10
ScoreboardScrub off
What is missing or what is wrong in my proftpd.conf (proftpd-1.3.5b-2.el7.x86_64)?
Thank you in advance for help.
Alex
----------------------------------------------------------------------
***@BareMetal.com | Courage is doing what you're afraid to do.
http://BareMetal.com/ | There can be no courage unless you're scared.
| - Eddie Rickenbacker

------------------------------------------------------------------------------
Developer Access Program for Intel Xeon Phi Processors
Access to Intel Xeon Phi processor-based developer platforms.
With one year of Intel Parallel Studio XE.
Training and support from Colfax.
Order your platform today.http://sdm.link/xeonphi
_______________________________________________
ProFTPD Users List <proftpd-***@proftpd.org>
Unsubscribe problems?
http://www.proftpd.org/list-unsub.html
lista unx
2016-12-09 09:39:42 UTC
Permalink
Hi Tom,

That's it! Bravo! Is over 10 years from I did not debug ftp using telnet
and forgot TO OPEN ANOTHER TERMINAL for data connection! Perfect answer.
Thank you Tom and all posters in this thread.

Regards,
Alex

On Thu, Dec 8, 2016 at 8:08 PM, Tom Brown <
Post by Tom Brown
what you show is perfectly normal... and is why most folks don't try to
mess with data connections over telnet. FTP uses two connections, and it
is "stalled" waiting for the second connection.
230 User tbrown logged in.
pasv
227 Entering Passive Mode (67,223,102,138,161,81).
go calculate port: 161 * 256 + 81 = 41297
ok, setup connection to that other port
Trying 67.223.102.138...
Connected to am5.
Escape character is '^]'.
run the list command
list
and voila, data on the second connection
drwxr-x--x 24 tbrown tbrown 4096 Dec 8 00:00 .
drwxr-x--x 24 tbrown tbrown 4096 Dec 8 00:00 ..
-rw-r--r-- 1 tbrown tbrown 0 Dec 31 1995 .addressbook
-rw-r--r-- 1 tbrown tbrown 1257 Dec 31 1995 .addressbook.lu
-rw-r--r-- 1 tbrown tbrown 13843 Dec 7 00:50 .bash_history
-rw-r--r-- 1 root root 190 Jul 15 2015 .bashrc
-rw------- 1 tbrown tbrown 55 Feb 20 2003 .cvspass
...
-rw-r--r-- 1 tbrown tbrown 5922791 Jun 10 2003
whoisservice-lookup.log
Connection closed by foreign host.
and feedback on the normal (control) connection
150 Opening ASCII mode data connection for file list
226 Transfer complete
quit
221 Goodbye.
#
... but you've gotta do TWO telnet sessions and you gotta calculate the
port number from the pasv resposne.
-Tom
Post by Lista Unx
Hello all,
Trying to isolate a global problem which I have on another system,
I've installed proftpd on centos 7 box, standalone. From the beginning
Selinux and firewall has been disabled!
Post by Lista Unx
When trying to connect locally and LIST content in current path,
nothing is displayed and the process is still running in loop.
Post by Lista Unx
So I've started proftpd in debug mode.
"added timer ID 4 ('TimeoutStalled', for module '[none]'), triggering in
3600 seconds" ...
Post by Lista Unx
What does module NONE mean and how can be solved? Seems proftpd is
Trying 127.0.0.1...
Connected to localhost.
Escape character is '^]'.
220 FTP Server ready.
user alex
331 Password required for alex
pass
230 User alex logged in
pasv
227 Entering Passive Mode (192,168,13,104,194,82).
stat
211-Status of 'ProFTPD server'
Connected from 127.0.0.1 (127.0.0.1)
Logged in as alex
TYPE: ASCII, STRUcture: File, Mode: Stream
No data connection
211 End of status
list
^]
telnet> quit
Connection closed.
...
2016-12-07 13:28:58,656 ftpd.rhce.local proftpd[24781] 192.168.13.104
(127.0.0.1[127.0.0.1]): dispatching PRE_CMD command 'LIST' to mod_tls
Post by Lista Unx
2016-12-07 13:28:58,656 ftpd.rhce.local proftpd[24781] 192.168.13.104
(127.0.0.1[127.0.0.1]): dispatching PRE_CMD command 'LIST' to mod_core
Post by Lista Unx
2016-12-07 13:28:58,656 ftpd.rhce.local proftpd[24781] 192.168.13.104
(127.0.0.1[127.0.0.1]): dispatching PRE_CMD command 'LIST' to mod_core
Post by Lista Unx
2016-12-07 13:28:58,656 ftpd.rhce.local proftpd[24781] 192.168.13.104
(127.0.0.1[127.0.0.1]): dispatching CMD command 'LIST' to mod_ls
Post by Lista Unx
2016-12-07 13:30:35,926 ftpd.rhce.local proftpd[24705] 192.168.13.104
(127.0.0.1[127.0.0.1]): ProFTPD terminating (signal 2)
Post by Lista Unx
2016-12-07 13:30:35,926 ftpd.rhce.local proftpd[24705] 192.168.13.104
(127.0.0.1[127.0.0.1]): FTP session closed.
Post by Lista Unx
2016-12-07 13:28:52,746 [24781] <response:1>: Logged in as alex
File, Mode: Stream
Post by Lista Unx
2016-12-07 13:28:52,746 [24781] <response:1>: No data connection
2016-12-07 13:28:52,746 [24781] <response:1>: 211 End of status
2016-12-07 13:28:58,171 [24779] <signal:5>: signals blocked
2016-12-07 13:28:58,371 [24779] <signal:5>: signals unblocked
2016-12-07 13:28:58,371 [24779] <signal:9>: handling SIGALRM (signal 14)
2016-12-07 13:28:58,371 [24779] <timer:4>: 10 seconds for timer ID 24075
('Controls polling', for module 'ctrls') elapsed, invoking callback
(0x7ff9987c2530)
Post by Lista Unx
2016-12-07 13:28:58,372 [24779] <timer:6>: restarting timer ID 24075
('Controls polling'), as per callback
Post by Lista Unx
2016-12-07 13:28:58,372 [24779] <fsio:8>: using system lstat() for path
'/etc/shutmsg'
Post by Lista Unx
2016-12-07 13:28:58,656 [24781] <timer:7>: reset timer ID 2
('TimeoutIdle', for module '[none]')
Post by Lista Unx
2016-12-07 13:28:58,656 [24781] <response:9>: clearing response lists
before dispatching command 'list'
Post by Lista Unx
2016-12-07 13:28:58,656 [24781] <encode:5>: decoded 'LIST' into 'LIST'
2016-12-07 13:28:58,656 [24781] <command:7>: dispatching PRE_CMD command
'LIST' to mod_tls.c
Post by Lista Unx
2016-12-07 13:28:58,656 [24781] <command:7>: dispatching PRE_CMD command
'LIST' to mod_core.c
Post by Lista Unx
2016-12-07 13:28:58,656 [24781] <command:7>: dispatching PRE_CMD command
'LIST' to mod_core.c
Post by Lista Unx
2016-12-07 13:28:58,656 [24781] <scoreboard:3>: updating scoreboard entry
2016-12-07 13:28:58,656 [24781] <lock:9>: attempting to write-lock
scoreboard fd 14 entry, offset 32
Post by Lista Unx
2016-12-07 13:28:58,656 [24781] <lock:9>: write-lock of scoreboard fd 14
entry, offset 32 succeeded
Post by Lista Unx
2016-12-07 13:28:58,656 [24781] <lock:9>: attempting to unlock
scoreboard fd 14 entry, offset 32
Post by Lista Unx
2016-12-07 13:28:58,656 [24781] <lock:9>: unlock of scoreboard fd 14
entry, offset 32 succeeded
Post by Lista Unx
2016-12-07 13:28:58,656 [24781] <scoreboard:3>: finished updating
scoreboard entry
Post by Lista Unx
2016-12-07 13:28:58,656 [24781] <scoreboard:3>: updating scoreboard entry
2016-12-07 13:28:58,656 [24781] <lock:9>: attempting to write-lock
scoreboard fd 14 entry, offset 32
Post by Lista Unx
2016-12-07 13:28:58,656 [24781] <lock:9>: write-lock of scoreboard fd 14
entry, offset 32 succeeded
Post by Lista Unx
2016-12-07 13:28:58,656 [24781] <lock:9>: attempting to unlock
scoreboard fd 14 entry, offset 32
Post by Lista Unx
2016-12-07 13:28:58,656 [24781] <lock:9>: unlock of scoreboard fd 14
entry, offset 32 succeeded
Post by Lista Unx
2016-12-07 13:28:58,656 [24781] <scoreboard:3>: finished updating
scoreboard entry
Post by Lista Unx
2016-12-07 13:28:58,656 [24781] <command:7>: dispatching CMD command
'LIST' to mod_ls.c
Post by Lista Unx
2016-12-07 13:28:58,656 [24781] <encode:5>: decoded '' into ''
2016-12-07 13:28:58,656 [24781] <fsio:8>: using system stat() for path ''
2016-12-07 13:28:58,656 [24781] <data:8>: allocated data transfer buffer
of 16384 bytes
Post by Lista Unx
2016-12-07 13:28:58,656 [24781] <timer:7>: added timer ID 4
('TimeoutStalled', for module '[none]'), triggering in 3600 seconds
Post by Lista Unx
and jump again to beginning: "<signal:5>: signals blocked" forever if
not stopped manually.
Post by Lista Unx
^C
See below my proftpd.conf
ServerName "ProFTPD server"
ServerIdent on "FTP Server ready."
DefaultServer on
DefaultRoot ~ !adm
AuthPAMConfig proftpd
AuthOrder mod_auth_pam.c* mod_auth_unix.c
UseReverseDNS off
User nobody
Group nobody
MaxInstances 20
UseSendfile off
LogFormat default "%h %l %u %t \"%r\" %s %b"
LogFormat auth "%v [%P] %h %t \"%r\" %s"
LoadModule mod_ctrls_admin.c
LoadModule mod_vroot.c
LoadModule mod_ls.c
ModuleControlsACLs insmod,rmmod allow user root
ModuleControlsACLs lsmod allow user *
ControlsEngine on
ControlsACLs all allow user root
ControlsSocketACL allow user *
ControlsLog /var/log/proftpd/controls.log
<IfModule mod_ctrls_admin.c>
AdminControlsEngine on
AdminControlsACLs all allow user root
</IfModule>
<Global>
Umask 022
# Allow users to overwrite files and change permissions
AllowOverwrite yes
<Limit ALL SITE_CHMOD>
AllowAll
</Limit>
<Limit LIST>
AllowAll
</Limit>
</Global>
<Anonymous ~ftp>
User ftp
Group ftp
AccessGrantMsg "Anonymous login ok, restrictions apply."
UserAlias anonymous ftp
MaxClients 10 "Sorry, max %m users -- try again
later"
Post by Lista Unx
DefaultChdir /pub
DisplayLogin /welcome.msg
DisplayChdir .message
DisplayReadme README*
DirFakeUser on ftp
DirFakeGroup on ftp
# Limit WRITE everywhere in the anonymous chroot
<Limit WRITE SITE_CHMOD>
DenyAll
</Limit>
# Allow read, list
<Limit READ LIST>
AllowAll
</Limit>
# Don't write anonymous accesses to the system wtmp file (good idea!)
WtmpLog off
# Logging for the anonymous transfers
ExtendedLog /var/log/proftpd/access.log WRITE,READ
default
Post by Lista Unx
ExtendedLog /var/log/proftpd/auth.log AUTH auth
</Anonymous>
MasqueradeAddress 192.168.13.104
PassivePorts 49152 65534
<IfModule mod_facts.c>
FactsAdvertise off
</IfModule>
TraceLog /var/log/proftpd/trace.log
Trace DEFAULT:10
ScoreboardScrub off
What is missing or what is wrong in my proftpd.conf
(proftpd-1.3.5b-2.el7.x86_64)?
Post by Lista Unx
Thank you in advance for help.
Alex
----------------------------------------------------------------------
http://BareMetal.com/ | There can be no courage unless you're scared.
| - Eddie Rickenbacker
------------------------------------------------------------
------------------
Developer Access Program for Intel Xeon Phi Processors
Access to Intel Xeon Phi processor-based developer platforms.
With one year of Intel Parallel Studio XE.
Training and support from Colfax.
Order your platform today.http://sdm.link/xeonphi
_______________________________________________
Unsubscribe problems?
http://www.proftpd.org/list-unsub.html
Loading...