Power on a virtual machine failed with 'StaleObjectStateException' error.
search cancel

Power on a virtual machine failed with 'StaleObjectStateException' error.

book

Article ID: 419827

calendar_today

Updated On:

Products

VMware Cloud Director

Issue/Introduction

  • Upgraded from VMware Cloud Director 10.5.* to VMware Cloud Director 10.6.1.1.
  • The OVDC is configured with the flex allocation model and has elasticity enabled.
  • The number of resource pools in an OVDC is less than the number of resource pools in the backed PVDC.
  • Power on a virtual machine fails with the StaleObjectStateException error while adding missing resource pools for the corresponding OVDC.
    vcloud-container-debug.log
    yyyy-mm-ddThh:mm:ss,nnn  | DEBUG    | Backend-activity-pool-*** | VC20VirtualEngine              | Resource pool [vcId=***, moref=resgroup-***] not found! Waiting a sec...
    yyyy-mm-ddThh:mm:ss,nnn  | ERROR    | Backend-activity-pool-*** | DeployVmOnFabricsActivity      | [Activity Execution] Uncaught Exception during Activity execution. 
    java.util.concurrent.ExecutionException: org.hibernate.StaleObjectStateException: Row was updated or deleted by another transaction (or unsaved-value mapping was incorrect): [com.vmware.vcloud.fabric.compute.model.VRPModel#***]
  • Task Details
    Internal Server Error
    - Unable to perform this action. Contact your cloud administrator.
    - Row was updated or deleted by another transaction (or unsaved-value mapping was incorrect): [com.vmware.vcloud.fabric.compute.model.VRPModel#***]
  • Retrying the power on operation should succeed, as it will add the missing resource pools to the corresponding OVDC.

Environment

VMware Cloud Director 10.6.1.1

Cause

This is a known issue affecting VMware Cloud Director version 10.6.1.

Resolution

This will be fixed in VMware Cloud Director version 10.6.1.2 version.

Workaround:
Option 1:
1) Log in to the VMware Cloud Director Provider portal.
2) Navigate to Organization VDCs under Resources.
3) Select the VDC where the VM is failing to power on.
4) In the left panel, click Allocation and then select Edit.
5) Without changing any value/parameter.
6) Save it.
7) Check if the number of resource pools in an OVDC is same to the backed PVDC.
8) Try powering on the VM again.

Option 2:
Retry power on the same virtual machine.

Additional Information

Error 'Internal Server Error - Row was updated or deleted by another transaction' when powering on virtual machines in the VMware Cloud Director tenant portal