Function process_utils::kill_and_restart [] [src]

pub fn kill_and_restart(
    pid_info: Vec<Stat>,
    limit: u64,
    kill_parent: bool,
    simulate: bool
) -> IOResult<()>

Kills a process and optionally the parent process and restarts them. simulate will just log and not kill anything. Currently SIGTERM is used to nicely stop processes and wait for them to exit. If you need a bigger hammer this isn't the function for you.