Back Up and Restore NetQ
The following sections describe how to back up and restore your NetQ data and VMs for on-premises deployments.
- You must run backup and restore scripts with sudo privileges.
- NetQ does not retain custom-signed certificates during the backup and restore process. If your deployment uses a custom-signed certificate, you must reconfigure the certificate after you restore it on a new NetQ VM.
- The backup and restore process does not retain several configurations necessary for the Grafana integration, including switch TLS certificates, authentication tokens (vm-tokens), OpenTelemetry configurations, and external time-series database configurations. After reinstalling NetQ, you must reconfigure these components. Grafana will not display data from previous NetQ versions.
Back Up Your NetQ Data
Follow the process below for your deployment type to back up your NetQ data:
- Retrieve the
vm-backuprestore.shscript:
a. Log in to the NVIDIA Application Hub.
b. Select NVIDIA Licensing Portal.
c. Select Software Downloads from the menu.
d. In the search field, enter NetQ.
e. Locate the latest NetQ Upgrade Backup Restore file and select Download.
f. If prompted, read the license agreement and proceed with the download.
- Copy the
vm-backuprestore.shscript to your NetQ server in standalone deployments, or to each node in cluster deployments:
username@hostname:~$ scp ./vm-backuprestore.sh nvidia@10.10.10.10:/home/nvidia/
nvidia@10.10.10.10's password:
vm-backuprestore.sh
Then copy the vm-backuprestore.sh script to the /usr/sbin/ directory on your NetQ servers:
nvidia@netq-server:~$ sudo cp ./vm-backuprestore.sh /usr/sbin/
- Log in to your NetQ server and set the script to executable. Do this for each node in your deployment:
nvidia@netq-server:/home/nvidia# sudo chmod +x /usr/sbin/vm-backuprestore.sh
- On your NetQ server (or the master node in cluster deployments), run the
/usr/sbin/vm-backuprestore.sh --backupcommand. This command backs up each node in your deployment and combines the data into a single .tar file. Take note of the config key in the output of this command. You will enter it when you restore your data:
nvidia@netq-server:~$ sudo /usr/sbin/vm-backuprestore.sh --backup
Fri Jan 17 05:44:13 2025 - Please find detailed logs at: /var/log/vm-backuprestore.log
Stopping pods...
Fri Jan 17 05:44:13 2025 - Stopping pods in namespace default
Fri Jan 17 05:44:19 2025 - Scaling all pods to replica 0
Fri Jan 17 05:44:38 2025 - Waiting for all pods to go down in namespace: default
Fri Jan 17 05:45:39 2025 - Stopping pods in namespace ingress-nginx
Fri Jan 17 05:45:43 2025 - Scaling all pods to replica 0
Fri Jan 17 05:45:57 2025 - Waiting for all pods to go down in namespace: ingress-nginx
Fri Jan 17 05:45:57 2025 - Stopping pods in namespace monitoring
Fri Jan 17 05:46:01 2025 - Scaling all pods to replica 0
Fri Jan 17 05:46:14 2025 - Waiting for all pods to go down in namespace: monitoring
Fri Jan 17 05:46:14 2025 - All pods are down
Fetching master and worker IPs...
Running backup on all nodes...
Running backup on master node (10.188.46.221)...
Fri Jan 17 05:46:14 2025 - Starting backup of data, the backup might take time based on the size of the data
Fri Jan 17 05:46:15 2025 - Creating backup tar /opt/backuprestore/backup-netq-cluster-onprem.tar
Backup is successful
Running backup on worker node (10.188.46.193)...
Fri Jan 17 05:46:19 2025 - Please find detailed logs at: /var/log/vm-backuprestore.log
Fri Jan 17 05:46:19 2025 - Starting backup of data, the backup might take time based on the size of the data
Fri Jan 17 05:46:19 2025 - Creating backup tar /opt/backuprestore/backup-netq-cluster-onprem.tar
Backup is successful
Running backup on worker node (10.188.44.55)...
Fri Jan 17 05:46:44 2025 - Please find detailed logs at: /var/log/vm-backuprestore.log
Fri Jan 17 05:46:44 2025 - Starting backup of data, the backup might take time based on the size of the data
Fri Jan 17 05:46:45 2025 - Creating backup tar /opt/backuprestore/backup-netq-cluster-onprem.tar
Backup is successful
Combining tars from all nodes...
Adding the latest master tar...
Fetching the latest tar from worker node (10.188.46.193)...
Fetching the latest tar from worker node (10.188.44.55)...
Creating combined tar at /opt/backuprestore/combined_backup_20250117054718.tar...
Cleaning up temporary files...
Combined tar created at /opt/backuprestore/combined_backup_20250117054718.tar
The config key is EhVuZXRxLWVuZHBvaW50LWdhdGV3YXkYsagDIixWMnkyRVRwbkxVVXBTVDFsSXUzM3NzRlNkMFE5S0Y3OFlVRVdBWUU5K244PQ==, alternately the config key is available in file /tmp/config-key
Starting pods on master node...
Fri Jan 17 05:48:25 2025 - Scaling all pods to replica 1
Fri Jan 17 05:50:01 2025 - Waiting for all pods to come up
Fri Jan 17 05:58:14 2025 - All pods are up
- Copy the newly created tarball from the server and restore the data on your new VM.
nvidia@netq-server:~$ sudo scp /opt/backuprestore/combined_backup_20250117054718.tar username:password@<destination>
Restore Your NetQ Data
To restore your NetQ data, perform a new NetQ VM installation and follow the steps to restore your NetQ data when you run the netq install command. You will use the restore option, referencing the path where the backup file resides.