Execute Command(using a Script to FTP)
Posted: Wed Jul 26, 2006 1:45 pm
I have a sequence job,in that i am using a Execute Command activity to FTP a file to a mainframe server.I am getting the Exit status for the FTP script as 0,but it says file or directory not found.Where as the file is present in that directory.
I have manually checked transferred the file,it is getting FTPed.
Below is the output which i am getting from the Execute Command
TestFTP..JobControl (@Execute_Command_0): Executed: /usr/ascential/work/Scripts/Other/FTP.sh cenvse prog ftp /usr/ascential/work/OutputFiles/ReportFactory/ G_ws_mov_hist_out.txt /usr/ascential/work/Logs/Other
Reply=0
Output from command ====>
G_ws_mov_hist_out.txt: A file or directory in the path name does not exist.
The Script which i am using to FTP file is below
remote_server="${1}"
remote_user="${2}"
remote_passwd="${3}"
remote_path="${4}"
remote_file="${5}"
local_path="${6}"
local_file="${7}"
log_path="${8}"
ftp -v -n $remote_server << eof >> $log_path/$local_file.log
user "$remote_user" "$remote_passwd"
lcd $local_path
cd $remote_path
prompt
put $local_file $remote_file
eof
Any hint in this matter will help me.
I have manually checked transferred the file,it is getting FTPed.
Below is the output which i am getting from the Execute Command
TestFTP..JobControl (@Execute_Command_0): Executed: /usr/ascential/work/Scripts/Other/FTP.sh cenvse prog ftp /usr/ascential/work/OutputFiles/ReportFactory/ G_ws_mov_hist_out.txt /usr/ascential/work/Logs/Other
Reply=0
Output from command ====>
G_ws_mov_hist_out.txt: A file or directory in the path name does not exist.
The Script which i am using to FTP file is below
remote_server="${1}"
remote_user="${2}"
remote_passwd="${3}"
remote_path="${4}"
remote_file="${5}"
local_path="${6}"
local_file="${7}"
log_path="${8}"
ftp -v -n $remote_server << eof >> $log_path/$local_file.log
user "$remote_user" "$remote_passwd"
lcd $local_path
cd $remote_path
prompt
put $local_file $remote_file
eof
Any hint in this matter will help me.