4 ms·
That looks interesting for some use-cases, but I don't see a way to use it to assign limits to users, or to processes that aren't started as systemd services. W
by _delirium 13y ago
That looks interesting for some use-cases, but I don't see a way to use it to assign limits to users, or to processes that aren't started as systemd services. What I have in mind is that I give someone ssh access, they run R or matlab or from the command line, but limited to 512mb (or 1Gb or whatever) of total memory.
- WestCoastJustin 13y agoOn RHEL systems you can use the 'cgred' service to classify processes based on the user running it or the command itself. For example, say you have user X who always logs in and runs rsync commands and saturates the link. You can automatically classify this user or rsync process into a cgroup that throttles the network IP (or in your use case, memory) -- problem solved. There is some great documentation @ https://access.redhat.com/site/documentation/en-US/Red_Hat_Enterprise_Linux/6/html-single/Resource_Management_Guide/index.html#The_cgred_Service https://access.redhat.com/site/documentation/en-US/Red_Hat_E...
- viraptor 13y agoIt's not RHEL-specific. Ubuntu and pretty much everything that includes cgroups tools has it.
- shykes 13y agoYou could build a matlab docker container and limit memory with 'docker run -m 512M delirium/matlab' :) See http://docker.io http://docker.io
- hdevalence 13y agoYou're in luck; this specific usecase is documented on the Arch Wiki: https://wiki.archlinux.org/index.php/cgroups#Matlab https://wiki.archlinux.org/index.php/cgroups#Matlab