The ftp job fails with the error "PORT is unsuccessful"
The Job definition is as follows
/* ----------------- TEST_FTP1_C ----------------- */
insert_job: TEST_FTP1_C job_type: FTP
machine: dalaaaaa
owner: xxxxx@xxxxxxxxx
permission:
date_conditions: 0
description: "FTP"
alarm_if_fail: 0
ftp_transfer_type: B
ftp_transfer_direction: UPLOAD
ftp_local_name: "/data1/XXXX/YYYY/ZZZZ/abc/def/test.properties"
ftp_remote_name: "/tmp/test.properties"
ftp_server_name: x.x.x.x
ftp_server_port: 21
ftp_use_ssl: 0
ftp_local_user: local
ftp_user_type: Simple
In the autorep outout we see the following error
$ autorep -J TEST_FTP1_C -d
Job Name Last Start Last End ST Run/Ntry Pri/Xit
________________________________________________________________ ____________________ ____________________ __ ________ _______
TEST_FTP1_C 07/27/2015 16:29:45 07/27/2015 16:29:46 FA 2348890/1 500
Status/[Event] Time Ntry ES ProcessTime Machine
-------------- --------------------- -- -- --------------------- ----------------------------------------
STARTING 07/27/2015 16:29:44 1 PD 07/27/2015 16:29:45 dalaaaaa
RUNNING 07/27/2015 16:29:45 1 PD 07/27/2015 16:29:46 dalaaaaa <Executing at dalaaaaa>
FAILURE 07/27/2015 16:29:46 1 PD 07/27/2015 16:29:46
<"PORT is unsuccessful">
The spool file had the following output
$ pg 41082.2420077_1
Attempting to connect to x.x.x.x:21
Connection established to x.x.x.x:21
USER xxxxx
331 Password required for xxxxx
PASS (hidden)
230 User xxxxx logged in
SYST
215 UNIX Type: L8
Uploading binary /data1/XXXX/YYYY/ZZZZ/abc/def/test.properties --> /tmp/test.properties
PORT x,x,x,x,174,173
500 Illegal PORT command
Upload failed: "PORT is unsuccessful"
There are two types of ftp. The active mode and passive mode. The system agent by default uses active mode. In environments where there is a firewall between the ftp server and client the ftp active mode can fail.
In order to switch to passive mode add the following parameter to the agentparm.txt and restart the agent:
ftp.passive=true