Displaying 4 results from an estimated 4 matches for "pid_exist".
Did you mean:
pid_exists
2018 Aug 30
3
Detecting whether a process exists or not by its PID?
...nce started.
I can the PID of each cluster nodes by querying them for their
Sys.getpid(), e.g.
pids <- parallel::clusterEvalQ(cl, Sys.getpid())
Is there a function in core R for testing whether a process with a
given PID exists or not? From trial'n'error, I found that on Linux:
pid_exists <- function(pid) as.logical(tools::pskill(pid, signal = 0L))
returns TRUE for existing processes and FALSE otherwise, but I'm not
sure if I can trust this. It's not a documented feature in
?tools::pskill, which also warns about 'signal' not being standardized
across OSes.
The...
2018 Aug 31
2
Detecting whether a process exists or not by its PID?
...t; > Sys.getpid(), e.g.
> >
> > pids <- parallel::clusterEvalQ(cl, Sys.getpid())
> >
> > Is there a function in core R for testing whether a process with a
> > given PID exists or not? From trial'n'error, I found that on Linux:
> >
> > pid_exists <- function(pid) as.logical(tools::pskill(pid, signal = 0L))
> >
> > returns TRUE for existing processes and FALSE otherwise, but I'm not
> > sure if I can trust this. It's not a documented feature in
> > ?tools::pskill, which also warns about 'signal' n...
2018 Aug 31
0
Detecting whether a process exists or not by its PID?
...ster nodes by querying them for their
> Sys.getpid(), e.g.
>
> pids <- parallel::clusterEvalQ(cl, Sys.getpid())
>
> Is there a function in core R for testing whether a process with a
> given PID exists or not? From trial'n'error, I found that on Linux:
>
> pid_exists <- function(pid) as.logical(tools::pskill(pid, signal = 0L))
>
> returns TRUE for existing processes and FALSE otherwise, but I'm not
> sure if I can trust this. It's not a documented feature in
> ?tools::pskill, which also warns about 'signal' not being standardize...
2018 Aug 31
0
Detecting whether a process exists or not by its PID?
....g.
>>>
>>> pids <- parallel::clusterEvalQ(cl, Sys.getpid())
>>>
>>> Is there a function in core R for testing whether a process with a
>>> given PID exists or not? From trial'n'error, I found that on Linux:
>>>
>>> pid_exists <- function(pid) as.logical(tools::pskill(pid, signal = 0L))
>>>
>>> returns TRUE for existing processes and FALSE otherwise, but I'm not
>>> sure if I can trust this. It's not a documented feature in
>>> ?tools::pskill, which also warns about 's...