FTP Server with mainframe error logging in.

Need help with FileZilla Server? Something does not work as expected? In this forum you may find an answer.

Moderator: Project members

Post Reply
Message
Author
Cosine-FTP
500 Command not understood
Posts: 5
Joined: 2010-02-09 08:38
First name: Sean
Last name: Connolly

FTP Server with mainframe error logging in.

#1 Post by Cosine-FTP » 2010-02-09 09:15

Hi,

I have had the task of setting up our FTP for our company since changing ISP's. The scenario is this:

Server: Windows Server 2003 Small Business and FileZilla Server FTP. FTP server is a fixed WAN IP address.

We can FTP either internally within the company LAN, and externally on WAN and can see directory structure, upload/download files and it all seems pretty good. Here is a log of the FTP Server and FTP Client side.

Client FTP

Status: Connecting to 81.143.98.44:21...
Status: Connection established, waiting for welcome message...
Response: 220 Welcome to the On time FTP Server. Al transactions are logged for security.
Command: USER otftpot
Response: 331 Password required for otftpot
Command: PASS *******
Response: 230 Logged on
Status: Connected
Status: Retrieving directory listing...
Command: PWD
Response: 257 "/" is current directory.
Command: TYPE I
Response: 200 Type set to I
Command: PASV
Response: 227 Entering Passive Mode (192,168,0,14,19,142)
Status: Server sent passive reply with unroutable address. Using server address instead.
Command: LIST
Response: 150 Connection accepted
Response: 226 Transfer OK
Status: Directory listing successful


Server FTP

000006) 09/02/2010 08:47:16 - (not logged in) (87.194.135.227)> Connected, sending welcome message...
(000006) 09/02/2010 08:47:16 - (not logged in) (87.194.135.227)> 220 Welcome to the On time FTP Server. Al transactions are logged for security.
(000006) 09/02/2010 08:47:16 - (not logged in) (87.194.135.227)> USER otftpot
(000006) 09/02/2010 08:47:16 - (not logged in) (87.194.135.227)> 331 Password required for otftpot
(000006) 09/02/2010 08:47:16 - (not logged in) (87.194.135.227)> PASS *******
(000006) 09/02/2010 08:47:16 - otftpot (87.194.135.227)> 230 Logged on
(000006) 09/02/2010 08:47:16 - otftpot (87.194.135.227)> PWD
(000006) 09/02/2010 08:47:16 - otftpot (87.194.135.227)> 257 "/" is current directory.
(000006) 09/02/2010 08:47:16 - otftpot (87.194.135.227)> TYPE I
(000006) 09/02/2010 08:47:16 - otftpot (87.194.135.227)> 200 Type set to I
(000006) 09/02/2010 08:47:16 - otftpot (87.194.135.227)> PASV
(000006) 09/02/2010 08:47:16 - otftpot (87.194.135.227)> 227 Entering Passive Mode (192,168,0,14,19,142)
(000006) 09/02/2010 08:47:16 - otftpot (87.194.135.227)> LIST
(000006) 09/02/2010 08:47:16 - otftpot (87.194.135.227)> 150 Connection accepted
(000006) 09/02/2010 08:47:16 - otftpot (87.194.135.227)> 226 Transfer OK

Apart from the "Server sent passive reply with unroutable address. Using server address instead." error, everything else seems to have gone according to plan.

The big problem we have is that an external company who sends data files to us every night from their mainframe to our FTP site for database updating. I don't know if the above error would cause any problems, but when they establish a connection, they receive an error 425 which would normally mean they are unable to list the directory and any subsequent upload fails.

I have no idea what type of mainframe FTP system they are using but I am guessing it is a very old system. I know that we have used it for the past 10 years, but apart from changing ISP, we've also changed to a newer server for our FTP link.

Can anyone help with the "Server sent passive reply with unroutable address. Using server address instead." error please? Also would anyone know why the external mainframe would receive such error 425 when connecting and transmitting data?

Just a little more information for you. The last time our FTP ran on our old server under our previous Internet Provider, it was all configured under IIS on Windows Server 2003, but I would prefer to use FileZilla Server instead.

Many thanks in Advance for your help!

Kind regards,

Sean

User avatar
boco
Contributor
Posts: 26938
Joined: 2006-05-01 03:28
Location: Germany

Re: FTP Server with mainframe error logging in.

#2 Post by boco » 2010-02-09 09:33

