This article describes how to replace a failed or faulty Versa Controller (RMA) with a new virtual machine and bring it back into service under the same node name. The procedure disconnects the old Controller from the Director, restores the appliance private key and SSH keys on the new Controller, and syncs the configuration from the Director.
The examples use a Director named VOAE1 and a Controller node named SDWAN-Controller2. Replace these with the names in your deployment.
Note: Values in angle brackets, such as <controller_ip>, are placeholders. Replace them with values from your environment.
|
Step |
Where |
Action |
|
1 |
Director CLI (VOAE1) |
Disconnect the old Controller node |
|
2 |
KVM host of old Controller |
Shut down the old Controller VM |
|
3 |
Director CLI (VOAE1) |
Connect to the new Controller node |
|
4 |
Director bash (VOAE1) |
Copy the flex utility to the new Controller |
|
5 |
Director bash and database |
Retrieve the private key from the Director database |
|
6 |
Director bash (VOAE1) |
Apply the key on the new Controller |
|
7 |
New Controller |
Restart the Controller services |
|
8 |
Director bash (VOAE1) |
Restore the appliance SSH keys |
|
9 |
Director UI |
Sync the configuration to the Controller |
On the Director (VOAE1) CLI, enter configuration mode and disconnect the node.
config
request disconnect-node node-id SDWAN-Controller2
commit
On the KVM host that runs the old Controller VM, power off the VM.
If the Controller is already powered off or shut down. Please proceed with Step 3.
virsh destroy <controller>
Note: <controller> is the VM (domain) name shown by virsh list. This step stops the old VM immediately, so confirm you are on the correct host and VM before you run it.
On the Director (VOAE1) CLI, connect the node. The new Controller takes over the node named SDWAN-Controller2.
config
request connect-node node-id SDWAN-Controller2
commit
From the Director (VOAE1) bash shell, copy the flex_privkey_util script to the new Controller.
cd /opt/versa/vnms/scripts
scp flex_privkey_util admin<controller_ip>:/home/versa/packages/
On the Director (VOAE1) bash shell, retrieve the database password, open the database shell, and query the private key for the Controller.
sudo python3 /opt/versa/vnms/scripts/decrypt_content.py | grep '^export PG_PASSWORD=' | cut -d= -f2 | xargs
pgdb
When prompted, use the password returned by the first command. At the database prompt, run:
\pset pager off
select pvt_key from appliance_keys where device_name = 'SDWAN-Controller2';
Copy the value returned in the pvt_key column. You will use it in Step 6.
Caution: The private key and database password are sensitive. Do not paste them into tickets, chat, or shared documents, and clear your shell history when finished.
From the Director (VOAE1) bash shell, run the flex utility on the new Controller with the key from Step 5.
rsh admin<controller_ip> /home/versa/packages/flex_privkey_util change <key>
On the new Controller, restart the Versa services.
vsh restart
From the Director (VOAE1) bash shell, run the restore script with the new Controller IP address.
cd /opt/versa/vnms/scripts
./restore_appliance_ssh_keys.sh <controller_ip>
Enter the following when prompted:
Director username: <Director_username>
Director password: <Director_password>
Replacement admin password: <controller_password>
In the Director UI:
After the sync completes, confirm that the replacement is healthy. These checks are suggested; adjust them to your environment.