Howdy!
I am working on a project where I know nothing about what I'm doing as usual.
So here goes..
I have a script the runs from another like this
Code:
$SCRIPTDIR/oblog Overwrite &
echo $! > $PIDDIR/oblog.pid
the script is like this
Code:
if [ "$1" = "Overwrite" ]; then
tail -f $DATADIR/$FNAME.raw |sed -e 's/^~...//' |grep -f $GREPFILE > $DATADIR/$FNAME.ob
I can close the script down like this
Code:
kill -1 `cat $PIDDIR/oblog.pid`
tail, sed, and grep are still running
I want to kill off tail so sed and grep will finish
Maybe some use of --pid with tail, I would need to pipe something to it to do that, not sure
some other signal maybe?
any ideas?
thanks,