Your server is configured incorrectly, it does not know the external IP. You must configure the server's Passive settings (+your network) correctly. Please read the Network Configuration guide.
No support requests over PM! You will NOT get any reply!!!
FTP connection problems? Please read Network Configuration.
FileZilla connection test: https://filezilla-project.org/conntest.php
FileZilla Pro support: https://customerforum.fileZilla-project.org

Cosine-FTP
500 Command not understood
Posts: 5
Joined: 2010-02-09 08:38
First name: Sean
Last name: Connolly

Re: FTP Server with mainframe error logging in.

#3 Post by Cosine-FTP » 2010-02-09 17:29

Hi,

Thanks for your earlier reply. I don't have the problem with the external IP now. The administrator from the remote FTP server has attempted a few connections late this afternoon and this is the log file from 3 different connect and transfer sessions:

(000037) 09/02/2010 16:45:43 - (not logged in) (157.203.43.23)> Connected, sending welcome message...
(000037) 09/02/2010 16:45:43 - (not logged in) (157.203.43.23)> 220 Welcome to the On time FTP Server. All transactions are logged for security.
(000037) 09/02/2010 16:45:43 - (not logged in) (157.203.43.23)> USER otftpot
(000037) 09/02/2010 16:45:43 - (not logged in) (157.203.43.23)> 331 Password required for otftpot
(000037) 09/02/2010 16:45:43 - (not logged in) (157.203.43.23)> PASS *******
(000037) 09/02/2010 16:45:43 - otftpot (157.203.43.23)> 230 Logged on
(000037) 09/02/2010 16:45:43 - otftpot (157.203.43.23)> TYPE A N
(000037) 09/02/2010 16:45:43 - otftpot (157.203.43.23)> 200 Type set to A N
(000037) 09/02/2010 16:45:43 - otftpot (157.203.43.23)> STRU F
(000037) 09/02/2010 16:45:43 - otftpot (157.203.43.23)> 200 Using file structure 'File'
(000037) 09/02/2010 16:45:43 - otftpot (157.203.43.23)> PORT 157,203,43,23,159,157
(000037) 09/02/2010 16:45:43 - otftpot (157.203.43.23)> 200 Port command successful
(000037) 09/02/2010 16:45:43 - otftpot (157.203.43.23)> STOR DELETE.ME
(000037) 09/02/2010 16:45:43 - otftpot (157.203.43.23)> 150 Opening data channel for file transfer.
(000037) 09/02/2010 16:45:53 - otftpot (157.203.43.23)> 425 Can't open data connection.
(000037) 09/02/2010 16:46:13 - otftpot (157.203.43.23)> QUIT
(000037) 09/02/2010 16:46:13 - otftpot (157.203.43.23)> 221 Goodbye
(000037) 09/02/2010 16:46:13 - otftpot (157.203.43.23)> disconnected.
(000038) 09/02/2010 16:46:37 - (not logged in) (157.203.43.23)> Connected, sending welcome message...
(000038) 09/02/2010 16:46:37 - (not logged in) (157.203.43.23)> 220 Welcome to the On time FTP Server. Al transactions are logged for security.
(000038) 09/02/2010 16:46:37 - (not logged in) (157.203.43.23)> USER otftpot
(000038) 09/02/2010 16:46:37 - (not logged in) (157.203.43.23)> 331 Password required for otftpot
(000038) 09/02/2010 16:46:37 - (not logged in) (157.203.43.23)> PASS *******
(000038) 09/02/2010 16:46:37 - otftpot (157.203.43.23)> 230 Logged on
(000038) 09/02/2010 16:46:37 - otftpot (157.203.43.23)> TYPE A N
(000038) 09/02/2010 16:46:37 - otftpot (157.203.43.23)> 200 Type set to A N
(000038) 09/02/2010 16:46:37 - otftpot (157.203.43.23)> STRU F
(000038) 09/02/2010 16:46:37 - otftpot (157.203.43.23)> 200 Using file structure 'File'
(000038) 09/02/2010 16:46:38 - otftpot (157.203.43.23)> PORT 157,203,43,23,160,19
(000038) 09/02/2010 16:46:38 - otftpot (157.203.43.23)> 200 Port command successful
(000038) 09/02/2010 16:46:38 - otftpot (157.203.43.23)> STOR DELETE.ME
(000038) 09/02/2010 16:46:38 - otftpot (157.203.43.23)> 150 Opening data channel for file transfer.
(000038) 09/02/2010 16:46:48 - otftpot (157.203.43.23)> 425 Can't open data connection.
(000038) 09/02/2010 16:47:08 - otftpot (157.203.43.23)> QUIT
(000038) 09/02/2010 16:47:08 - otftpot (157.203.43.23)> 221 Goodbye
(000038) 09/02/2010 16:47:08 - otftpot (157.203.43.23)> disconnected.
(000039) 09/02/2010 16:59:05 - (not logged in) (157.203.43.23)> Connected, sending welcome message...
(000039) 09/02/2010 16:59:05 - (not logged in) (157.203.43.23)> 220 Welcome to the On time FTP Server. Al transactions are logged for security.
(000039) 09/02/2010 16:59:05 - (not logged in) (157.203.43.23)> USER otftpot
(000039) 09/02/2010 16:59:05 - (not logged in) (157.203.43.23)> 331 Password required for otftpot
(000039) 09/02/2010 16:59:05 - (not logged in) (157.203.43.23)> PASS *******
(000039) 09/02/2010 16:59:05 - otftpot (157.203.43.23)> 230 Logged on
(000039) 09/02/2010 16:59:05 - otftpot (157.203.43.23)> TYPE A N
(000039) 09/02/2010 16:59:05 - otftpot (157.203.43.23)> 200 Type set to A N
(000039) 09/02/2010 16:59:05 - otftpot (157.203.43.23)> STRU F
(000039) 09/02/2010 16:59:05 - otftpot (157.203.43.23)> 200 Using file structure 'File'
(000039) 09/02/2010 16:59:05 - otftpot (157.203.43.23)> PORT 157,203,43,23,170,14
(000039) 09/02/2010 16:59:05 - otftpot (157.203.43.23)> 200 Port command successful
(000039) 09/02/2010 16:59:05 - otftpot (157.203.43.23)> STOR DELETE.ME
(000039) 09/02/2010 16:59:05 - otftpot (157.203.43.23)> 150 Opening data channel for file transfer.
(000039) 09/02/2010 16:59:16 - otftpot (157.203.43.23)> 425 Can't open data connection.
(000039) 09/02/2010 16:59:35 - otftpot (157.203.43.23)> QUIT
(000039) 09/02/2010 16:59:35 - otftpot (157.203.43.23)> 221 Goodbye
(000039) 09/02/2010 16:59:35 - otftpot (157.203.43.23)> disconnected.

