[pve-devel] [PATCH container] fix #2014: don't check if unpriv for blkio

Oguz Bektas o.bektas at proxmox.com
Fri Dec 7 11:34:42 CET 2018


Signed-off-by: Oguz Bektas <o.bektas at proxmox.com>
---
 src/PVE/LXC.pm | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/PVE/LXC.pm b/src/PVE/LXC.pm
index 787d34f..ab15ec0 100644
--- a/src/PVE/LXC.pm
+++ b/src/PVE/LXC.pm
@@ -254,7 +254,7 @@ sub vmstatus {
 	}
 
 	if (-d '/sys/fs/cgroup/blkio') {
-	    my $blkio_bytes = read_cgroup_value('blkio', $vmid, $unpriv, 'blkio.throttle.io_service_bytes', 1);
+	    my $blkio_bytes = read_cgroup_value('blkio', $vmid, 0, 'blkio.throttle.io_service_bytes', 1); # don't check if unpriv
 	    my @bytes = split(/\n/, $blkio_bytes);
 	    foreach my $byte (@bytes) {
 		if (my ($key, $value) = $byte =~ /(Read|Write)\s+(\d+)/) {
-- 
2.11.0





More information about the pve-devel mailing list