Nutanix AHV – Destroy a cluster

Whether you’re selling the cluster to a third party or repurposing it for another purpose, sometimes you need to destroy a Nutanix cluster. Here’s how to do it…
WARNING
The procedure described below will completely delete all cluster data and configurations. Do not perform this procedure on a production cluster.
Preparing the Cluster for Destruction
Before destroying a cluster, some preparations must be made.
Among the necessary prerequisites, it is imperative that there are no longer any virtual machines running on the cluster. Make sure to migrate/shutdown/delete (as desired) all virtual machines on the cluster.
Note: All the commands in this article must be entered on one of the cluster’s CVMs.
Once this prerequisite is met, we begin by checking the cluster’s status:
cluster status
You should get a return like this:
nutanix@NTNX-5f832032-A-CVM:192.168.84.22:~$ cluster status
2025-07-24 07:20:18,663Z INFO MainThread zookeeper_session.py:136 Using multithreaded Zookeeper client library: 1
2025-07-24 07:20:18,666Z INFO MainThread zookeeper_session.py:248 Parsed cluster id: 4439894058604263884, cluster incarnation id: 1753169113232129
2025-07-24 07:20:18,666Z INFO MainThread zookeeper_session.py:270 cluster is attempting to connect to Zookeeper, host port list zk1:9876
2025-07-24 07:20:18,676Z INFO Dummy-1 zookeeper_session.py:840 ZK session establishment complete, sessionId=0x198310781ce5e38, negotiated timeout=20 secs
2025-07-24 07:20:18,678Z INFO MainThread cluster:3303 Executing action status on SVMs 192.168.84.22
2025-07-24 07:20:18,682Z INFO Dummy-2 zookeeper_session.py:940 Calling c_impl.close() for session 0x198310781ce5e38
2025-07-24 07:20:18,683Z INFO Dummy-2 zookeeper_session.py:941 Calling zookeeper_close and invalidating zhandle
The state of the cluster: start
Lockdown mode: Disabled
CVM: 192.168.84.22 Up, ZeusLeader
Xmount UP [459073, 459235, 459236, 459311]
IkatProxy UP [458789, 458917, 458918, 458919]
Zeus UP [454133, 454189, 454190, 454191, 454201, 454218]
Scavenger UP [459084, 459296, 459297, 459298]
SysStatCollector UP [464017, 464089, 464090, 464091]
IkatControlPlane UP [464039, 464218, 464219, 464220]
SSLTerminator UP [464170, 464323, 464324]
SecureFileSync UP [464362, 464646, 464647, 464648]
Medusa UP [468604, 469223, 469224, 469395, 470062]
DynamicRingChanger UP [476814, 476897, 476898, 476920]
Pithos UP [476843, 477058, 477060, 477086]
InsightsDB UP [476918, 477131, 477132, 477155]
Athena UP [477152, 477270, 477271, 477273]
Mercury UP [513735, 513803, 513804, 513808]
Mantle UP [477391, 477551, 477552, 477562]
VipMonitor UP [485663, 485664, 485665, 485666, 485670]
Stargate UP [477857, 477995, 477996, 477997, 477998]
InsightsDataTransfer UP [478768, 478929, 478930, 478934, 478935, 478936, 478937, 478938, 478939]
GoErgon UP [478834, 479020, 479021, 479039]
Cerebro UP [478950, 479138, 479139, 479306]
Chronos UP [479088, 479286, 479287, 479310]
Curator UP [479234, 479406, 479407, 483968]
Prism UP [479436, 479600, 479601, 479650, 480643, 480885]
Hera UP [479602, 479917, 479918, 479919]
AlertManager UP [479860, 480436, 480438, 480555]
Arithmos UP [480751, 481566, 481567, 481765]
Catalog UP [481670, 482699, 482700, 482701, 483502]
Acropolis UP [483575, 484493, 484494, 488301]
Castor UP [484403, 484877, 484878, 484911, 484972]
Uhura UP [484912, 485066, 485067, 485300]
NutanixGuestTools UP [485132, 485254, 485255, 485284, 485611]
MinervaCVM UP [491046, 491263, 491264, 491265]
ClusterConfig UP [491188, 491361, 491362, 491363, 491381]
APLOSEngine UP [491374, 491650, 491651, 491652]
APLOS UP [495252, 496063, 496064, 496065]
PlacementSolver UP [497033, 497330, 497331, 497332, 497341]
Lazan UP [497256, 497568, 497569, 497570]
Polaris UP [498016, 498620, 498621, 498911]
Delphi UP [498765, 499238, 499239, 499240, 499332]
Security UP [500506, 501578, 501579, 501581]
Flow UP [501478, 502168, 502169, 502171, 502178]
Anduril UP [510708, 511248, 511249, 511252, 511335]
Narsil UP [502382, 502472, 502473, 502474]
XTrim UP [502488, 502629, 502630, 502631]
ClusterHealth UP [502656, 502774, 503156, 503158, 503166, 503174, 503183, 503351, 503352, 503359, 503384, 503385, 503396, 503401, 503402, 503420, 503421, 503444, 503445, 503468, 503469, 503474, 503752, 503753, 503785, 503786, 503817, 503818, 528495, 528533, 528534, 530466, 530467, 530468, 530469, 530474, 530475, 530488, 530512, 530522, 530571, 530576, 530684, 530773, 530791, 531349, 531357]
2025-07-24 07:20:20,740Z INFO MainThread cluster:3466 Success!
Since the cluster is currently started, I first need to stop it with the following command:
cluster stop
Please note: to shut down the cluster, there must be no virtual machines running on the cluster except the CVM.
The command will shut down the cluster and associated services after you confirm the operation with “I agree” and should return something like this:
The state of the cluster: stop
Lockdown mode: Disabled
CVM: 192.168.84.22 Up, ZeusLeader
Xmount UP [1761344, 1761418, 1761419, 1761475]
IkatProxy UP [458789, 458917, 458918, 458919]
Zeus UP [454133, 454189, 454190, 454191, 454201, 454218]
Scavenger UP [459084, 459296, 459297, 459298]
SysStatCollector DOWN []
IkatControlPlane DOWN []
SSLTerminator DOWN []
SecureFileSync DOWN []
Medusa DOWN []
DynamicRingChanger DOWN []
Pithos DOWN []
InsightsDB DOWN []
Athena DOWN []
Mercury DOWN []
Mantle DOWN []
VipMonitor UP [485663, 485664, 485665, 485666, 485670]
Stargate DOWN []
InsightsDataTransfer DOWN []
GoErgon DOWN []
Cerebro DOWN []
Chronos DOWN []
Curator DOWN []
Prism DOWN []
Hera DOWN []
AlertManager DOWN []
Arithmos DOWN []
Catalog DOWN []
Acropolis DOWN []
Castor DOWN []
Uhura DOWN []
NutanixGuestTools DOWN []
MinervaCVM DOWN []
ClusterConfig DOWN []
APLOSEngine DOWN []
APLOS DOWN []
PlacementSolver DOWN []
Lazan DOWN []
Polaris DOWN []
Delphi DOWN []
Security DOWN []
Flow DOWN []
Anduril DOWN []
Narsil DOWN []
XTrim DOWN []
ClusterHealth DOWN []
2025-07-24 07:23:57,716Z INFO MainThread cluster:2194 Cluster has been stopped via 'cluster stop' command, hence stopping all services.
2025-07-24 07:23:57,716Z INFO MainThread cluster:3466 Success!
Now we can move on to destroying the cluster.
Destroying the Cluster
Destroying the cluster requires running the following command:
cluster destroy
The system will then ask you for confirmation before proceeding to delete all configurations and data:
2025-07-24 07:35:45,898Z INFO MainThread zookeeper_session.py:136 Using multithreaded Zookeeper client library: 1
2025-07-24 07:35:45,900Z INFO MainThread zookeeper_session.py:248 Parsed cluster id: 4439894058604263884, cluster incarnation id: 1753169113232129
2025-07-24 07:35:45,900Z INFO MainThread zookeeper_session.py:270 cluster is attempting to connect to Zookeeper, host port list zk1:9876
2025-07-24 07:35:45,916Z INFO Dummy-1 zookeeper_session.py:840 ZK session establishment complete, sessionId=0x198310781ce5e6e, negotiated timeout=20 secs
2025-07-24 07:35:45,918Z INFO Dummy-2 zookeeper_session.py:940 Calling c_impl.close() for session 0x198310781ce5e6e
2025-07-24 07:35:45,918Z INFO Dummy-2 zookeeper_session.py:941 Calling zookeeper_close and invalidating zhandle
2025-07-24 07:35:45,921Z INFO MainThread cluster:3303 Executing action destroy on SVMs 192.168.84.22
2025-07-24 07:35:45,922Z WARNING MainThread genesis_utils.py:348 Deprecated: use util.cluster.info.get_node_uuid() instead
2025-07-24 07:35:45,928Z INFO MainThread cluster:3350
***** CLUSTER NAME *****
Unnamed
This operation will completely erase all data and all metadata, and each node will no longer belong to a cluster. Do you want to proceed? (Y/[N]): Y
The cluster destruction operation will take a few minutes, during which time all remaining data will be completely erased.
Once the cluster destruction is complete, a “cluster status” will allow you to verify that AHV is waiting for the cluster to be created:
nutanix@NTNX-5f832032-A-CVM:192.168.84.22:~$ cluster status
2025-07-24 07:42:50,694Z CRITICAL MainThread cluster:3242 Cluster is currently unconfigured. Please create the cluster.
There you have it, your cluster is destroyed and all you have to do is recreate it.
For those who prefer to follow the procedure via video, here’s my associated YouTube video:
0 comments