Skip to content
This repository has been archived by the owner on May 10, 2020. It is now read-only.

Add libvirt types #50

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions cgroup_top.py
Original file line number Diff line number Diff line change
Expand Up @@ -286,7 +286,7 @@ def type(self):
# Guess cgroup owner
if any(path.startswith(prefix) for prefix in DOCKER_PREFIXES):
return 'docker'
elif path.startswith('/lxc/'):
elif path.startswith('/lxc/') or path.endswith('libvirt-lxc'):
return 'lxc'
elif path.startswith('/user.slice/'):
_, parent, name = path.rsplit('/', 2)
Expand All @@ -296,7 +296,7 @@ def type(self):
return 'systemd'
elif path == '/user.slice' or path == '/system.slice' or path.startswith('/system.slice/'):
return 'systemd'
elif path.startswith('/machine.slice/machine-qemu'):
elif path.startswith('/machine.slice/machine-qemu') or path.endswith('libvirt-qemu'):
return 'qemu-kvm'
elif regexp_ovz_container.match(path) and path != '/0' and HAS_OPENVZ:
return 'openvz'
Expand Down