Title: Some issues with managed/unmanaged VMs on KVM · Issue #8439 · apache/cloudstack · GitHub
Open Graph Title: Some issues with managed/unmanaged VMs on KVM · Issue #8439 · apache/cloudstack
X Title: Some issues with managed/unmanaged VMs on KVM · Issue #8439 · apache/cloudstack
Description: There is an issue while importing a VM with a Basic zone network: if you chose to set a random IP address: 2024-01-03 16:51:26,068 ERROR [o.a.c.v.UnmanagedVMsManagerImpl] (API-Job-Executor-10:ctx-bcae51d0 job-864 ctx-e872b0fb) (logid:016...
Open Graph Description: There is an issue while importing a VM with a Basic zone network: if you chose to set a random IP address: 2024-01-03 16:51:26,068 ERROR [o.a.c.v.UnmanagedVMsManagerImpl] (API-Job-Executor-10:ctx-b...
X Description: There is an issue while importing a VM with a Basic zone network: if you chose to set a random IP address: 2024-01-03 16:51:26,068 ERROR [o.a.c.v.UnmanagedVMsManagerImpl] (API-Job-Executor-10:ctx-b...
Opengraph URL: https://github.com/apache/cloudstack/issues/8439
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Some issues with managed/unmanaged VMs on KVM","articleBody":"1. There is an issue while importing a VM with a Basic zone network:\r\n- if you chose to set a random IP address:\r\n\r\n```\r\n2024-01-03 16:51:26,068 ERROR [o.a.c.v.UnmanagedVMsManagerImpl] (API-Job-Executor-10:ctx-bcae51d0 job-864 ctx-e872b0fb) (logid:016f507c) Failed to import NICs while importing vm: i-2-58-VM\r\ncom.cloud.exception.InsufficientVirtualNetworkCapacityException: Unable to acquire Guest IP address for network Network {\"id\": 204, \"name\": \"defaultGuestNetwork\", \"uuid\": \"2c6b7a88-939a-42b1-8a5e-d9641071bff8\",\r\n \"networkofferingid\": 7}Scope=interface com.cloud.dc.DataCenter; id=1\r\n at org.apache.cloudstack.engine.orchestration.NetworkOrchestrator.importNic(NetworkOrchestrator.java:4582)\r\n```\r\n\r\n- if you use a predetermined IP address the import fails with\r\n```\r\n\r\n2024-01-03 16:52:49,765 DEBUG [o.a.c.f.j.i.AsyncJobManagerImpl] (API-Job-Executor-11:ctx-a94ebd23 job-865) (logid:0f522606) Complete async job-865, jobStatus: FAILED, resultCode: 530, result: org.apache.cloudsta\r\nck.api.response.ExceptionResponse/null/{\"uuidList\":[],\"errorcode\":\"530\",\"errortext\":\"IP address 10.2.32.49 for NIC(ID: 0) is not available in network(ID: 2c6b7a88-939a-42b1-8a5e-d9641071bff8)\"}\r\n```\r\n\r\n2. If the storage pool is of type block for the volumes of an unmanaged VM, CS cannot find the pools. The select DB query tries to list by path and host_address which are taken from the libvirt XML disk definition and are not correct (for example it gets the volume path /dev/storpool-byid/bgu4.b.8wm instead of the actual primary storage path /dev/storpool-byid/. Also StorPool for example doesn't have a host described in the XML definition). Probably this issue will appear with similar storage plugins.\r\n\r\n3. Issue with VMs with RBD storage pool. You can unmanage a VM on Ceph storage but the listing of unmanaged VMs fails because libvirt cannot access the RBD volumes.\r\n\r\n```\r\n2024-01-04 11:56:55,383 DEBUG [utils.script.Script] (agentRequest-Handler-2:null) (logid:43ccc964) Executing command [qemu-img info -U cloudstack/d3638e01-955c-4702-8433-b62fe4bc680a ].\r\n2024-01-04 11:56:55,388 WARN [utils.script.Script] (agentRequest-Handler-2:null) (logid:43ccc964) Execution of process [2868475] for command [qemu-img info -U cloudstack/d3638e01-955c-4702-8433-b62fe4bc680a ] f\r\nailed.\r\n2024-01-04 11:56:55,388 DEBUG [utils.script.Script] (agentRequest-Handler-2:null) (logid:43ccc964) Exit value of process [2868475] for command [qemu-img info -U cloudstack/d3638e01-955c-4702-8433-b62fe4bc680a ] \r\nis [1].\r\n2024-01-04 11:56:55,389 WARN [utils.script.Script] (agentRequest-Handler-2:null) (logid:43ccc964) Process [2868475] for command [qemu-img info -U cloudstack/d3638e01-955c-4702-8433-b62fe4bc680a ] encountered th\r\ne error: [qemu-img: Could not open 'cloudstack/d3638e01-955c-4702-8433-b62fe4bc680a': Could not open 'cloudstack/d3638e01-955c-4702-8433-b62fe4bc680a': No such file or directory].\r\n2024-01-04 11:56:55,389 INFO [resource.wrapper.LibvirtGetUnmanagedInstancesCommandWrapper] (agentRequest-Handler-2:null) (logid:43ccc964) Unable to retrieve unmanaged instance info. org.apache.cloudstack.utils.\r\nqemu.QemuImgException: qemu-img: Could not open 'cloudstack/d3638e01-955c-4702-8433-b62fe4bc680a': Could not open 'cloudstack/d3638e01-955c-4702-8433-b62fe4bc680a': No such file or directory\r\njava.lang.RuntimeException: org.apache.cloudstack.utils.qemu.QemuImgException: qemu-img: Could not open 'cloudstack/d3638e01-955c-4702-8433-b62fe4bc680a': Could not open 'cloudstack/d3638e01-955c-4702-8433-b62fe\r\n4bc680a': No such file or directory\r\n at com.cloud.hypervisor.kvm.resource.wrapper.LibvirtGetUnmanagedInstancesCommandWrapper.getUnmanagedInstanceDisks(LibvirtGetUnmanagedInstancesCommandWrapper.java:191)\r\n at com.cloud.hypervisor.kvm.resource.wrapper.LibvirtGetUnmanagedInstancesCommandWrapper.getUnmanagedInstance(LibvirtGetUnmanagedInstancesCommandWrapper.java:135)\r\n```\r\n\r\n\r\n##### ISSUE TYPE\r\n\u003c!-- Pick one below and delete the rest --\u003e\r\n * Bug Report\r\n\r\n\r\n\r\n##### CLOUDSTACK VERSION\r\n\u003c!--\r\nNew line separated list of affected versions, commit ID for issues on main branch.\r\n--\u003e\r\n\r\n~~~\r\ntested with https://github.com/apache/cloudstack/pull/8433\r\n~~~\r\n\r\n\r\n##### OS / ENVIRONMENT\r\n\u003c!--\r\nInformation about the environment if relevant, N/A otherwise\r\n--\u003e\r\nRocky linux 8.5\r\n\r\n\r\n","author":{"url":"https://github.com/slavkap","@type":"Person","name":"slavkap"},"datePublished":"2024-01-04T10:49:46.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":5},"url":"https://github.com/8439/cloudstack/issues/8439"}
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:2d192f08-26e5-7fea-e103-34c57ea0d0c5 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | BD40:397AD8:47D01FD:65527FB:6A4FBA7C |
| html-safe-nonce | 2e8b6d8d93631a8f8c5198174d705f3c23d9c5cf4dc7d6f95c202d76921db861 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJCRDQwOjM5N0FEODo0N0QwMUZEOjY1NTI3RkI6NkE0RkJBN0MiLCJ2aXNpdG9yX2lkIjoiODgxNzQ1Nzg5MjEyODk2MzE5NiIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9 |
| visitor-hmac | 9e6dbf57450b775ec17bd83ed97896bd2b4df81de495b10d2963667de1a1ae80 |
| hovercard-subject-tag | issue:2065425038 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/apache/cloudstack/8439/issue_layout |
| twitter:image | https://opengraph.githubassets.com/c3da46750557dadc9d6b02679cf48a3fed112ff29c81a242714619aa2a70e4a4/apache/cloudstack/issues/8439 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/c3da46750557dadc9d6b02679cf48a3fed112ff29c81a242714619aa2a70e4a4/apache/cloudstack/issues/8439 |
| og:image:alt | There is an issue while importing a VM with a Basic zone network: if you chose to set a random IP address: 2024-01-03 16:51:26,068 ERROR [o.a.c.v.UnmanagedVMsManagerImpl] (API-Job-Executor-10:ctx-b... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | slavkap |
| hostname | github.com |
| expected-hostname | github.com |
| None | b92d11c0aa4a77d54ef4af1078b6a15fb5a70a215b30c4ecf28889d5a8e656d9 |
| turbo-cache-control | no-preview |
| go-import | github.com/apache/cloudstack git https://github.com/apache/cloudstack.git |
| octolytics-dimension-user_id | 47359 |
| octolytics-dimension-user_login | apache |
| octolytics-dimension-repository_id | 9759448 |
| octolytics-dimension-repository_nwo | apache/cloudstack |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 9759448 |
| octolytics-dimension-repository_network_root_nwo | apache/cloudstack |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 4b249b445842943ed31549e027f57a8ade9881ed |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width