CPU pinning: separate tabs for VM and Docker

This commit is contained in:
bergware
2018-09-05 16:22:00 +02:00
parent 48784faa89
commit ebcbdbb235
3 changed files with 47 additions and 23 deletions

View File

@@ -1,4 +1,4 @@
Menu="CPUset"
Menu="CPUset:2"
Title="CPU Isolation"
Tag="leaf"
---
@@ -24,8 +24,7 @@ Tag="leaf"
</form>
<div class="notice isol" style="display:none">System must be rebooted for changes to take effect!</div>
> CPU isolation allows the user to specify CPU cores that are to be explicitly reserved for assignment (to VMs or Containers).
> CPU isolation allows the user to specify CPU cores that are to be explicitly reserved for assignment (to VMs or Docker containers).
>
> This is incredibly important for gaming VMs to run smoothly because even if you manually pin your docker containers to not overlap with your gaming VM,
> This is incredibly important for gaming VMs to run smoothly because even if you manually pin your Docker containers to not overlap with your gaming VM,
> the host OS can still utilize those same cores as the guest VM needs for things like returning responses for the webGui, running a parity check, btrfs operations, etc.

View File

@@ -0,0 +1,39 @@
Menu="CPUset:1"
Title="CPU Pinning Docker"
Tag="map-marker"
---
<?PHP
/* Copyright 2005-2018, Lime Technology
* Copyright 2012-2018, Bergware International.
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License version 2,
* as published by the Free Software Foundation.
*
* The above copyright notice and this permission notice shall be included in
* all copies or substantial portions of the Software.
*/
?>
<?if ($dockerd):?>
<form name="ct">
<input type="hidden" name="names" id="names-ct" value="">
<table class='tablesorter shift' style='width:auto'>
<thead><tr><th><i class="fa fa-list"></i> Container</th><?create()?></tr></thead>
<tbody id="table-ct"><?=$spinner?></tbody>
</table>
<input type="button" value="Apply" onclick="apply(this.form)" disabled><input type="button" value="Done" onclick="done()"><span id="wait-ct" class="red-text" style="display:none"><i class="fa fa-spinner fa-spin"></i> Please wait...</span>
</form>
<?endif;?>
> This page gives a total view of the current CPU pinning assignments for Docker containers.<br>
> It also allows to modify these assignments.
>
> Running containers are **stopped first** and restarted after the modification.<br>
> Stopped containers are instantly modified and new assignments become active when the user manually starts the container.
>
> When ***Apply*** is pressed a scan is performed to find the changes, subsequently containers which have changes are modified in parallel.
>
> *Important: Please wait until all updates are finished before leaving this page*.
>
> By default NO cores are selected for a Docker container, which means it uses all available cores.<br>
> Do not select **ALL** cores for containers, just select **NO** cores if you want unrestricted core use.

View File

@@ -1,5 +1,5 @@
Menu="OtherSettings"
Title="CPU Pinning"
Title="CPU Pinning VM"
Type="xmenu"
Icon="grid.png"
Tag="map-marker"
@@ -195,26 +195,12 @@ $(function(){
</form>
<?endif;?>
<?if ($dockerd):?>
<form name="ct">
<input type="hidden" name="names" id="names-ct" value="">
<table class='tablesorter <?=$libvirtd?'':'shift'?>' style='width:auto'>
<thead><tr><th><i class="fa fa-list"></i> Container</th><?create()?></tr></thead>
<tbody id="table-ct"><?=$spinner?></tbody>
</table>
<input type="button" value="Apply" onclick="apply(this.form)" disabled><input type="button" value="Done" onclick="done()"><span id="wait-ct" class="red-text" style="display:none"><i class="fa fa-spinner fa-spin"></i> Please wait...</span>
</form>
<?endif;?>
> This page gives a total view of the current CPU pinning assignments for both VMs and Docker containers.<br>
> This page gives a total view of the current CPU pinning assignments for VMs.<br>
> It also allows to modify these assignments.
>
> Running VMs or containers are **stopped first** and restarted after the modification.<br>
> Stopped VMs or containers are instantly modified and new assignments become active when the user manually starts the VM or container.
> Running VMs are **stopped first** and restarted after the modification.<br>
> Stopped VMs are instantly modified and new assignments become active when the user manually starts the VM.
>
> When ***Apply*** is pressed a scan is performed to find the changes, subsequently only VMs or containers which have changes are modified in parallel.
> When ***Apply*** is pressed a scan is performed to find the changes, subsequently only VMs which have changes are modified in parallel.
>
> *Important: Please wait until all updates are finished before leaving this page*.
>
> By default NO cores are selected for a Docker container, which means it uses all available cores.<br>
> Do not select **ALL** cores for containers, just select **NO** cores if you want unrestricted core use.