Check if the HAXM service is running when starting a Qemu VM with hardware acceleration. Ref #1242.

This commit is contained in:
grossmj
2018-03-24 22:15:20 +07:00
parent 5d704aa478
commit d419d3fa39
3 changed files with 47 additions and 18 deletions

View File

@ -1764,6 +1764,12 @@ class QemuVM(BaseNode):
if version is None:
raise QemuError("HAXM acceleration support is not installed on this host")
log.info("HAXM support version {} detected".format(version))
# check if the HAXM service is running
from gns3server.utils.windows_service import check_windows_service_is_running
if not check_windows_service_is_running("intelhaxm"):
raise QemuError("Intel HAXM service is not running on this host")
else:
return False
elif sys.platform.startswith("darwin"):