Unable to create VM
-
@Sugarat If you are running XO from sources, make sure you're completely up-to-date with the latest source. There was a fix released for this earlier this week.
-
@Danp Thanks for that. I built the XO from source a few days back, but maybe it just missed that. I'll rebuild now and see what happens.. Thanks
-
I have just rebuilt the XO install, and that error has... apparently changed into a different one. Create VM operation still fails, but this time the message is:
HANDLE_INVALID(SR, OpaqueRef:NULL) This is a XenServer/XCP-ng error
Hmph
-
@Sugarat I'm not able to replicate here. Can you check under
Settings > Logs
to see if there is an entry there with a detailed error log? -
@Danp I tried removing the second host from the pool but it now still will not allow me to create a VM.
Ah, nice. I did not know that you could drill down into the error. The dump is as follows:
vm.create { "clone": false, "existingDisks": {}, "installation": { "method": "cdrom", "repository": "8eb59f38-25e2-4486-b7c2-98dc938e1fc6" }, "name_label": "Windows 10 (64-bit)", "template": "3d3a2920-24c8-f280-5c27-1e4d4a82253c-7774689b-4ca1-4dea-8545-dddd6b64c17f", "VDIs": [ { "bootable": false, "device": "0", "size": 34359738368, "type": "system", "SR": "3d615d9a-4b54-cf75-ef43-0d08bbf0a640", "name_description": "Created by XO", "name_label": "Windows 10 (64-bit)_epunu" } ], "VIFs": [ { "network": "945f1105-893e-becc-35fe-0a97328ee7ac", "allowedIpv4Addresses": [], "allowedIpv6Addresses": [] } ], "CPUs": 2, "cpusMax": 2, "cpuWeight": null, "cpuCap": null, "name_description": "", "memory": 4294967296, "bootAfterCreate": true, "copyHostBiosStrings": false, "createVtpm": false, "destroyCloudConfigVdiAfterBoot": false, "secureBoot": false, "share": false, "coreOs": false, "tags": [], "hvmBootFirmware": "uefi" } { "code": "HANDLE_INVALID", "params": [ "SR", "OpaqueRef:NULL" ], "call": { "duration": 8, "method": "VDI.create", "params": [ "* session id *", { "name_description": "Created by XO", "name_label": "Windows 10 (64-bit)_epunu", "other_config": {}, "read_only": false, "sharable": false, "SR": "OpaqueRef:NULL", "type": "user", "virtual_size": 34359738368 } ] }, "message": "HANDLE_INVALID(SR, OpaqueRef:NULL)", "name": "XapiError", "stack": "XapiError: HANDLE_INVALID(SR, OpaqueRef:NULL) at Function.wrap (file:///opt/xo/xo-builds/xen-orchestra-202412191835/packages/xen-api/_XapiError.mjs:16:12) at file:///opt/xo/xo-builds/xen-orchestra-202412191835/packages/xen-api/transports/json-rpc.mjs:38:21 at runNextTicks (node:internal/process/task_queues:60:5) at processImmediate (node:internal/timers:454:9) at process.callbackTrampoline (node:internal/async_hooks:130:17)"
-
I am having the same issue which I also have two hosts which I just updated my XO from source yesterday. My log looks the exact same.
-
Seems like it is missing the SR information during VDI creation. Does this also occur with other SR types, ie: local storage?
-
@Danp Yes. Even when I select a local SSD SR it still happens. I'm not able to create any VM's at all, no matter which SR I am selecting.
-
Hi @Sugarat. thanks for the report.
Can you try this branch:fix-handle-inavlid-vm-creation
?
This should fix the issue -
@MathieuRA It does indeed Sir. Thank you very much!