An NSX-T upgrade within VMware Cloud Foundation (VCF) fails and the corresponding upgrade task is marked as cancelled.
The folllowng erros can be found for the upgrade task ID in /var/log/vmware/vcf/lcm/lcm-debug.log
Error acquiring resource lock.
Error in acquiring resource locks Lock for resource LEGACY of type deployment cannot be acquired by LCM service and TASK_ID task. Reason: Resource is already locked by FSM service and null task ..
VMware Cloud Foundation 9.1
A stale lock entry existed in the SDDC Manager lock table for the domain resource, preventing the upgrade from acquiring the necessary lock.
Take a snapshot of the SDDC manager VM
SSH into the SDDC Manager appliance as the VCF user and switch to root user.
Validate if a lock exists.
psql -h localhost -U postgres -d platform -c "select * from lock;"
If there is a lock, Delete the DB lock entry
psql -h localhost -U postgres -d platform -c "delete from lock where id='1#######-####-####-####-###########';"/opt/vmware/vcf/operationsmanager/scripts/cli/sddcmanager_restart_services.sh