Sponsored Content
Full Discussion: Multiple Process issue
Top Forums UNIX for Dummies Questions & Answers Multiple Process issue Post 302213219 by jntgopal on Wednesday 9th of July 2008 01:41:02 PM
Old 07-09-2008
Question Multiple Process issue

Hello all,

First of all, I want to thank the forum for being so helpful to me in many occasions. I have searched through the forums and the internet. I couldnt find a perfect solution for my issue. Here is what Im trying to do..

Im verifying a bunch of jobs whether they are completed or not and start the next set. We have two sets of jobs one is LongRunning(LR) and the other SR jobs. The SR jobs are in sets of 7 and the LR are by themselves. We have to start the next set of jobs after completion of the first set.. For ex..

LR1 Job1
LR2 Job2
SR1 Job3
SR1 Job4
SR1 Job5
SR1 Job6
SR1 Job7
SR1 Job8
SR1 Job9
LR3 Job10
LR4 Job11
SR2 Job12
SR2 Job13
SR2 ....

LR1, LR2 and SR1 starts simultaneously. I need to check for LR1 completion to start the LR3 and LR2's completion to start LR4. But on the other hand, I have to wait for all the SR1 jobs to complete to start SR2 jobs. The SR jobs runs much faster than the LR jobs.

What I have done so far is ; Verify the LR jobs and write to 2 different files, completedLR.txt if it is completed and to runningLR.txt if it is still running. Simultaneously, I verify the SRjobs for completion. Its working for the first time. What Im having trouble with is to check the jobs after 3mins. Im having trouble in putting them into a loop where it will keep checking and also continue with starting the next set of jobs at the same time.

My main program calls a subprogram ;

main.sh
--- checkcomp.sh LR &
--- checkcomp.sh SR &
verify the completedLR.txt and go to the next set of jobs.

All the starting and verification of completion are against oracle tables. I have to just update the tables with timestamp for it to start the job and verify the stoptime for completion. Im very much confused to find a way to run one process which will keep checking the completion every 3mins and the other one to proceed further with the next and then the next set of jobs continuously.

Im not that wellversed in Unix. Any kind of help would be much appreciated. Im new to this forum as well. If I havent clarified anything clearly to help further, please let me know.

Thanks much in advance
Jay
 

10 More Discussions You Might Find Interesting

1. IP Networking

How to choose Multiple process or Multiple threads?

Hi All, Please explain me when i have to use multiple process and when I have to use Multiple threads? Please give me an example.It will be very helpful for me. Thanks in advance. (0 Replies)
Discussion started by: ashleykumar
0 Replies

2. Shell Programming and Scripting

Help in co-process issue

Would you please tell me any link to learn about the concepts of coprocess from teh start and tell me briefly its applications, ie when, where, why to use co-process, and ive seen its applied to much in an ftp script. why its importnat in an ftp script ill appreciata hihly your help. Thanks (2 Replies)
Discussion started by: alexcol
2 Replies

3. UNIX for Advanced & Expert Users

Oracle library issue in child process

Hi, I am using a daemon from which I am forking 3 processes P1,P2,P3 out of which P3 is compiled with oracle lib32/libclntsh.so and P1,P2 are non database process. The Logic of daemon is that if any one goes down simply clean the other and refork all the 3 again. P3 is getting forked first time... (1 Reply)
Discussion started by: unisuraj
1 Replies

4. Shell Programming and Scripting

Issue in mail sending process

Hi I created one CSV file and i need to append some message in the content of my mail. $sales=sales.dat $sales_csv=sales.csv $sales_report=sales.txt this is the command am using it. echo "sales for `date`"| read subject uuencode $sales $sales_csv | mailx -ms "${subject}."... (2 Replies)
Discussion started by: bobprabhu
2 Replies

5. UNIX for Dummies Questions & Answers

Multiple instance of same process

;)Hi Everyone, I am using solaris 5.10. I have a java process running in server mode in unix. The problem is that it automatically forks i.e creates a child process. I mean suddenly two instances of that process start running , in which the process-id of first instance is the parent... (0 Replies)
Discussion started by: glamo_2312
0 Replies

6. Shell Programming and Scripting

Snmp Process Monitoring Issue

Can someone please explain to me how come snmpwalk doesn't always find a running process that's on a remote server? I prefer to use snmp to monitor processes remotely because this doesn't require me to put a script on that remote box. but the problem is, there are times that my snmp command... (2 Replies)
Discussion started by: SkySmart
2 Replies

7. UNIX for Advanced & Expert Users

Issue while killing the process using autosys job

Hi, I have one autosys job that will retrieve the proccess id's and will kill those processess as follows, pid=`/usr/ucb/ps -auwwxx | grep MAIN |nawk '{print $2}'` kill -9 pid but after executing this particular job, its status is showing as TE(terminated) and the kill process is... (3 Replies)
Discussion started by: Kattoor
3 Replies

8. Solaris

Process issue

They asked me to check is if process 'aanr' isn't working or hung!! $ ps -ef | grep aanr artsadm 11355 1 0 20:15:01 ? 0:00 /usr/local/bin/perl5 ./aanr artsadm 28203 1 0 Sep 06 ? 0:49 /usr/local/bin/perl5 ./aanr artsadm 24646 1 0 Sep 26 ? 0:00... (3 Replies)
Discussion started by: learner46
3 Replies

9. Shell Programming and Scripting

Issue Running UNIX process from CRON !!

Experts, Not sure whether the problem described here is related with Unix or is it with Oracle Installation. Here is the description of the issue: A new Unix server is setup as a part of Unix and Oracle upgradation activity for one of the Application, I work on. One strange thing is... (2 Replies)
Discussion started by: Oracle_User
2 Replies

10. UNIX for Beginners Questions & Answers

Issue with search and replacing multiple items in multiple files

Im having an issue when trying to replace the first column with a new set of values in multiple files. The results from the following code only replaces the files with the last set of values in val.txt. I want to replace all the files with all the values. for date in {1..31} do for val in... (1 Reply)
Discussion started by: ncwxpanther
1 Replies
select_wakeup(9r)														 select_wakeup(9r)

NAME
select_wakeup - General: Wakes up a kernel thread SYNOPSIS
void select_wakeup( sel_queue_t *selq ); ARGUMENTS
Specifies a pointer to a sel_queue structure. DESCRIPTION
The select_wakeup routine wakes up a kernel thread that is suspended while waiting for an event on the specified device. A user-level process can use the select system call to cause the process to be suspended while waiting for an event to happen on a device. For example, a graphics application may issue a select call while waiting for mouse or keyboard input to arrive. In this case the process would issue the select system call, which would indirectly call the graphics driver's select routine (through the driver's select entry point in the dsent table) to determine if any input is available. If input is available, the select call may return immediately. If no input is cur- rently available, the graphics driver would suspend the process until input arrived. For this example, when the graphics driver has received input (typically through its interrupt handler), it causes any processes suspended from calling select to continue by calling the select_wakeup routine. This causes any process currently suspended on the select channel (as specified by the selq argument) to resume. RETURN VALUES
None SEE ALSO
Routines: select_dequeue(9r), select_dequeue_all(9r), select_enqueue(9r) System Calls: select(2) select_wakeup(9r)
All times are GMT -4. The time now is 06:08 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy