5

Korn shell timeout/kill script

view full story
linux-howto

http://unix.stackexchange.com – I am trying to write a simple Korn shell script to execute a loading process. The process occasionally runs into connectivity issues, so I need to kill it if it runs too long. I have been trying the following code: #!/usr/bin/ksh . /home/dw/script/load.ksh & LOADPID=$! sleep 100 kill $LOADPID Unfortunately, the kill command does not kill the process - am I missing something? (HowTos)