10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hello:
Am trying to understand why the method #2 works but method #1 does not.
For both methods, sending CTRL+C should kill both the Parent script & all of the spanwd background procs.
Method #1:
==========================
#!/bin/sh
ctrl_c()
{
echo "** Trapped CTRL-C"
... (3 Replies)
Discussion started by: gilgamesh
3 Replies
2. UNIX for Dummies Questions & Answers
need script(shell or python) for killing pid in linux (2 Replies)
Discussion started by: roshan9995
2 Replies
3. Homework & Coursework Questions
Use and complete the template provided. The entire template must be completed. If you don't, your post may be deleted!
1. The problem statement, all variables and given/known data:
That is the last reply I received from my instructor, and I'm looking for some alternatives.
When using... (2 Replies)
Discussion started by: newuser45
2 Replies
4. Shell Programming and Scripting
I had issues with processes locking up. This script checks for processes and kills them if they are older than a certain time.
Its uses some functions you'll need to define or remove, like slog() which I use for logging, and is_running() which checks if this script is already running so you can... (0 Replies)
Discussion started by: sukerman
0 Replies
5. Solaris
Say I have 2 processes(perl scripts on Solaris machine) A and B.
the process A kill the process B.
While in the process B how do I print the PID of the process that Killed it(process A) before dieing.
My process A looks like
open(STATS, "ps -ef|");
while ($inputLine = <STATS>) {
if... (7 Replies)
Discussion started by: enigma_007
7 Replies
6. Shell Programming and Scripting
Hi folks,
I have tried to add some trap detection in the below script....this script is used to monitor database activities...in a rather awkward way :rolleyes:....
The idea behind adding trap is that....this script creates lots of temporary files in the running folder to store the count... (1 Reply)
Discussion started by: frozensmilz
1 Replies
7. UNIX for Dummies Questions & Answers
Hi,
I need to get the pid of a process and have to store the pid in a variable and i want to use this value(pid) of the variable for some process. Please can anyone tell me how to get the pid of a process and store it in a variable. please help me on this.
Thanks in advance,
Amudha (7 Replies)
Discussion started by: samudha
7 Replies
8. UNIX for Advanced & Expert Users
What option is used with kill to cause the server to reread its config file. (16 Replies)
Discussion started by: jo calamine
16 Replies
9. Shell Programming and Scripting
gurus,
normally to stop a process ,i need to kill all its child & then parent process.
i do it manually as follows
bash-2.03$ ps -ef | grep bpm|grep -v grep
tibadmin 21882 21875 0 May 27 ? 0:00 /bin/sh ./bpmse_20.sh -Xms512m -Xmx512m /tibco/UpdateCustomer/dat/UpdateCustome
... (0 Replies)
Discussion started by: abhijeetkul
0 Replies
10. UNIX for Dummies Questions & Answers
1. If I use an software application(which connects to the database in the server) in my local pc, how many PID should be registered? Would there be PID for the session and another PID for socket connection?
2. I noticed (through netstat) that when I logged in using the my software application,... (1 Reply)
Discussion started by: pcx26
1 Replies