{"id":520,"date":"2026-10-20T10:15:52","date_gmt":"2026-10-20T10:15:52","guid":{"rendered":"https:\/\/vcfwizard.nl\/?p=520"},"modified":"2026-10-20T10:19:21","modified_gmt":"2026-10-20T10:19:21","slug":"nsx-precheck-loops-and-upgrade-fails-with-must-complete-precheck-first","status":"publish","type":"post","link":"https:\/\/vcfwizard.nl\/?p=520","title":{"rendered":"NSX precheck loops and upgrade fails with &#8220;must complete precheck first&#8221;"},"content":{"rendered":"\n<p class=\"wp-block-paragraph\">SDDC Manager keeps re-running the NSX (and vCenter) upgrade precheck and never lets the upgrade start. Root cause: a stale ELM drift-detection resource lock in the SDDC Manager database.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Date<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">2026-10-20<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Tags<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">VMware,VCF,VCF 9.1,SDDC Manager,NSX,vCenter,Upgrade,Troubleshooting<\/p>\n\n\n\n<h1 class=\"wp-block-heading\">Summary<\/h1>\n\n\n\n<p class=\"wp-block-paragraph\">While upgrading a VMware Cloud Foundation (VCF) environment to the latest\u00a0<strong>VCF 9.1.1<\/strong>\u00a0patch, the NSX upgrade in SDDC Manager gets stuck in a loop. The precheck completes successfully, but SDDC Manager doesn&#8217;t remember the result. Starting the upgrade fails with\u00a0<strong>&#8220;must complete precheck first&#8221;<\/strong>, and the task resets back to the start.<br><\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"945\" height=\"229\" src=\"https:\/\/vcfwizard.nl\/wp-content\/uploads\/2026\/10\/image.png\" alt=\"\" class=\"wp-image-521\" srcset=\"https:\/\/vcfwizard.nl\/wp-content\/uploads\/2026\/10\/image.png 945w, https:\/\/vcfwizard.nl\/wp-content\/uploads\/2026\/10\/image-300x73.png 300w, https:\/\/vcfwizard.nl\/wp-content\/uploads\/2026\/10\/image-768x186.png 768w, https:\/\/vcfwizard.nl\/wp-content\/uploads\/2026\/10\/image-437x106.png 437w, https:\/\/vcfwizard.nl\/wp-content\/uploads\/2026\/10\/image-677x164.png 677w\" sizes=\"auto, (max-width: 945px) 100vw, 945px\" \/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">The cause was a stale resource lock held by an\u00a0<strong>LCM\u00a0<code>ELM-DRIFT_DETECTION<\/code><\/strong>\u00a0operation in the SDDC Manager\u00a0<code>platform<\/code>\u00a0database. Removing the lock entry resolved the issue and the upgrade continued normally.<br><\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"945\" height=\"165\" src=\"https:\/\/vcfwizard.nl\/wp-content\/uploads\/2026\/10\/image-1.png\" alt=\"\" class=\"wp-image-522\" srcset=\"https:\/\/vcfwizard.nl\/wp-content\/uploads\/2026\/10\/image-1.png 945w, https:\/\/vcfwizard.nl\/wp-content\/uploads\/2026\/10\/image-1-300x52.png 300w, https:\/\/vcfwizard.nl\/wp-content\/uploads\/2026\/10\/image-1-767x134.png 767w, https:\/\/vcfwizard.nl\/wp-content\/uploads\/2026\/10\/image-1-435x76.png 435w, https:\/\/vcfwizard.nl\/wp-content\/uploads\/2026\/10\/image-1-676x118.png 676w\" sizes=\"auto, (max-width: 945px) 100vw, 945px\" \/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\"><\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Environment<\/h2>\n\n\n\n<figure class=\"wp-block-table\"><table class=\"has-fixed-layout\"><thead><tr><th>Item<\/th><th>Value<\/th><\/tr><\/thead><tbody><tr><td>Product<\/td><td>VMware Cloud Foundation (VCF)<\/td><\/tr><tr><td>Target version<\/td><td>VCF 9.1.1 (latest patch)<\/td><\/tr><tr><td>Component<\/td><td>SDDC Manager \u2013 Lifecycle Management (LCM)<\/td><\/tr><tr><td>Affected step<\/td><td>NSX upgrade (also reproduced with vCenter)<\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n<h2 class=\"wp-block-heading\">Symptoms<\/h2>\n\n\n\n<ul class=\"wp-block-list\">\n<li>The NSX upgrade precheck runs and\u00a0<strong>passes<\/strong>, but the result is not retained.<\/li>\n\n\n\n<li>Clicking\u00a0<strong>Upgrade<\/strong>\u00a0fails with:\u00a0<code>must complete precheck first<\/code>.<\/li>\n\n\n\n<li>The upgrade task auto-fails. Running the precheck again (globally or on the individual object) resets the workflow back to the beginning \u2014 an endless loop.<\/li>\n\n\n\n<li><strong>Rebooting the SDDC Manager appliance does not help.<\/strong><\/li>\n\n\n\n<li>Skipping NSX and continuing with the\u00a0<strong>vCenter<\/strong>\u00a0upgrade shows exactly the same behavior, which indicates the problem isn&#8217;t component-specific.<\/li>\n<\/ul>\n\n\n\n<h2 class=\"wp-block-heading\">Cause<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">SDDC Manager uses resource locks (stored in the&nbsp;<code>lock<\/code>&nbsp;table of the&nbsp;<code>platform<\/code>&nbsp;PostgreSQL database) to make sure only one operation works on a domain or system resource at a time.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">In this case an&nbsp;<strong>LCM&nbsp;<code>ELM-DRIFT_DETECTION<\/code><\/strong>&nbsp;operation had acquired a lock and never released it. Because the resource remained locked, the upgrade workflow couldn&#8217;t persist its precheck state or acquire the lock it needed to start, so it kept falling back to the precheck stage.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">A reboot doesn&#8217;t clear this, because the lock is persisted in the database rather than in memory.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Resolution<\/h2>\n\n\n\n<blockquote class=\"wp-block-quote is-layout-flow wp-block-quote-is-layout-flow\">\n<p class=\"wp-block-paragraph\">\u26a0\ufe0f&nbsp;<strong>Important<\/strong><\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>Take a snapshot of the SDDC Manager appliance<\/strong>\u00a0before modifying the database.<\/li>\n\n\n\n<li>In production environments, consider opening a support request with Broadcom before making database-level changes.<\/li>\n\n\n\n<li>Make sure no legitimate operation is still running before you remove a lock.<\/li>\n<\/ul>\n<\/blockquote>\n\n\n\n<h3 class=\"wp-block-heading\">1. Log in to SDDC Manager and switch to root<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">SSH to the SDDC Manager appliance as the&nbsp;<code>vcf<\/code>&nbsp;user, then:<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">bash<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>su -<\/code><\/pre>\n\n\n\n<h3 class=\"wp-block-heading\">2. List the current resource locks<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">bash<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>psql -h localhost -U postgres -d platform -c \"select * from lock;\"<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">Look for the lock entry owned by the drift-detection operation (service\/owner referencing\u00a0<code>ELM-DRIFT_DETECTION<\/code>\u00a0\/\u00a0<code>elm-drift-detection<\/code>). Note its\u00a0<code>id<\/code>.<br><\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"945\" height=\"52\" src=\"https:\/\/vcfwizard.nl\/wp-content\/uploads\/2026\/10\/image-2.png\" alt=\"\" class=\"wp-image-523\" srcset=\"https:\/\/vcfwizard.nl\/wp-content\/uploads\/2026\/10\/image-2.png 945w, https:\/\/vcfwizard.nl\/wp-content\/uploads\/2026\/10\/image-2-300x17.png 300w, https:\/\/vcfwizard.nl\/wp-content\/uploads\/2026\/10\/image-2-763x42.png 763w, https:\/\/vcfwizard.nl\/wp-content\/uploads\/2026\/10\/image-2-436x24.png 436w, https:\/\/vcfwizard.nl\/wp-content\/uploads\/2026\/10\/image-2-672x37.png 672w\" sizes=\"auto, (max-width: 945px) 100vw, 945px\" \/><\/figure>\n\n\n\n<h3 class=\"wp-block-heading\">3. Delete the stale lock<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">Replace&nbsp;<code>&lt;LOCK_ID_OR_OPERATION_ID&gt;<\/code>&nbsp;with the ID from the previous step:<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">bash<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>psql -h localhost -U postgres -d platform -c \"delete from lock where id='&lt;LOCK_ID_OR_OPERATION_ID&gt;';\"<\/code><\/pre>\n\n\n\n<h3 class=\"wp-block-heading\">4. Verify the lock is gone<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">bash<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>psql -h localhost -U postgres -d platform -c \"select * from lock;\"<\/code><\/pre>\n\n\n\n<h3 class=\"wp-block-heading\">5. Retry the upgrade<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">Go back to SDDC Manager, run the NSX precheck once more and start the upgrade. The precheck result is now retained and the NSX upgrade proceeds. Continue with the remaining components (vCenter, etc.) as usual.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Alternative: remove the lock through the API<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Instead of editing the database directly, resource locks can also be listed and released via the&nbsp;<code>\/v1\/resource-locks<\/code>&nbsp;API, as described by William Lam for the VCF 9.0 Installer. Run this from the appliance:<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">bash<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code># Get an access token\nTOKEN=$(curl -s -k -H 'Content-Type: application\/json' https:\/\/localhost\/v1\/tokens \\\n  -d '{\"username\":\"&lt;user&gt;\",\"password\":\"&lt;password&gt;\"}' | jq -r '.accessToken')\n\n# List current locks\ncurl -k -H \"Content-Type: application\/json\" -H \"Authorization: Bearer $TOKEN\" \\\n  -X GET https:\/\/localhost\/v1\/resource-locks\n\n# Release the lock (use serviceId, resourceType, resourceName and operationId from the output above)\ncurl -k -H \"Content-Type: application\/json\" -H \"Authorization: Bearer $TOKEN\" \\\n  -X DELETE https:\/\/localhost\/v1\/resource-locks \\\n  -d '{\"serviceId\":\"elm-drift-detection\",\"resources\":&#91;{\"resourceType\":\"system\",\"resourceName\":\"SYSTEM\"}],\"operationId\":\"&lt;OPERATION_ID&gt;\"}'<\/code><\/pre>\n\n\n\n<h2 class=\"wp-block-heading\">Key takeaways<\/h2>\n\n\n\n<ul class=\"wp-block-list\">\n<li>An upgrade that loops on a\u00a0<strong>successful<\/strong>\u00a0precheck usually points to a\u00a0<strong>lock problem<\/strong>, not a precheck problem.<\/li>\n\n\n\n<li>Rebooting SDDC Manager won&#8217;t clear persisted resource locks.<\/li>\n\n\n\n<li>Always check\u00a0<code>select * from lock;<\/code>\u00a0in the\u00a0<code>platform<\/code>\u00a0database when LCM operations behave unexpectedly.<\/li>\n<\/ul>\n\n\n\n<h2 class=\"wp-block-heading\">References<\/h2>\n\n\n\n<ul class=\"wp-block-list\">\n<li><a href=\"https:\/\/knowledge.broadcom.com\/external\/article\/449148\/vcenter-upgrade-switchover-fails-due-to.html\">Broadcom KB 449148 \u2013 vCenter Upgrade Switchover Fails Due to Domain Resource Lock by OPERATIONS_MANAGER Task<\/a><\/li>\n\n\n\n<li><a href=\"https:\/\/williamlam.com\/2025\/07\/clearing-resource-locks-with-vcf-9-0-installer.html\">William Lam \u2013 Clearing resource locks with VCF 9.0 Installer<\/a><\/li>\n<\/ul>\n","protected":false},"excerpt":{"rendered":"<p>SDDC Manager keeps re-running the NSX (and vCenter) upgrade precheck and never lets the upgrade start. Root cause: a stale ELM drift-detection resource lock in the SDDC Manager database. Date 2026-10-20 Tags VMware,VCF,VCF 9.1,SDDC Manager,NSX,vCenter,Upgrade,Troubleshooting Summary While upgrading a VMware Cloud Foundation (VCF) environment to the latest\u00a0VCF 9.1.1\u00a0patch, the NSX upgrade in SDDC Manager gets [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":495,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_regular_price":[],"currency_symbol":[],"_monsterinsights_skip_tracking":false,"footnotes":""},"categories":[31,18],"tags":[],"class_list":["post-520","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-lab","category-vcf-infrastructuur"],"post_slider_layout_featured_media_urls":{"thumbnail":["https:\/\/vcfwizard.nl\/wp-content\/uploads\/2026\/08\/ChatGPT-Image-13-aug-2026-10_12_19-150x150.png",150,150,true],"post_slider_layout_landscape_large":["https:\/\/vcfwizard.nl\/wp-content\/uploads\/2026\/08\/ChatGPT-Image-13-aug-2026-10_12_19-1200x800.png",1200,800,true],"post_slider_layout_portrait_large":["https:\/\/vcfwizard.nl\/wp-content\/uploads\/2026\/08\/ChatGPT-Image-13-aug-2026-10_12_19-1200x958.png",1200,958,true],"post_slider_layout_square_large":["https:\/\/vcfwizard.nl\/wp-content\/uploads\/2026\/08\/ChatGPT-Image-13-aug-2026-10_12_19-1200x958.png",1200,958,true],"post_slider_layout_landscape":["https:\/\/vcfwizard.nl\/wp-content\/uploads\/2026\/08\/ChatGPT-Image-13-aug-2026-10_12_19-600x400.png",600,400,true],"post_slider_layout_portrait":["https:\/\/vcfwizard.nl\/wp-content\/uploads\/2026\/08\/ChatGPT-Image-13-aug-2026-10_12_19-600x900.png",600,900,true],"post_slider_layout_square":["https:\/\/vcfwizard.nl\/wp-content\/uploads\/2026\/08\/ChatGPT-Image-13-aug-2026-10_12_19-600x600.png",600,600,true],"full":["https:\/\/vcfwizard.nl\/wp-content\/uploads\/2026\/08\/ChatGPT-Image-13-aug-2026-10_12_19.png",1642,958,false]},"_links":{"self":[{"href":"https:\/\/vcfwizard.nl\/index.php?rest_route=\/wp\/v2\/posts\/520","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/vcfwizard.nl\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/vcfwizard.nl\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/vcfwizard.nl\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/vcfwizard.nl\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=520"}],"version-history":[{"count":1,"href":"https:\/\/vcfwizard.nl\/index.php?rest_route=\/wp\/v2\/posts\/520\/revisions"}],"predecessor-version":[{"id":524,"href":"https:\/\/vcfwizard.nl\/index.php?rest_route=\/wp\/v2\/posts\/520\/revisions\/524"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/vcfwizard.nl\/index.php?rest_route=\/wp\/v2\/media\/495"}],"wp:attachment":[{"href":"https:\/\/vcfwizard.nl\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=520"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/vcfwizard.nl\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=520"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/vcfwizard.nl\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=520"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}