Gw Start Single Task

  • November 2019
  • PDF

This document was uploaded by user and they confirmed that they have the permission to share it. If you are author or own the copyright of this book, please report to us by using this DMCA report form. Report DMCA


Overview

Download & View Gw Start Single Task as PDF for free.

More details

  • Words: 291
  • Pages: 2
#!/bin/ksh #****** shellscript/gw_start_single_task.sh # name # gw_start_single_task.sh # synopsis # ./gw_start_single_task.sh # function # starts wf defined with input parameters # author # bs # creation date # 01.04.2007 # history # 01.04.2007 - bs - initial implementation # 30.04.2007 - bs - review because of hardcoded paths and credentials # 05.05.2007 - bs - added prcprocessid in the name of spool file # inputs # param1 - workflow directory # param2 - workflow name # param3 - parameter file name (togeteher with direcory) # output # status of workflow execution # notes # function descriptions, notes, etc. # source # wf_dir=${1} wf_name=${2} param_file=${3} # passwords, database name and informatica server/port are stored in a separate file file_name=`basename $param_file` dir=`echo ${param_file} | sed 's/'$file_name'//g'` inf_file=${dir}/infa.txt pc_server=`grep -m1 '$$pcserver' $inf_file | cut -f2 -d '='` port=`grep -m1 '$$pcport' $inf_file | cut -f2 -d '='` creation_date=`date +%y%m%d%h%m%s` location=`grep -m1 '$$location' $inf_file | cut -f2 -d '='` arch_dir=${pm_home}/scriptlogs/${location} prc_process_id=`grep -m1 '$$prcprocessid' $param_file | cut -f2 -d '='` log_file=${dir}/${prc_process_id}_log_single_$creation_date echo echo echo echo echo

"pc server : $pc_server (port: $port)" "archive directory: $arch_dir " "working dir: $dir" "start parameter file: $param_file" "wf: $wf_dir / $wf_name"

echo " log file on `date +%y.%m.%d` for the prc_process_id=${prc_process_id}" > $log_file echo "pc server : $pc_server (port: $port)" >> $log_file echo "archive directory: $arch_dir " >> $log_file echo "working dir: $dir" >> $log_file echo "start parameter file: $param_file" >> $log_file echo "wf: $wf_dir / $wf_name" >> $log_file

echo "pmcmd startworkflow -s ${pc_server}:${port} -u administrator -paramfile ${param_file} -pv pm_pass -f ${wf_dir} ${wf_name}" >> $log_file pmcmd startworkflow -s ${pc_server}:${port} -u administrator -paramfile ${param_file} -pv pm_pass -f ${wf_dir} ${wf_name} pmcmd waitworkflow -s ${pc_server}:${port} -u administrator -pv pm_pass -f ${wf_dir} ${wf_name} exec_status=$? echo "execution status: $exec_status" >> $log_file mv $log_file $arch_dir; exit $exec_status

Related Documents

Gw Start Single Task
November 2019 10
Gw Start Seq Tasks
November 2019 8
Gw
May 2020 17
Gw
October 2019 31
Gw
August 2019 35
Gw
December 2019 24