Unix Shell Script on Tidal schedular for ETL


 
Thread Tools Search this Thread
Top Forums UNIX for Dummies Questions & Answers Unix Shell Script on Tidal schedular for ETL
# 1  
Old 11-30-2010
Unix Shell Script on Tidal schedular for ETL

Hello

I am very new to Unix scripting,
I am using informatica etl,which is schedule by tidal enterprise.

I have a scenario where assume that Tidal only knows how to run jobs at a given time and does not know how to retry.

So i want to know weather can i write a shell script such that tidal will try to run job 3 times,and if still the job fails it will abort the process.

ANy help will be appreciated

Thank You

Pls do reply.


# 2  
Old 12-01-2010
Piece of cake:

Put in script file "tryn", chmod 755:
Code:
#!/usr/bin/ksh

if (( $# < 2 || 0$1 <2 ))
then
 echo "
Usage: tryn <no_tries> <cmd> [ <arg> . . . ]

Tries <cmd> with any <arg>'s until it exits 0 (success) or <no_tries> times, sleeping one minute between tries.
" >&2
 exit 1
fi

t=$1
shift

while [ 1 ]
do
  "$@"
  ret=$0

  if [ $ret = 0 ]
  then
    exit 0
  fi

  t=$(( $t - 1 ))

  if [ $t = 0 ]
  then
    exit $ret
  fi

  sleep 60
done

 
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. High Performance Computing

Job Schedular for Suse Enterprise SLES 11 SP2

We have a server with 160 hyper-threaded cpu's threads and 2Tb of RAM. I need to implement command line job queue and parallel thread usage for multiple user environment kindly suggest necessary tools to be installed. I have understanding that sun grid engine like applications are available for... (0 Replies)
Discussion started by: vaibhavvsk
0 Replies

2. Shell Programming and Scripting

Shell script executed from Informatica ETL tool is spawning 2 processes for one script

Hi, I am having a shell script which has a while loop as shown below. while do sleep 60 done I am executing this script from Informatica ETL tool command task from where we can execute UNIX commands/scripts. When i do that, i am seeing 2 processes getting started for one script... (2 Replies)
Discussion started by: chekusi
2 Replies

3. Shell Programming and Scripting

Script to check ETL standards in an Informatica mapping

Hi, Script to check the ETL standards in an informatica mapping ( xml file ). Example: To check the naming standard of mapping . To check the transformation naming convention. To check the datatypes. To the session name , it should start with s. To check the workflow name , it should... (0 Replies)
Discussion started by: srimadhuri
0 Replies

4. Shell Programming and Scripting

Unix Script via ETL

while ;do sleep 5; done Hi, We do run the ETL jobs via DataStage. We do have 30 sequences which calls 1 update query. Most of the time when the update query is run by many countries, the ETL job gets hang. Becuase of this we have written a above script. We do in the script i.,e if... (1 Reply)
Discussion started by: dsnaveen
1 Replies

5. UNIX for Advanced & Expert Users

Schedular

Hi, I was looking for a schedular(a simple script would do or a tool) that would invoke jobs on few conditions: 1. Every day 2. Every working day(Considering customized holiday list, from a file or table) 3. Weekly 4. being able to define variable dependency. like on every day run,... (1 Reply)
Discussion started by: ahmedwaseem2000
1 Replies

6. Shell Programming and Scripting

Creating a Schedular to Run the Jobs.

Hi, I have to create a sheduler to run the shell scripts one by one(dependency). Suppose i have 10 scripts. For all the 10 scripts i have a database table containing these scripts_names and status. Executing the first script.if the first status script is only 'success' then go to next... (4 Replies)
Discussion started by: laknar
4 Replies

7. UNIX for Dummies Questions & Answers

Problem: Run schedular to copy from one table to other

Check if records of table B are 1 month old. if yes then Truncate table B_SNAPSHOT and then copy data from B to SNAPSHOT_B table otherwise no need to copy. Run a schedular after every 15 minutes. The tables B and SNAPSHOT_B has the below structure(same for both): PROCESS_NAME MQ_NAME... (0 Replies)
Discussion started by: nehagupta2008
0 Replies

8. Shell Programming and Scripting

ETL Complex FTP

Hi Gurus, I want to perform following task : I am getting new text file every month in CD format. Now by using 3rd party ETL tool which is installed in UNIX I want to run the job whose input file will be this file from CD. So I need to FTP text file from my client machine CD drive to UNIX.... (2 Replies)
Discussion started by: ganesh123
2 Replies

9. UNIX for Advanced & Expert Users

command to schedule a unix script in tidal' scheduler

hi i am needed to use tidal's scheduler to schedule unix scripts available on server A. while creating a job to be scheduled, it has an option called command which will take a path of the file. i have seen several examples in the following way e:\tidal\bin\sleep.exe here i did not understand two... (0 Replies)
Discussion started by: balireddy_77
0 Replies

10. AIX

Difference between writing Unix Shell script and AIX Shell Scripts

Hi, Please give me the detailed Differences between writing Unix Shell script and AIX Shell Scripts. Thanks in advance..... (0 Replies)
Discussion started by: haroonec
0 Replies
Login or Register to Ask a Question