Debian CGROUP Install doesn't work after reboot
Clash Royale CLAN TAG#URR8PPP
up vote
5
down vote
favorite
After I do this on my Debian Stretch:
sudo apt install cgroup-bin cgroup-tools cgroupfs-mount libcgroup1
I can issue this:
sudo systemctl set-property user-1000.slice CPUQuota=40%
I have 4 vCPU host, each CPU takes 10% hit with "stress -cpu 4", but after reboot, I can no longer get the "CPUQuota" to work, again.
I have already have "GRUB_CMDLINE_LINUX_DEFAULT="cgroup_enable=memory swapaccount=1"
So how do I get systemd resource management to work after each reboot without having to reissue:
sudo apt --reinstall install cgroup-bin cgroup-tools cgroupfs-mount libcgroup1
linux systemd cgroups quota
add a comment |Â
up vote
5
down vote
favorite
After I do this on my Debian Stretch:
sudo apt install cgroup-bin cgroup-tools cgroupfs-mount libcgroup1
I can issue this:
sudo systemctl set-property user-1000.slice CPUQuota=40%
I have 4 vCPU host, each CPU takes 10% hit with "stress -cpu 4", but after reboot, I can no longer get the "CPUQuota" to work, again.
I have already have "GRUB_CMDLINE_LINUX_DEFAULT="cgroup_enable=memory swapaccount=1"
So how do I get systemd resource management to work after each reboot without having to reissue:
sudo apt --reinstall install cgroup-bin cgroup-tools cgroupfs-mount libcgroup1
linux systemd cgroups quota
add a comment |Â
up vote
5
down vote
favorite
up vote
5
down vote
favorite
After I do this on my Debian Stretch:
sudo apt install cgroup-bin cgroup-tools cgroupfs-mount libcgroup1
I can issue this:
sudo systemctl set-property user-1000.slice CPUQuota=40%
I have 4 vCPU host, each CPU takes 10% hit with "stress -cpu 4", but after reboot, I can no longer get the "CPUQuota" to work, again.
I have already have "GRUB_CMDLINE_LINUX_DEFAULT="cgroup_enable=memory swapaccount=1"
So how do I get systemd resource management to work after each reboot without having to reissue:
sudo apt --reinstall install cgroup-bin cgroup-tools cgroupfs-mount libcgroup1
linux systemd cgroups quota
After I do this on my Debian Stretch:
sudo apt install cgroup-bin cgroup-tools cgroupfs-mount libcgroup1
I can issue this:
sudo systemctl set-property user-1000.slice CPUQuota=40%
I have 4 vCPU host, each CPU takes 10% hit with "stress -cpu 4", but after reboot, I can no longer get the "CPUQuota" to work, again.
I have already have "GRUB_CMDLINE_LINUX_DEFAULT="cgroup_enable=memory swapaccount=1"
So how do I get systemd resource management to work after each reboot without having to reissue:
sudo apt --reinstall install cgroup-bin cgroup-tools cgroupfs-mount libcgroup1
linux systemd cgroups quota
edited Apr 8 at 15:18
Jeff Schaller
31.1k846105
31.1k846105
asked Mar 31 at 19:07
Hitchhiker2018
261
261
add a comment |Â
add a comment |Â
1 Answer
1
active
oldest
votes
up vote
1
down vote
This is how I fixed the problem. (For some reason, after cgroupfs-mount is installed, the file /lib/systemd/system/cgroupfs-mount.service is linked to /dev/null.)
sudo apt --reinstall instll cgroupfs-mount
sudo rm /lib/systemd/system/cgroupfs-mount.service
sudo systemctl daemon-reload
Now created systemd service file:
sudo nano /lib/systemd/system/cgroupfs-mount.service
[Unit]
Description=CGroups FS Mount
[Service]
Type=oneshot
ExecStart=/etc/init.d/cgroupfs-mount start
ExecStop=/etc/init.d/cgroupfs-mount stop
RemainAfterExit=yes
[Install]
WantedBy=multi-user.target
Once the file is created, issue:
sudo systemctl daemon-reload
Check on the status and enable startup during boot:
sudo systemctl status cgroupfs-mount
sudo systemctl enable cgroupfs-mount
Now test:
sudo systemctl set-property user-1000.slice CPUQuota=40%
sudo systemctl daemon-reload
add a comment |Â
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
up vote
1
down vote
This is how I fixed the problem. (For some reason, after cgroupfs-mount is installed, the file /lib/systemd/system/cgroupfs-mount.service is linked to /dev/null.)
sudo apt --reinstall instll cgroupfs-mount
sudo rm /lib/systemd/system/cgroupfs-mount.service
sudo systemctl daemon-reload
Now created systemd service file:
sudo nano /lib/systemd/system/cgroupfs-mount.service
[Unit]
Description=CGroups FS Mount
[Service]
Type=oneshot
ExecStart=/etc/init.d/cgroupfs-mount start
ExecStop=/etc/init.d/cgroupfs-mount stop
RemainAfterExit=yes
[Install]
WantedBy=multi-user.target
Once the file is created, issue:
sudo systemctl daemon-reload
Check on the status and enable startup during boot:
sudo systemctl status cgroupfs-mount
sudo systemctl enable cgroupfs-mount
Now test:
sudo systemctl set-property user-1000.slice CPUQuota=40%
sudo systemctl daemon-reload
add a comment |Â
up vote
1
down vote
This is how I fixed the problem. (For some reason, after cgroupfs-mount is installed, the file /lib/systemd/system/cgroupfs-mount.service is linked to /dev/null.)
sudo apt --reinstall instll cgroupfs-mount
sudo rm /lib/systemd/system/cgroupfs-mount.service
sudo systemctl daemon-reload
Now created systemd service file:
sudo nano /lib/systemd/system/cgroupfs-mount.service
[Unit]
Description=CGroups FS Mount
[Service]
Type=oneshot
ExecStart=/etc/init.d/cgroupfs-mount start
ExecStop=/etc/init.d/cgroupfs-mount stop
RemainAfterExit=yes
[Install]
WantedBy=multi-user.target
Once the file is created, issue:
sudo systemctl daemon-reload
Check on the status and enable startup during boot:
sudo systemctl status cgroupfs-mount
sudo systemctl enable cgroupfs-mount
Now test:
sudo systemctl set-property user-1000.slice CPUQuota=40%
sudo systemctl daemon-reload
add a comment |Â
up vote
1
down vote
up vote
1
down vote
This is how I fixed the problem. (For some reason, after cgroupfs-mount is installed, the file /lib/systemd/system/cgroupfs-mount.service is linked to /dev/null.)
sudo apt --reinstall instll cgroupfs-mount
sudo rm /lib/systemd/system/cgroupfs-mount.service
sudo systemctl daemon-reload
Now created systemd service file:
sudo nano /lib/systemd/system/cgroupfs-mount.service
[Unit]
Description=CGroups FS Mount
[Service]
Type=oneshot
ExecStart=/etc/init.d/cgroupfs-mount start
ExecStop=/etc/init.d/cgroupfs-mount stop
RemainAfterExit=yes
[Install]
WantedBy=multi-user.target
Once the file is created, issue:
sudo systemctl daemon-reload
Check on the status and enable startup during boot:
sudo systemctl status cgroupfs-mount
sudo systemctl enable cgroupfs-mount
Now test:
sudo systemctl set-property user-1000.slice CPUQuota=40%
sudo systemctl daemon-reload
This is how I fixed the problem. (For some reason, after cgroupfs-mount is installed, the file /lib/systemd/system/cgroupfs-mount.service is linked to /dev/null.)
sudo apt --reinstall instll cgroupfs-mount
sudo rm /lib/systemd/system/cgroupfs-mount.service
sudo systemctl daemon-reload
Now created systemd service file:
sudo nano /lib/systemd/system/cgroupfs-mount.service
[Unit]
Description=CGroups FS Mount
[Service]
Type=oneshot
ExecStart=/etc/init.d/cgroupfs-mount start
ExecStop=/etc/init.d/cgroupfs-mount stop
RemainAfterExit=yes
[Install]
WantedBy=multi-user.target
Once the file is created, issue:
sudo systemctl daemon-reload
Check on the status and enable startup during boot:
sudo systemctl status cgroupfs-mount
sudo systemctl enable cgroupfs-mount
Now test:
sudo systemctl set-property user-1000.slice CPUQuota=40%
sudo systemctl daemon-reload
edited Apr 28 at 13:39
GAD3R
22.2k154891
22.2k154891
answered Apr 28 at 13:34
GaoZu
111
111
add a comment |Â
add a comment |Â
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f434728%2fdebian-cgroup-install-doesnt-work-after-reboot%23new-answer', 'question_page');
);
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password