|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
|
|
Be the architects of evolution and help create the mobile internet future. It’s your move---enter to win here! |
|
#1
|
|||
|
|||
|
killing jobs in C-shell scripts
Hi all,
I'd like to know how to run and kill jobs in a c-shell scripts.. I mean: last week I tried to run this simple script: #! /bin/csh donalduck & sleep 60 kill %1 the problem is that sometimes it' s not able to stop the background script (donalduck running job not found). I' ve tried to substitute the line : "kill %1" with "kill -9 %1" or "kill <pid>" or "kill -9 <pid>", but the behaviour is the same!! Moreover it seems that the problem is only present in c-shell scripts because I ran the same script using Ksh and it worked always well. Can anybody explain me the different behaviuor from the two shell?? Is there any other mechanism I can use inr C-shell to overcome the problem? Thanks for the support! |
|
#2
|
|||
|
|||
|
imo
the best cmd-line shell: csh the worst script shell: csh csh (in script) is buggy, bsd joungs did not finish the job ![]() don't use csh for scripts, if you want sure they work on EVERY *nix use bourne. if you need more infos, google for csh scripts, a lot of papers. |
![]() |
| Viewing: Dev Shed Forums > Operating Systems > UNIX Help > killing jobs in C-shell scripts |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|