![]() |
Hello and Welcome from United States to the UNIX and Linux Forums! Thank You for Visiting and Joining Our Global Community.
|
|
google unix.com
|
|||||||
| Forums | Register | Forum Rules | Links | Albums | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| Shell Programming and Scripting Post questions about KSH, CSH, SH, BASH, PERL, PHP, SED, AWK and OTHER shell scripts and shell scripting languages here. |
More UNIX and Linux Forum Topics You Might Find Helpful
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| How to find the jobs running in background and stop | srinivas_paluku | Shell Programming and Scripting | 7 | 01-28-2008 08:41 PM |
| background jobs exit status and limit the number of jobs to run | GrepMe | Shell Programming and Scripting | 1 | 06-11-2007 06:56 PM |
| Background jobs | Jeremiorama | High Level Programming | 1 | 11-25-2005 09:48 AM |
| background jobs | qsi | Shell Programming and Scripting | 4 | 11-24-2004 05:45 AM |
| exit unix, but says running jobs | yls177 | UNIX for Dummies Questions & Answers | 6 | 10-25-2002 03:08 AM |
![]() |
|
|
LinkBack | Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
|
|
||||
|
Issues with exit after running jobs in background
I have the following sample script to run a script the jobs with the same
priority(in this case field3) in parallel; wait for the jobs to finish and run the next set of jobs in parallel.When all the lines are read exit the script. I have the following script which is doing evrything I want to, but the script does not exit after completing all the jobs. Would appreciate any input as to why the script doesnt exit #!/bin/ksh a=1 cat abc.txt | while read field1 field2 field3 do F1=$field1 F2=$field2 priority=$field3 if[[ $priority -eq $a ]] ; then run_some_job.ksh - $F1 -$F2 $F3& else wait a=`expr $a + 1` fi done exit |
![]() |
| Bookmarks |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|