Skip to content

Commit c90fad0

Browse files
committed
Clarify CloudLinux/ApisCP variable usage
1 parent 382deb7 commit c90fad0

File tree

1 file changed

+20
-0
lines changed

1 file changed

+20
-0
lines changed

docs/admin/Resource enforcement.md

+20
Original file line numberDiff line numberDiff line change
@@ -395,6 +395,26 @@ cat /sys/fs/cgroup/memory/site1/memory.usage_in_bytes
395395

396396
This can be confirmed by examining `memory.stat` in the cgroup home. Likewise memory reported by a process may be higher than memory reported by cgroup, this is because cgroup only accounts for memory uniquely reserved by the application. A fork shares its parent's memory pages and copies-on-write at which point the newly claimed memory is charged to the cgroup.
397397

398+
## CloudLinux terminology
399+
400+
Both ApisCP and CloudLinux utilize cgroups for resource enforcement. The table below summarizes the relationships between CloudLinux limit variables and ApisCP's equivalent settings.
401+
402+
| CloudLinux | ApisCP | Remarks |
403+
| ------------------------------------------------------------ | ------------------------------------------------------------ | ------------------------------------------------------------ |
404+
| [SPEED](https://docs.cloudlinux.com/limits/#speed-limit) | [cgroup,cpuweight](#weighting-usage) | |
405+
|| [cgroup,cpupin](#pinning) | Assign work to logical CPU(s). |
406+
|| [cgroup,cpu](#limiting-cumulative-usage) | 24 hour CPU limit (wall time, seconds). *Overage not presently enforced.* |
407+
| [PMEM](https://docs.cloudlinux.com/limits/#physical-memory-limit) | [cgroup,memory](#memory) | |
408+
| [VMEM](https://docs.cloudlinux.com/limits/#virtual-memory-limit) | [limit_as_soft](https://gitlab.com/apisnetworks/apnscp/-/blob/master/resources/playbooks/roles/system/limits/templates/apnscp.conf.j2) | Does not affect active memory usage, results in undefined behavior in complex software such as [v8](https://github.com/nodejs/node/issues/25933). |
409+
| [IO](https://docs.cloudlinux.com/limits/#io) | [cgroup,writebw](#io) + [cgroup,readbw](#io) | Write/read bandwidth separated to facilitate resource tracking on limited endurance disks. |
410+
| [IOPS](https://docs.cloudlinux.com/limits/#iops) | [cgroup,writeiops](#io) + [cgroup,readiops](#io) | Write/read IOPS separated to facilitate resource tracking on limited endurance disks. |
411+
|| [cgroup,ioweight](#io) | Controls IO priority similar to CPU weight. Requires CFQ/BFQ IO elevator (auto-detection). |
412+
| [NPROC](https://docs.cloudlinux.com/limits/#number-of-processes) | [cgroup,proclimit](#process) | |
413+
| [EP](https://docs.cloudlinux.com/limits/#entry-processes) | [workers](PHP-FPM.md#policy-maps) | Requires policy map usage. |
414+
|| [cgroup:freeze](#freezer), cgroup:thaw | Immediately suspends all activity. Use cgroup:freeze, cgroup:thaw API commands. |
415+
416+
417+
398418
## See also
399419

400420
- [Linux Performance Tools](https://www.brendangregg.com/Slides/Velocity2015_LinuxPerfTools.pdf) by Brendan Gregg

0 commit comments

Comments
 (0)