[
https://issues.apache.org/jira/browse/CLOUDSTACK-8125?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Likitha Shetty resolved CLOUDSTACK-8125.
----------------------------------------
Resolution: Fixed
+Root Cause Analysis+
Things to note
* After VM migration, ROOT volumes's VMDK name changes. And in the _volumes_
table in DB, _path_ is updated to reflect this change but _chain___info_ is not.
* In case of VMware, when VM is cold migrated, vCenter is unaware of the
migration and hence unaware of the change in the location of the VM's volumes.
* In case of VMware, when CS attempts to start a VM, we retrieve VM's current
disk information from vCenter, tear down the disks from the VM, re-configure
the VM with the disks and power on the VM. During VM re-configuration with the
disks if disk information is returned by vCenter in the first step, then that
information is honored and used to re-configure the VM. Otherwise CS build the
disk information based on the volume's path.
What happened during VM start after a cold migration?
VM was cold migrated and vCenter was unaware of the change in the ROOT
volumes's location/path. And so when asked for VM's disk information, vCenter
returned the old path i.e. the path before the VM was migrated. CS then
re-configured the VM with this wrong disk information and tried to power-on the
VM. This power-on failed with the warning message.
But CS always retries if VM fails to start on the first attempt. And during the
second attempt, when asked for the disk information, vCenter returned with no
disks. vCenter returned no disks because CS tore down the disks during the
first attempt to start the VM. Because vCenter didn't return any disk
information, CS built the disk information based on the volume path (which had
been rightly updated after the cold migration), re-configured the VM with the
right disk and successfully powered-on the VM.
> [VMware] After cold migration of a VM, VM starts with warning messages in MS
> logs
> ---------------------------------------------------------------------------------
>
> Key: CLOUDSTACK-8125
> URL: https://issues.apache.org/jira/browse/CLOUDSTACK-8125
> Project: CloudStack
> Issue Type: Bug
> Security Level: Public(Anyone can view this level - this is the
> default.)
> Affects Versions: 4.5.0
> Reporter: Likitha Shetty
> Assignee: Likitha Shetty
> Priority: Critical
> Fix For: Future
>
>
> +Steps to reproduce+
> 1. Deploy a vm.
> 2. Stop the VM.
> 3. Add another primary storage to the same cluster.
> 4. Migrate the VM to the new primary storage.
> 5. Try to start the VM.
> Issue - First attempt to start the VM fails with
> {noformat}
> java.lang.RuntimeException: File
> []/vmfs/volumes/27951060-bbb89fa5/i-2-10-VM/daadfb44467f41e6a38fd8ba05e28cb4.vmdk
> was not found
> {noformat}
> The VM eventually starts up but the disks are migrated back to the old
> storage.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)