Commit 70b81309 authored by Anael Beutot's avatar Anael Beutot
Browse files

Set libvirt environment variables to deactivate logging

parent 67d145b3
Loading
Loading
Loading
Loading
+5 −0
Original line number Diff line number Diff line
import os
import time
import signal
import logging
@@ -152,6 +153,10 @@ class RPCStartHandler(Thread):
            if self.loop.role is not None:
                self.loop.close_plugins()
            logger.debug('Role hypervisor affected')
            # set libvirt environement variables
            os.environ['LIBVIRT_DEBUG'] = '4'
            # os.environ['LIBVIRT_LOG_FILTERS'] = ''
            os.environ['LIBVIRT_LOG_OUTPUT'] = '4:stderr'
            # we don't import those modules at the top because some dependancies
            # may not be installed
            from cloudcontrol.node.hypervisor import Handler as HypervisorHandler