10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
im looking for a portable way to get the PID of the script that is running, and to get every other PIDs that are spawned from it.
and by ever other PIDs, i presume, that would be "child processes".
however, i want to shy away from using any command that is not available on every single unix... (1 Reply)
Discussion started by: SkySmart
1 Replies
2. Shell Programming and Scripting
Hi there !!!
I am writing a script to kill the pids on different linux boxes :cool:
the output of my command gives the pids running on that box, but how can I kill all the pids without looping? :confused:
Code:
ssh $i ps -fu $USER | grep ManServer | grep -v grep | awk '{print $2}' | kill
... (4 Replies)
Discussion started by: prany_cool
4 Replies
3. Homework & Coursework Questions
script to write PIDs to a file
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:
write a script that writes the PID of 2 different processes to a file every... (1 Reply)
Discussion started by: navlelo
1 Replies
4. Solaris
I am trying to determine the root cause of a java process that dies trying to startup during it's cron job.
I did go ahead and change the time that it starts up in the cron file and now it starts successfully.
However is there a way to determine what PID a process was attempting to get when... (5 Replies)
Discussion started by: vedder191
5 Replies
5. Shell Programming and Scripting
Hey,
So I'm new to shell scripting, and I'm trying to write one for my lab that will keep down the work load by deleting processes that are left over from previous sessions.
Basically I want it to do three things.
1) Check the processes running
2) See if that person is logged on.
3) if... (2 Replies)
Discussion started by: prgoodwin
2 Replies
6. Shell Programming and Scripting
I have a script that conducts some SSH calls and I would like to capture the child info so that I can do a sleep and then a cleanup to make sure they do not stay out there as ghosts.
I was told I could do something like this...
#!/bin/sh
for m = job1, job2, job3
x=1... (4 Replies)
Discussion started by: LRoberts
4 Replies
7. Shell Programming and Scripting
Hi,
There is a file having a list of running PIDs (pid_process) and another file having a list of registered PIDs (pid_regieter).
I want to check if:-
a) there is at least one running PID that does not correspond to a
registered PID (listing the PID not registered in the file)
... (1 Reply)
Discussion started by: marconi
1 Replies
8. Shell Programming and Scripting
Hi,
There is a file having a list of running PIDs and another file having a list of registered PIDs. How can we check if the number of running PIDs are less or more than the registered PIDs, comparing the total no. in each and also each value.
Request you to pls give your inputs.
Thanks a... (2 Replies)
Discussion started by: marconi
2 Replies
9. Shell Programming and Scripting
:confused: Hi
i am trying to make a script through which i can get the total number of User and their PID after that kill all Users except the one by which i am currently logged in. (i m using SCO UNIX 5.06)
# id of current usre < total number of current user
USR=`who -u |wc -l`
# id of... (2 Replies)
Discussion started by: aafflatoon
2 Replies
10. HP-UX
How to track the pid of a background child process(shell script) from a parent script ?
For example :-
$ sleep 10000 &
4220
where 4220 is the pid of bg process sleep.
Now my requirement is to keep the sleep statement in a shell script(test.ksh) and will be invoking it from... (3 Replies)
Discussion started by: ramkumar
3 Replies