kill_all_Rscript_s: kill (i.e.: stop) all running "Rscript" processes

Description Usage Arguments Value References See Also Examples

View source: R/kill_pid.R

Description

kill (i.e.: stop) all running "Rscript" processes based on their process ID (pid)

Usage

1
kill_all_Rscript_s(s = 0, m = 0, h = 0, ...)

Arguments

s

numeric. number of seconds to wait before killing the processes

m

numeric. number of minutes to wait before killing the processes

h

numeric. number of hours to wait before killing the processes

...

not used.

Value

an integer vector with the process ID (pid) of the "Rscript" processes.

References

tasklist details from microsoft homepage: http://technet.microsoft.com/en-us/library/bb491010.aspx pskill details from microsoft homepage: http://technet.microsoft.com/en-us/sysinternals/bb896683.aspx

See Also

get_tasklist, get_Rscript_PID, get_pid, kill_pid, kill_all_Rscript_s, pskill

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
## Not run: 
# create several running processes of Rscript (to shitdown)
system("Rscript -e repeat{2+2}", wait = FALSE) # this process should be stuck   
system("Rscript -e repeat{2+2}", wait = FALSE) # this process should be stuck   
# here are there pid numbers:
get_Rscript_PID() 
# let's kill them:
kill_all_Rscript_s()
# they are gone...
get_Rscript_PID() # we no longer have Rscripts running

## End(Not run)

installr documentation built on May 20, 2017, 1:10 a.m.

Search within the installr package
Search all R packages, documentation and source code

Questions? Problems? Suggestions? Tweet to @rdrrHQ or email at ian@mutexlabs.com.

Please suggest features or report bugs in the GitHub issue tracker.

All documentation is copyright its authors; we didn't write any of that.