It would look like a connection was made over port 40861 from the client side (157,203,43,23,159,157) the first time round. The second time around it would appear to have come from 40979 (157,203,43,23,160,19). The third time around it looks like it was on port 43534 (157,203,43,23,170,14).

If I come in on a remote connection with FileZilla Client with my laptop or even my home PC, log in as this username, I can connect without problems, do upload/download/delete/create directory tests and everything works for me. Any ideas why this might work for me and not for the external mainframe?

Here's a log from my own test:

(000040) 09/02/2010 17:18:43 - (not logged in) (86.178.124.118)> Connected, sending welcome message...
(000040) 09/02/2010 17:18:43 - (not logged in) (86.178.124.118)> 220 Welcome to the On time FTP Server. Al transactions are logged for security.
(000040) 09/02/2010 17:18:43 - (not logged in) (86.178.124.118)> USER otftpot
(000040) 09/02/2010 17:18:43 - (not logged in) (86.178.124.118)> 331 Password required for otftpot
(000040) 09/02/2010 17:18:43 - (not logged in) (86.178.124.118)> PASS *******
(000040) 09/02/2010 17:18:43 - otftpot (86.178.124.118)> 230 Logged on
(000040) 09/02/2010 17:18:43 - otftpot (86.178.124.118)> SYST
(000040) 09/02/2010 17:18:43 - otftpot (86.178.124.118)> 215 UNIX emulated by FileZilla
(000040) 09/02/2010 17:18:43 - otftpot (86.178.124.118)> FEAT
(000040) 09/02/2010 17:18:43 - otftpot (86.178.124.118)> 211-Features:
(000040) 09/02/2010 17:18:43 - otftpot (86.178.124.118)> MDTM
(000040) 09/02/2010 17:18:43 - otftpot (86.178.124.118)> REST STREAM
(000040) 09/02/2010 17:18:43 - otftpot (86.178.124.118)> SIZE
(000040) 09/02/2010 17:18:43 - otftpot (86.178.124.118)> MLST type*;size*;modify*;
(000040) 09/02/2010 17:18:43 - otftpot (86.178.124.118)> MLSD
(000040) 09/02/2010 17:18:43 - otftpot (86.178.124.118)> UTF8
(000040) 09/02/2010 17:18:43 - otftpot (86.178.124.118)> CLNT
(000040) 09/02/2010 17:18:43 - otftpot (86.178.124.118)> MFMT
(000040) 09/02/2010 17:18:43 - otftpot (86.178.124.118)> 211 End
(000040) 09/02/2010 17:18:43 - otftpot (86.178.124.118)> PWD
(000040) 09/02/2010 17:18:43 - otftpot (86.178.124.118)> 257 "/" is current directory.
(000040) 09/02/2010 17:18:43 - otftpot (86.178.124.118)> TYPE I
(000040) 09/02/2010 17:18:43 - otftpot (86.178.124.118)> 200 Type set to I
(000040) 09/02/2010 17:18:43 - otftpot (86.178.124.118)> PASV
(000040) 09/02/2010 17:18:43 - otftpot (86.178.124.118)> 227 Entering Passive Mode (81,143,98,44,19,154)
(000040) 09/02/2010 17:18:43 - otftpot (86.178.124.118)> MLSD
(000040) 09/02/2010 17:18:43 - otftpot (86.178.124.118)> 150 Connection accepted
(000040) 09/02/2010 17:18:43 - otftpot (86.178.124.118)> 226 Transfer OK
(000041) 09/02/2010 17:19:24 - (not logged in) (86.178.124.118)> Connected, sending welcome message...
(000041) 09/02/2010 17:19:24 - (not logged in) (86.178.124.118)> 220 Welcome to the On time FTP Server. Al transactions are logged for security.
(000041) 09/02/2010 17:19:24 - (not logged in) (86.178.124.118)> USER otftpot
(000041) 09/02/2010 17:19:24 - (not logged in) (86.178.124.118)> 331 Password required for otftpot
(000041) 09/02/2010 17:19:24 - (not logged in) (86.178.124.118)> PASS *******
(000041) 09/02/2010 17:19:24 - otftpot (86.178.124.118)> 230 Logged on
(000041) 09/02/2010 17:19:24 - otftpot (86.178.124.118)> CWD /
(000041) 09/02/2010 17:19:24 - otftpot (86.178.124.118)> 250 CWD successful. "/" is current directory.
(000041) 09/02/2010 17:19:24 - otftpot (86.178.124.118)> PWD
(000041) 09/02/2010 17:19:24 - otftpot (86.178.124.118)> 257 "/" is current directory.
(000041) 09/02/2010 17:19:24 - otftpot (86.178.124.118)> TYPE I
(000041) 09/02/2010 17:19:24 - otftpot (86.178.124.118)> 200 Type set to I
(000041) 09/02/2010 17:19:24 - otftpot (86.178.124.118)> PASV
(000041) 09/02/2010 17:19:24 - otftpot (86.178.124.118)> 227 Entering Passive Mode (81,143,98,44,19,155)
(000041) 09/02/2010 17:19:24 - otftpot (86.178.124.118)> STOR ACPI.SY_
(000041) 09/02/2010 17:19:24 - otftpot (86.178.124.118)> 150 Connection accepted
(000041) 09/02/2010 17:19:26 - otftpot (86.178.124.118)> 226 Transfer OK
(000041) 09/02/2010 17:19:26 - otftpot (86.178.124.118)> PASV
(000041) 09/02/2010 17:19:26 - otftpot (86.178.124.118)> 227 Entering Passive Mode (81,143,98,44,19,156)
(000041) 09/02/2010 17:19:26 - otftpot (86.178.124.118)> MLSD
(000041) 09/02/2010 17:19:26 - otftpot (86.178.124.118)> 150 Connection accepted
(000041) 09/02/2010 17:19:26 - otftpot (86.178.124.118)> 226 Transfer OK
(000041) 09/02/2010 17:20:26 - otftpot (86.178.124.118)> disconnected.

I can see that my own login is entering passive mode, but the other mainframe is not sending PASV commands, so I guess it is in Active mode.

I've cleared the way on our company firewall for TCP ports 20, 21 and already the range 5001-5201 for passive mode is cleared and configured in FileZilla (we use a pfSense network Firewall). Do I need to configure anything else to allow the other mainframe to connect?

Kind regards,

Sean

User avatar
botg
Site Admin
Posts: 35563
Joined: 2004-02-23 20:49
First name: Tim
Last name: Kosse

Re: FTP Server with mainframe error logging in.

#4 Post by botg » 2010-02-09 18:51

I can see that my own login is entering passive mode, but the other mainframe is not sending PASV commands, so I guess it is in Active mode.
In this case the mainframe's firewall needs to be configured properly.

Post Reply