sivhaga
IS-IT--Management
- Jun 3, 2008
- 25
I have got an inputfile having processes names.
The file called atp.text has got two fields and looks like:
createcase createaa
createcase createbb
createcase createcc
This file has got a 85 records and we started all the processes with the following command:
{
cmd="nohup " $1 " ATP $ENVIRONMENT -sectionname " $2
system(cmd)
}
The above code starts all the processes from the above file.The challenge that im facing now is when one or more processes have stopped, how do i check if they have stopped and how to start it. How do i compare from the system and the one from my input file which one has stopped.If it has stopped i have to start it but if it is still running i have to skip it
Which code can i use on Unix or Awk. Pls pls pls I have spend 3 weeks and not winning.
Thanks in advance
The file called atp.text has got two fields and looks like:
createcase createaa
createcase createbb
createcase createcc
This file has got a 85 records and we started all the processes with the following command:
{
cmd="nohup " $1 " ATP $ENVIRONMENT -sectionname " $2
system(cmd)
}
The above code starts all the processes from the above file.The challenge that im facing now is when one or more processes have stopped, how do i check if they have stopped and how to start it. How do i compare from the system and the one from my input file which one has stopped.If it has stopped i have to start it but if it is still running i have to skip it
Which code can i use on Unix or Awk. Pls pls pls I have spend 3 weeks and not winning.
Thanks in advance