Upgrade OpenVidu Elastic: On-premises#
On-premises
OpenVidu offers an updater that allows you to upgrade your OpenVidu deployment in an easy and automated way. The updater will take care of the whole process, from stopping the services to updating the configuration files.
Upgrading OpenVidu Elastic#
Upgrading OpenVidu Elastic is very simple. These are the steps you need to follow:
-
First, make sure to shut down OpenVidu Elastic. SSH into all the nodes and execute the following command:
-
SSH into your Master Node and your Media Nodes and execute on each of them the following command:
To upgrade to a specific version instead, replace
latestwith the version number (e.g.3.x.y). -
In all the nodes, you will see the following output:
Stopping OpenVidu service... Backing up files... - Backing up file '/opt/openvidu/config' to '/opt/openvidu/backups/<DATE>_<VERSION>/config' ... More files ... -------------------- 📦 Backup directory: /opt/openvidu/backups/<DATE>_<VERSION>/ -------------------- -------------------- 🚀 Updating OpenVidu from 3.x.x to 3.y.y -------------------- ? Do you want to update from 3.x.x to 3.y.y? › • Yes No -
Confirm each version upgrade. You can jump straight to the latest release no matter how far behind you are, the updater will automatically apply every intermediate upgrade in sequence.
For each intermediate version, the updater will ask you to confirm the upgrade, display a diff of configuration file changes, ask whether to apply the diff, and ask whether to pull updated Docker images. You must confirm each step.
Warning
The updater will flag any deployment breaking changes if they are present. Pay special attention to these, as they may require you to update firewall rules, open or close specific ports, or perform other manual configuration changes.
Pulling Docker images
When upgrading across multiple intermediate versions, answer
Nowhen the updater asks whether to pull images at each intermediate step. Only answerYesfor the final version.Any missing images will be pulled automatically when you run
systemctl start openvidu. -
After the last intermediate upgrade completes, execute the following command in all the nodes:
The journalctl command will show you the logs of the OpenVidu services. You can stop the logs by pressing Ctrl + C.
Backups and Rollback#
When you finish the upgrade process on each node, you will have a backup of the previous version in the /opt/openvidu/backups directory. The backup only contains the previous configuration files that have changed in the upgrade process.
To roll back to the previous version, you have to copy the files from the backup to the OpenVidu directory. You can do it with the following command:
Where <DATE> and <VERSION> are the date and version of the backup you want to restore. For example:
You need to do this in all the nodes of your OpenVidu Elastic deployment to restore to the previous version.
Recommendations#
- Always upgrade all nodes in your OpenVidu Elastic deployment. Running mismatched versions across nodes may cause compatibility issues.
- If you encounter any problems during an upgrade, a full redeployment is always the recommended path to a clean installation.
- Keep your Docker and Docker Compose versions up to date.
-
Remove unused images and containers to free up disk space. For example, once the upgrade is complete and OpenVidu is running, you can remove old images with the following command:
This command removes all images that are not currently in use by any container.