diff --git a/gns3server/modules/dynamips/__init__.py b/gns3server/modules/dynamips/__init__.py index 054a4ac9..aead3a3a 100644 --- a/gns3server/modules/dynamips/__init__.py +++ b/gns3server/modules/dynamips/__init__.py @@ -127,8 +127,8 @@ class Dynamips(IModule): Properly stops the module. """ - #if not sys.platform.startswith("win32"): - # self._callback.stop() + if not sys.platform.startswith("win32"): + self._callback.stop() if self._hypervisor_manager: self._hypervisor_manager.stop_all_hypervisors() IModule.stop(self) # this will stop the I/O loop diff --git a/gns3server/modules/iou/iou_device.py b/gns3server/modules/iou/iou_device.py index ccd9e331..14c64628 100644 --- a/gns3server/modules/iou/iou_device.py +++ b/gns3server/modules/iou/iou_device.py @@ -402,8 +402,9 @@ class IOUDevice(object): log.info("iouyap started PID={}".format(self._iouyap_process.pid)) except OSError as e: - log.error("could not start iouyap: {}".format(e)) - raise IOUError("Could not start iouyap: {}".format(e)) + iouyap_stdout = self.read_iouyap_stdout() + log.error("could not start iouyap: {}\n{}".format(e, iouyap_stdout)) + raise IOUError("Could not start iouyap: {}\n{}".format(e, iouyap_stdout)) def start(self): """ @@ -411,6 +412,10 @@ class IOUDevice(object): """ if not self.is_running(): + + if not os.path.exists(self._path): + raise IOUError("IOU '{}' is not accessible".format(self._path)) + if not self._iourc or not os.path.exists(self._iourc): raise IOUError("A iourc file is necessary to start IOU") @@ -435,8 +440,9 @@ class IOUDevice(object): log.info("IOU instance {} started PID={}".format(self._id, self._process.pid)) self._started = True except OSError as e: - log.error("could not start IOU: {}".format(e)) - raise IOUError("could not start IOU: {}".format(e)) + iou_stdout = self.read_iou_stdout() + log.error("could not start IOU: {}\n{}".format(e, iou_stdout)) + raise IOUError("could not start IOU: {}\n{}".format(e, iou_stdout)) # start console support self._start_ioucon()