Page 1 of 1

Checking files on Remote server

Posted: Tue Nov 25, 2008 3:25 am
by DEEPTI
Hi All,

We have a Sequnecer job design as below:

4 jobs running in parallel that load 4 CSV files in the remote server.

If any of the job aborts, our requirement is to remove the CSV files which are loaded by the other jobs.

What is the method to check whether the files exist in the remote server
and to remove them in DataSatge?

Thanks in advance,
Deepti

Re: Checking files on Remote server

Posted: Tue Nov 25, 2008 4:41 am
by syeed
Hi Deepti,

u can do it through Shell script, I had the similar situation.
login into ur remote server as telnet
####################Code####################
(
echo USERID;
sleep 2;
echo PWD;
sleep 2;
echo "rm FILE_PATH/filename";
sleep 2;
)| telnet SERVER_NAME>log.txt

OR if you want to look for the files existence then u want to delete u can do it using SHELL script, let me know if you need code for this.

thanks,
Waseem

Posted: Tue Nov 25, 2008 5:10 am
by basu.ds
method to check the files exists in server is using waitforfile activity .
To delete files if any job aborts using trigger conditions by your design and finally delete files