Created attachment 1451344 [details] Engine log Description of problem: I got: Failed to load resource: the server responded with a status of 500 (Internal Server Error) with empty response body, while trying to get graphic console, while VM is suspending. Version-Release number of selected component (if applicable): Version 4.3.0-0.0.master.20180612172344.git9643156.el7 How reproducible: Every time Steps to Reproduce: 1. Start VM 2. Suspend http://localhost:3000/api/vms/<vm-id>/suspend 3. And get console http://localhost:3000/api/vms/<vm-id>/graphicsconsoles/<console-id> Actual results: Failed to load resource: the server responded with a status of 500 (Internal Server Error) Expected results: Graphic console file
The Engine considers the VM not qualified for a console connection because it is suspended and fails the command on purpose. It issues a clear failure message in the log: "Operation Failed: Vm <vm_name> is not running". Seems to me that the fix should be to fail the request gracefully, returning an error with status CONFLICT and displaying the error message. This is in contrast to what's written under "Expected results", which is that the graphics console should be returned. Could you please address this?
(In reply to Ori Liel from comment #1) > The Engine considers the VM not qualified for a console connection because > it is suspended and fails the command on purpose. It issues a clear failure > message in the log: "Operation Failed: Vm <vm_name> is not running". > Seems to me that the fix should be to fail the request gracefully, returning an > error with status CONFLICT and displaying the error message. Yes, it would be nice if error would be more clearer then just 500 (Internal Server Error).
Verified on ovirt-engine-4.2.6-0.1.el7ev.noarch