ns_rlimit - Get or set resource limit in the operating system
This command allows one to query or set the resource limits specified in the operating system for the current process. The command is named after the getrlimit/setrlimit call available on most unix-like systems. The commands returns on success a pair of values, which are the soft and hard limit for a specified resource (see below for the interfaced resources). The command allows only to change the soft limit. The specified value might be an integer or the constant unlimited.
A typical use case for this command is to query or set e.g. the coresize via the NaviServer configuration file or at run time in a syntax independent of the naming and conventions in the various startup scripts (e.g. upstart, systemd, ...).
Get or set the maximum size of core file created on program aborts. When 0 no core dump files are created. When nonzero, larger dumps are truncated to this size.
Get or set the maximum size of the process's data segment.
Get or set the maximum number of file descriptor number that can be opened by this process.
Get or set the maximum size of files that the process may create.
Get or set the maximum size of the process's virtual memory (address space) in bytes.
When the server is for some reason in an unknown state, the command ns_rlimit can be used to force a core dump via ns_crash also for running processes, which were started with a core dump limit of 0.
% ns_rlimit coresize unlimited unlimited unlimited % ns_crash