I just removed everything before and after the pmcmd and this is all I have now. And it still spawns a new process momentarily for a second just after the pmcmd exits
Is there any build in command in unix to kill all the child process for a given process ID ? If any one has script or command, please let me know.
Thanks
Sanjay (4 Replies)
i want to create 3 child processes from the same parent using folk. I know how to use folk but my child processes did not come from the same parent. Any suggestion what i did wrong ? (12 Replies)
Hell Sir,
This is chanikya
Is there any System call which behaves just like fork but i dont want to return back two times to the calling func.
In the following ex iam creating a child process in the called func but the ex prints two times IN MAIN.
ex :-
calling()
{
fork();
}
... (2 Replies)
Hi,
I have written the following it is pretty sloppy but I don't see any reason why I should be losing 54 records from a 3.5 million line file after using it.
What I am doing:
I have a 3.5 million record file with about 80,000 records need a correction. They are missing the last data from... (8 Replies)
!/bin/sh
pid=$(ps -Aj | grep MSTRSvr | grep -v grep | awk '{print $1}')
sid=$(ps -Aj | grep MSTRSvr | grep -v grep | awk '{print $3}')
ps -s "$sid"
I am not able to get the desired output it says process list error
if i use watch ps -s "$sid" it considers only the first session id (5 Replies)
hi
i need shell script in ksh for the automation process in informtica.
The automation process is like this .
i have a folder in unix . when this folder gets updated (like if a file or files is/are added to the folder) an event in informatica is triggered and after the process is done in... (2 Replies)
Hi everyone
i am very new to linux , working on bash shell.
I am trying to solve the given problem
1. Create a process and then create children using fork
2. Check the Status of the application for successful running.
3. Kill all the process(threads) except parent and first child... (2 Replies)
Hi guys i have a problem with a script... this script creates differents GUI with YAD... well i want that when i press the "Cancel" button on this graphical interface all the child process and even the same script should be killed
#!/bin/bash
function gui_start {
local choice=""
... (4 Replies)
Hi,
I have setup keys between user1@server1 and user2@server2 however, the ssh is failing.
server1 is Linux 3.10.0-514.6.2.el7.x86_64 #1 SMP whereas server2 is 5.10 Generic_150400-40 sun4v sparc sun4v
I have checked port 22 to be open and keys to be correct. I also find the permissions... (3 Replies)
Hi All
Below code is working as expected but creating too many child processes when the url is not up and every minute that process is sending false email alerts
any help with the logic not to generate child process and not to send duplicate alerts
app="https://url"
appresult=$(wget... (2 Replies)
Discussion started by: srilinux09
2 Replies
LEARN ABOUT NETBSD
setpgid
SETPGID(2) BSD System Calls Manual SETPGID(2)NAME
setpgid, setpgrp -- set process group
LIBRARY
Standard C Library (libc, -lc)
SYNOPSIS
#include <unistd.h>
int
setpgid(pid_t pid, pid_t pgrp);
int
setpgrp(pid_t pid, pid_t pgrp);
DESCRIPTION
setpgid() sets the process group of the specified process pid to the specified pgrp. If pid is zero, then the call applies to the current
process. If pgrp is zero, then the process id of the process specified by pid is used instead.
If the invoker is not the super-user, then the affected process must have the same effective user-id as the invoker or be a descendant of the
invoking process.
RETURN VALUES
setpgid() returns 0 when the operation was successful. If the request failed, -1 is returned and the global variable errno indicates the
reason.
ERRORS
setpgid() will fail and the process group will not be altered if:
[EACCES] The value of the pid argument matches the process ID of a child process of the calling process, and the child process has
successfully executed one of the exec functions.
[EINVAL] The value of the pgrp argument is less than zero.
[EPERM] The effective user ID of the requested process is different from that of the caller and the process is not a descendant of
the calling process.
[ESRCH] The value of the pid argument does not match the process ID of the calling process or of a child process of the calling
process.
SEE ALSO getpgrp(2)STANDARDS
The setpgid() function conforms to ISO/IEC 9945-1:1990 (``POSIX.1'').
COMPATIBILITY
setpgrp() is identical to setpgid(), and is retained for calling convention compatibility with historical versions of BSD.
BSD December 18, 2003 BSD