Search:
www.rocket99.com : Technical Guides Sybase Oracle UNIX Javascript


Technical Guides
Sybase
Oracle
UNIX
Javascript




After Work

Highlife Adventures
The best club in Chicago
for Chicago Singles is Highlife Adventures!


Jersey Girl Shirts
Are you looking for a
Jersey Girl T-Shirt ?



Kyoto Sushi
in Chicago, on Lincoln Ave.
Moody's Pub
in Chicago, has great burgers
Skylark
in Chicago, on Halsted .. excellent Friday fish fry!


UNIX » Shell » Coding »

Wait for sentinel file to clear

     







-- Shell scripting: wait for sentinel file to clear


#
# Wait for batch queue to clear.
#
# Keep concurrent processes to four or less
#

i=`ls /tmp/batchflag*.log 2>/dev/null | wc -l`

# loop, until three or less batch processes are running.

while test $i -gt 0 ; do

echo "Waiting for sentinel to clear ..."

sleep 10

i=`ls /tmp/batchflag*.log 2>/dev/null | wc -l`

done





-- Alternative

while test -f /tmp/sqlldr*.txt 2>/dev/null ; do

echo `date` " File exists ..."

sleep 5

done











UNIX : Related Topics

UNIX : Shell : Scan a file in a shell script
UNIX : Shell : Formatting a date

Sybase Web Site
Sybase Mobile Web Site
Oracle Web Site





Site Index About this Guide to Sybase, Oracle, and UNIX Contact Us Advertise on this site




Copyright © 2008 Citisoft Inc All Rights Reserved.