Each time FTP transmits a new file, it has to create a "data
connection", this is done by connecting another (separate) TCP session
to an arbitrary port number. Each connection will use a different port
From your description, it sounds like some of the port numbers that are
being chosen are being "refused". This means that whichever computer is
opening these ports is failing to open them, or possibly, that a
firewall is blocking them.
The fact that this doesn't happen to every file makes me think that it's
sometimes picking port numbers that are allowed in through the firewall,
and sometimes picking port numbers that are not.
If you are using active mode FTP, try switching to passive mode or
vice-versa. (In active mode, the FTP client has to open up the ports.
In passive mode, the server does... typically, passive works better
because folks providing an FTP server usually take the time to make sure
it works nicely with their firewall, proxy and NAT environment. But,
occasionally, the opposite is true, and it's the client that works better.)
If that does not help, then please try putting FTP into debug mode (this
is done with the 'DEBUG' FTP sub-command...) and logging the details
when it succeeds/fails. This will provide more information that might
be used to help you.
On 1/6/2014 3:23 PM, Reiner, Tom wrote:
I have FTP scripts accessing a server from our iSeries Power 7. The process will error on file 1 with "425 Can't build data connection: Connection refused. " the go onto file 2 and down load it to the iseries. It will then download files 3 say 6 the error on file 7. Any thoughts as to what the issue might be?
C. Thomas Reiner
Sr. Programmer Analyst / EDI - Developer
69 N. Locust Street
Lititz, PA 17543
717.626.2125 Ext. 424
Disclaimer: This communication (including attachments) contains private, confidential, privileged and/or proprietary information intended solely for the Recipients named above. If you are not the intended Recipient, any use, dissemination, distribution or copying of the communication is strictly prohibited. If received in error, we apologize and ask that you please notify the Sender by calling (717) 626-2125 or via return e-mail, permanently delete this communication from your computer and raze any printed copies. Thank you in advance for your cooperation."
"Any views expressed herein are not necessarily those of Woodstream Corporation. No contracts, agreements or legally binding understandings may be entered into solely by an e-mail communication."