Struct procfs::process::Limits

source ·
pub struct Limits {
Show 16 fields pub max_cpu_time: Limit, pub max_file_size: Limit, pub max_data_size: Limit, pub max_stack_size: Limit, pub max_core_file_size: Limit, pub max_resident_set: Limit, pub max_processes: Limit, pub max_open_files: Limit, pub max_locked_memory: Limit, pub max_address_space: Limit, pub max_file_locks: Limit, pub max_pending_signals: Limit, pub max_msgqueue_size: Limit, pub max_nice_priority: Limit, pub max_realtime_priority: Limit, pub max_realtime_timeout: Limit,
}
Expand description

Process limits

For more details about each of these limits, see the getrlimit man page.

Fields§

§max_cpu_time: Limit

Max Cpu Time

This is a limit, in seconds, on the amount of CPU time that the process can consume.

§max_file_size: Limit

Max file size

This is the maximum size in bytes of files that the process may create.

§max_data_size: Limit

Max data size

This is the maximum size of the process’s data segment (initialized data, uninitialized data, and heap).

§max_stack_size: Limit

Max stack size

This is the maximum size of the process stack, in bytes.

§max_core_file_size: Limit

Max core file size

This is the maximum size of a core file in bytes that the process may dump.

§max_resident_set: Limit

Max resident set

This is a limit (in bytes) on the process’s resident set (the number of virtual pages resident in RAM).

§max_processes: Limit

Max processes

This is a limit on the number of extant process (or, more precisely on Linux, threads) for the real user rID of the calling process.

§max_open_files: Limit

Max open files

This specifies a value one greater than the maximum file descriptor number that can be opened by this process.

§max_locked_memory: Limit

Max locked memory

This is the maximum number of bytes of memory that may be locked into RAM.

§max_address_space: Limit

Max address space

This is the maximum size of the process’s virtual memory (address space).

§max_file_locks: Limit

Max file locks

This is a limit on the combined number of flock locks and fcntl leases that this process may establish.

§max_pending_signals: Limit

Max pending signals

This is a limit on the number of signals that may be queued for the real user rID of the calling process.

§max_msgqueue_size: Limit

Max msgqueue size

This is a limit on the number of bytes that can be allocated for POSIX message queues for the real user rID of the calling process.

§max_nice_priority: Limit

Max nice priority

This specifies a ceiling to which the process’s nice value can be raised using setpriority or nice.

§max_realtime_priority: Limit

Max realtime priority

This specifies a ceiling on the real-time priority that may be set for this process using sched_setscheduler and sched_setparam.

§max_realtime_timeout: Limit

Max realtime timeout

This is a limit (in microseconds) on the amount of CPU time that a process scheduled under a real-time scheduling policy may consume without making a blocking system call.

Trait Implementations§

source§

impl Clone for Limits

source§

fn clone(&self) -> Limits

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for Limits

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result<(), Error>

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for Limits

source§

fn deserialize<__D>( __deserializer: __D ) -> Result<Limits, <__D as Deserializer<'de>>::Error>where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl FromBufRead for Limits

source§

impl Serialize for Limits

source§

fn serialize<__S>( &self, __serializer: __S ) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where __S: Serializer,

Serialize this value into the given Serde serializer. Read more

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for Twhere T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for Twhere T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for Twhere T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T> FromRead for Twhere T: FromBufRead,

source§

fn from_read<R>(r: R) -> Result<T, ProcError>where R: Read,

Read the type from a Read.
source§

fn from_file<P>(path: P) -> Result<Self, ProcError>where P: AsRef<Path>,

Read the type from a file.
source§

impl<T, U> Into<U> for Twhere U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<T> ToOwned for Twhere T: Clone,

§

type Owned = T

The resulting type after obtaining ownership.
source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
source§

impl<T, U> TryFrom<U> for Twhere U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for Twhere U: TryFrom<T>,

§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
source§

impl<T> DeserializeOwned for Twhere T: for<'de> Deserialize<'de>,