1
0
Fork 0
mirror of https://github.com/munin-monitoring/contrib.git synced 2025-07-22 02:51:03 +00:00

kvm_net: switch to python3

This commit is contained in:
Lars Kruse 2018-06-10 17:37:22 +02:00
parent 67cc769c87
commit 3267bbd0ef

View file

@ -1,5 +1,4 @@
#!/usr/bin/python #!/usr/bin/python3
# -*- coding: utf-8 -*-
# vim: set fileencoding=utf-8 # vim: set fileencoding=utf-8
# #
# Munin plugin to show the network I/O per vm # Munin plugin to show the network I/O per vm
@ -112,7 +111,7 @@ def list_pids():
@return a list of pids from running kvm @return a list of pids from running kvm
""" """
pid = Popen("pidof qemu-kvm qemu-system-x86_64 kvm", shell=True, stdout=PIPE) pid = Popen("pidof qemu-kvm qemu-system-x86_64 kvm", shell=True, stdout=PIPE)
return pid.communicate()[0].split() return pid.communicate()[0].decode().split()
if __name__ == "__main__": if __name__ == "__main__":