Module rustix::process

source ·
Available on crate feature process only.
Expand description

Process-associated operations.

Structs§

Enums§

Constants§

Functions§

  • chdir(path)—Change the current working directory.
  • chroot(path)—Change the process root directory.
  • fchdir(fd)—Change the current working directory.
  • Get the list of descendants of the specified reaper process.
  • Get information about the reaper of the specified process (or the process itself if it is a reaper).
  • getCWD—Return the current working directory.
  • getegid()—Returns the process’ effective group ID.
  • geteuid()—Returns the process’ effective user ID.
  • getgid()—Returns the process’ real group ID.
  • getgroups()—Return a list of the current user’s groups.
  • getpgid(pid)—Returns the process group ID of the given process.
  • getpgrp()—Returns the process’ group ID.
  • getpid()—Returns the process’ ID.
  • getppid()—Returns the parent process’ ID.
  • getpriority(PRIO_PGRP, gid)—Get the scheduling priority of the given process group.
  • getpriority(PRIO_PROCESS, pid)—Get the scheduling priority of the given process.
  • getpriority(PRIO_USER, uid)—Get the scheduling priority of the given user.
  • getrlimit(resource)—Get a process resource limit value.
  • getsid(pid)—Get the session ID of the given process.
  • getuid()—Returns the process’ real user ID.
  • ioctl(fd, TIOCSCTTY, 0)—Sets the controlling terminal for the process.
  • kill(0, sig)—Sends a signal to all processes in the current process group.
  • kill(pid, sig)—Sends a signal to a process.
  • kill(-pid, sig)—Sends a signal to all processes in a process group.
  • nice(inc)—Adjust the scheduling priority of the current process.
  • Check the no_new_privs mode of the specified process.
  • Get the current value of the parent process death signal.
  • Deliver a signal to some subset of
  • sched_getaffinity(pid)—Get a thread’s CPU affinity mask.
  • sched_setaffinity(pid, cpuset)—Set a thread’s CPU affinity mask.
  • sched_yield()—Hints to the OS that other processes should run.
  • Set the state of the dumpable attribute for the process indicated by idtype and id. This determines whether the process can be traced and whether core dumps are produced for the process upon delivery of a signal whose default behavior is to produce a core dump.
  • Enable the no_new_privs mode that ignores SUID and SGID bits on execve in the specified process and its future descendants.
  • Set the parent-death signal of the calling process.
  • Acquire or release the reaper status of the calling process.
  • Set the current value of the capability mode violation trapping behavior. If this behavior is enabled, the kernel would deliver a Signal::Trap signal on any return from a system call that would result in a io::Errno::NOTCAPABLE or [io::Errno::CAPMODE`] error.
  • setpgid(pid, pgid)—Sets the process group ID of the given process.
  • setpriority(PRIO_PGRP, pgid)—Get the scheduling priority of the given process group.
  • setpriority(PRIO_PROCESS, pid)—Get the scheduling priority of the given process.
  • setpriority(PRIO_USER, uid)—Get the scheduling priority of the given user.
  • setrlimit(resource, new)—Set a process resource limit value.
  • setsid()—Create a new session.
  • kill(0, 0)—Check validity of pid and permissions to send signals to the all processes in the current process group, without actually sending any signals.
  • kill(pid, 0)—Check validity of pid and permissions to send signals to the process, without actually sending any signals.
  • kill(-pid, 0)—Check validity of pid and permissions to send signals to all processes in the process group, without actually sending any signals.
  • Get the tracing status of the process indicated by idtype and id.
  • Get the current value of the capability mode violation trapping behavior.
  • umask(mask)—Set the process file creation mask.
  • wait(waitopts)—Wait for any of the children of calling process to change state.
  • waitid(_, _, _, opts)—Wait for the specified child process to change state.
  • waitpid(-pgid, waitopts)—Wait for a process in a specific process group to change state.
  • waitpid(pid, waitopts)—Wait for a specific process to change state.

Type Aliases§

  • A process selector for use with the procctl interface.
  • The raw integer value of a Unix group ID. A group identifier as a raw integer.
  • The raw integer value of a Unix process ID. A process identifier as a raw integer.
  • The raw integer value of a Unix user ID. A user identifier as a raw integer.