JItsi Meet Multiple Videobridges with Load Balancing
- At least two Linux systems with Debian 10
- DNS Record for your domain (in our case meet.domain.com)
First of all, we prepare our system by updating all package lists and packages. To do so run the following commands.
sudo apt update && apt upgrade -y #If you are a root user, then you don't need to use Sudo
Add the Jitsi Repository
echo 'deb https://download.jitsi.org stable/' >> /etc/apt/sources.list.d/jitsi-stable.list sudo wget -qO - https://download.jitsi.org/jitsi-key.gpg.key | apt-key add - sudo apt update
Install jitsi meet
Now we are ready to install Jitsi Meet by running the following command. This will install all required components for Jitsi to work, including the web component, jicofo, jitsi-videobridge and much more.
sudo apt install jitsi-meet -y
During the installation, you will be asked to enter the FQDN (Domain name) of the Jitsi Meet instance. Please be sure to enter the correct hostname (in our case meet.domain.com)
Generate a certificate
You can select the letsencrypt or choose other certificates if you.
At this point we are already able to use Jitsi Meet. You can even test it by navigating to the hostname of your Jitsi Meet instance (in our case meet.domain.com)
Jitsi Meet on a single machine is fine if you only have a few videostreams but at some point, your single instance may get too busy to handle all meetings on its own.
open the file
/etc/jitsi/videobridge/sip-communicator.properties. It should look similar to this.
org.ice4j.ice.harvest.DISABLE_AWS_HARVESTER=true org.ice4j.ice.harvest.STUN_MAPPING_HARVESTER_ADDRESSES=meet-jit-si-turnrelay.jitsi.net:443 org.jitsi.videobridge.ENABLE_STATISTICS=true org.jitsi.videobridge.STATISTICS_TRANSPORT=muc org.jitsi.videobridge.xmpp.user.shard.HOSTNAME=localhost org.jitsi.videobridge.xmpp.user.shard.DOMAIN=auth.meet.domain.com org.jitsi.videobridge.xmpp.user.shard.USERNAME=jvb org.jitsi.videobridge.xmpp.user.shard.PASSWORD=hdg6dhdD org.jitsi.videobridge.xmpp.user.shard.MUC_JIDS=JvbBrewery@internal.auth.meet.domain.com org.jitsi.videobridge.xmpp.user.shard.MUC_NICKNAME=4d45d5-sd44d-5sf42d-2s54-g44sds4s4fg
Add the following lines to the end of this file.
Modify the line org.jitsi.videobridge.xmpp.user.shard.MUC_NICKNAME to this.
Configure the second machine
Connect to the second machine, add the required repositories and install jitsi-videobridge by running the following commands.
echo 'deb https://download.jitsi.org stable/' >> /etc/apt/sources.list.d/jitsi-stable.list wget -qO - https://download.jitsi.org/jitsi-key.gpg.key | apt-key add - sudo apt update sudo apt install jitsi-videobridge2 -y
Again, you will be asked for the hostname of your installation. Please enter the FQDN of the first machine (in our case meet.domain.com)
Next, also open the file
/etc/jitsi/videobridge/sip-communicator.properties and add the following lines to the end.
Find the line
org.jitsi.videobridge.xmpp.user.shard.HOSTNAME and set it to the
meet.domain.com of the first machine. whatever your domain is.
In addition, please change the line
org.jitsi.videobridge.xmpp.user.shard.MUC_NICKNAME to this.
For Short Names
Get the credentials from First Server
On the first machine, please open the file
/etc/jitsi/videobridge/config and find the line
JVB_SECRET. Copy the password and go back to the second machine.
Replace the passwords in the following two files by the password you just copied.
Restart the services on Server 1
sudo service prosody reload sudo service jicofo restart sudo service jitsi-videobridge2 restart # Generally we do not recommand to start the video-bridge on the main meet server. So you can stop it. sudo service nginx restart
Restart videobridge on Server 2
sudo service jitsi-videobridge2 restart
Check the following log files on Server 1 to verify the videobridge nodes are joined successfully.
tail -f /var/log/jitsi/jicofo.log tail -f /var/log/jitsi/jvb.log /var/log/prosody/prosody.log
Check the following log files on Serve 2.
tail -f /var/log/jitsi/jvb.log