Upgrade to LiveSwitch V1.14 from V1.11
Migrate Redis Configuration to PostgreSQL
LiveSwitch v1.11 and earlier uses Redis to store configuration data. In LiveSwitch v1.14, using Redis to store configuration data is no longer supported. You must use PostgreSQL to store configuration data.
The necessary steps to migrate for standalone and cluster installation are as the following:
Standalone Installation | Cluster Installation |
---|---|
|
|
If your server configuration is simple, rather than exporting and importing your configuration settings, you are better to have a fresh install of v1.14 with the PostgreSQL instance and manually enter your settings in the Configuration console.
Prerequisite
- You need to use the LiveSwitch command-line tool for the migration. You can find it in the
LiveSwitch CLI
folder of the LiveSwitch v1.14 installation package for Windows and Linux. Copy them to the desired location. - Install a PostgreSQL instance and get the connection string.
Upgrade LiveSwitch Installed on Windows
Run Windows Command Prompt as the administrator and stop the LiveSwitch servers:
net stop "gateway" net stop "media server" net stop "sip connector"
Export the configuration from Redis to a file using the LiveSwitch command-line tool. You can name your file at your choice to the desired location. Inside the command-line tool directory, run the following:
FM.LiveSwitch.Cli.exe export -f {path/to/file}
Import the previously exported configuration using the LiveSwitch command-line tool :
FM.LiveSwitch.Cli.exe import -f {path/to/file} -c {Postgres_connection_string}
Install LiveSwitch v1.14 using the PostgreSQL instance.
Confirm the servers start up correctly and the configuration is the same as before.
Upgrade LiveSwitch Installed on Linux Distribution
Stop the LiveSwitch servers:
sudo systemctl stop gateway sudo systemctl stop media_server sudo systemctl stop sip_connector
Export the configuration from Redis to a file using the LiveSwitch command-line tool. You can name your file at your choice to the desired location. Inside the command-line tool directory, run the following:
sudo dotnet FM.LiveSwitch.Cli.dll export -f {path/to/file}
Import the previously exported configuration using the LiveSwitch command-line tool :
sudo dotnet FM.LiveSwitch.Cli.dll import -f {path/to/file} -c {Postgres_connection_string}
Install LiveSwitch v1.14.
For all the servers, edit the configuration files to add the PostgreSQL connection string.
Restart the LiveSwitch servers:
sudo systemctl start gateway sudo systemctl start media_server sudo systemctl sip_connect
Confirm the servers start up correctly, and the configuration is the same as before.
Upgrade LiveSwitch Installed on Docker
Stop the liveswitch-gateway container.
Export the configuration from Redis to a file using the LiveSwitch command-line tool. You can name your file at your choice to the desired location. Inside the command-line tool directory, run the following:
sudo dotnet FM.LiveSwitch.Cli.dll export -f {path/to/file} -c {redis_connection_string}
Import the configuration:
sudo dotnet FM.LiveSwitch.Cli.dll export -f {path/to/file} -c {Postgres_connection_string}
Update your liveswitch-gateway image to v1.14:
sudo docker pull frozenmountain/liveswitch-gateway:latest
Remove the existing liveswitch-gateway docker container:
sudo docker rm liveswitch-gateway
Recreate the liveswitch-gateway container using the PostgreSQL configuration.
Update your liveswitch-media-server docker image to v1.14:
sudo docker pull frozenmountain/liveswitch-media-server:latest
Remove the existing liveswitch-media-server docker container:
sudo docker rm liveswitch-media-server
Recreate the liveswitch-media-server container using the PostgreSQL configuration.
Run the containers and make sure the configuration is the same as before.
Add Forbidden TURN Peer CIDR Ranges
LiveSwitch v1.14 supports Forbidden TURN Peer CIDR configuration. A new installation includes a list of forbidden CIDR ranges by default which represent private and reserved IANA ranges. However, if you are upgrading from v1.11 and earlier to v1.14, to prevent security vulnerability, you are recommended to manually add those ranges in the Configuration Console → Deployment →Forbidden TURN Peer CIDR section:
- 0.0.0.0/8
- 10.0.0.0/8
- 100.64.0.0/10
- 127.0.0.0/8
- 169.254.0.0/16
- 172.16.0.0/12
- 192.0.0.0/24
- 192.0.2.0/24
- 192.88.99.0/24
- 192.168.0.0/16
- 198.18.0.0/15
- 198.51.100.0/24
- 203.0.113.0/24
- 240.0.0.0/4
- ::/128
- ::1/128
- 100::/64
- 2001:db8::/32
- fc00::/7
- fe80::/10