Skip to content

Reset Node

Post cluster provisioning, there can be scenarios where admins may wish to fully deprovision the nodes of all installed software components. Tools are provided to help perform a factory reset of the nodes. This process will remove all installed software and bring the node back to a clean state.


Deprovision Node

The below command is to de-provision the existing nodes. On entering this command, a prompt message appears for the node removal confirmation. Enter YES to de-provision all the installed components.

./conjurer -deprovision

(or) use the shorthand

./conjurer -d

Important

The conjurer -d command cleans up the cron jobs brought up as part of the provisioning process, but does not affect user-created cron jobs

Example

ubuntu@user1:~$ ./conjurer -deprovision -force

[+] Removing all the components installed by conjurer and provisioning......(This might take up to 30 minutes to complete. Please be patient!)
    [-] Removing Consul......
    [-] Removing etcd......
    [-] Removing kubernetes components ......(This step might take up to 20 minutes to complete. Please be patient!)
    [-] Removing salt-minion......
    [-] Removing Chisel Service......
    [-] Removing docker and containerd......
    [-] Removing partitions......

[+] Finishing up ......
    [+] Updating the node......(This step might take sometime to complete. Please be patient!)
    [+] Daemon reload......

======> Reboot the node now. You may want to rerun [conjurer -deprovision] (especially if you're using external storage) until lsblk output does not contain any bricks. <======

Force Deprovision Node

The below command is to by-pass the prompt message and continue to remove the nodes. Provide the force flag along with the deprovision flag to bypass the prompt message at the time of removing the components. Customers can use this flag in their automation script or the existing pipeline in place

./conjurer -deprovision -force

(or) use the shorthand

./conjurer -d -f

Example

ubuntu@user1:~$ ./conjurer -deprovision -force

[+] Removing all the components installed by conjurer and provisioning......(This might take up to 30 minutes to complete. Please be patient!)
    [-] Removing Consul......
    [-] Removing etcd......
    [-] Removing kubernetes components ......(This step might take up to 20 minutes to complete. Please be patient!)
    [-] Removing salt-minion......
    [-] Removing Chisel Service......
    [-] Removing docker and containerd......
    [-] Removing partitions......

[+] Finishing up ......
    [+] Updating the node......(This step might take sometime to complete. Please be patient!)
    [+] Daemon reload......

======> Reboot the node now. You may want to rerun [conjurer -deprovision] (especially if you're using external storage) until lsblk output does not contain any bricks. <======

Note

Any errors occurring in the process of de-provision are resolved during reboot