You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cloudstack.apache.org by GitBox <gi...@apache.org> on 2020/09/23 20:13:19 UTC

[GitHub] [cloudstack] ravening edited a comment on pull request #4282: Prevents null pointers when doing consecutive VM migrates

ravening edited a comment on pull request #4282:
URL: https://github.com/apache/cloudstack/pull/4282#issuecomment-697946918


   > Hi, @ravening can you report the methodology you used?
   > 
   > * ACS version
   > 
   > * How are you executing the tests? Are you migrating VMs running? Stopped VMs? Stopped VMs, and then starting them, and just then migrating again?
   > 
   > 
   > 
   > If you take a look at the code, a null pointer will for sure happen. Just look at the lines I am changing.
   > 
   > 
   > 
   > Before this PR, the first migration will have `host_id` or `last_host_id`, but during the migrate, ACS will set the field `last_host_id` to null using the `afterStorageMigrationCleanup` method, and on the next executions of the migrate command (without starting the VM), this field will be null and then on this line, a NPE will be launched
   > 
   > https://github.com/apache/cloudstack/blob/d657ef7d5b4594b638eaf7df312b11efb99000fb/engine/orchestration/src/main/java/com/cloud/vm/VirtualMachineManagerImpl.java#L2282-L2283
   > 
   > 
   > 
   > Furthermore, some of these parameters were never used for some hypervisors, seems like VMWare needs it, that is why I moved it where they will be used, and did the necessary validations providing information about the process with an appropriate log message
   
   @RodrigoDLopez im using ACS 4.14
   
   I doing regular VM migration of running VM between multiple hosts. I didn't do migration with storage. Also I'm doing migration on KVM host and not VMware


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org