Our customers often decide to migrate from Windows to Linux due to a number of factors, including the ease of administration, malware attack mitigation and the need to reduce the cost of licensing. Besides, the software used in such cases should be backward compatible. At TrueConf, we value the time of our clients; so we made sure that it is easy to export data from one server to another.
Table of Contents
Step 1. Server data export
To migrate successfully, you need to make sure that the new server installed on Linux and the current server on Windows are of the same version. Our Linux repository always includes only the latest version of the distro. We do not provide earlier versions of the server due to security reasons. So, we suggest updating TrueConf Server for Windows up to the latest version. Read this article to learn how it can be done.
Step 2. Server data export
To migrate TrueConf Server, you will need the registration key of your TrueConf Server instance and the backup copies listed below.
Registration key
Due to security reasons, the registration key cannot be retrieved directly from the TrueConf Server control panel. The email with the key was sent to you when your TrueConf Server instance was registered. To find this email, you can use Server ID (the ID will be displayed in the Summary → License info section).
Main data
Registry
The registry stores the data about users, groups, aliases, conferences, streams, and server settings (LDAP, SIP/H.323, WebRTC, federation parameters etc.).
Open the terminal as the administrator and go to the following directory:
1 |
cd /d [backup] |
where [backup]
is the directory to which TrueConf Server settings will be exported, for example:
1 |
cd /d D:\backup |
Next, run this command to export the registry:
1 |
"C:\Program Files\TrueConf Server\tc_regkey.exe" export "" registry.csv |
Database
The database stores the information from the Reports section of TrueConf Server, including chat history.
How to check the current port number
To make sure that the data is exported successfully, you need to specify the number of the port used for connecting to the database. The 5444
port is used by default.
Since the port could be changed at some point in the past (e.g., the port could be set to 5432
after updating TrueConf Server from versions earlier than 5.2.9), run this command in the terminal to check the current port number:
1 |
findstr port "C:\Program Files\TrueConf Server\database\conf\postgresql.conf" |
Export
Open the command line as the administrator and go to the following directory:
1 |
cd /d [backup] |
where [backup]
is the directory to which the database will be exported, for example:
Then, run this command to export data:
1 |
"C:\Program Files\TrueConf Server\database\bin\pg_dumpall.exe" -p 5444 -U postgres -c -f tcs.dump |
HTTPS settings
If you have configured HTTPS, the key and certificate files will be stored in the directory [installation_path]\httpconf\ssl
where [installation_path]
is the server installation path. Keep the backup copy of this directory in any location you find convenient, e.g., D:\backup\
.
Additional data
Conference and call recordings
If conferences or calls are automatically recorded on the server side, the files will be saved in the Recordings
folder by default (this folder can be found in the TrueConf Server working directory). To find the location of video files, check the Path field in the Recordings section of the TrueConf Server control panel.
If you need to move them to a new server, just copy necessary recordings.
Chat files
All chat files shared by the users of your server are saved in the files
folder in the TrueConf Server working directory by default. To find their exact location, check the Path field in the File Storage section of the TrueConf Server control panel. If you want to move the files to a new server, save a backup copy of this directory.
Log files
If you submit a ticket to TrueConf technical support, you may need to attach log files (e.g., to analyze issues you had when using the previous instance of TrueConf Server).
The log files are located in the TrueConf Server working directory. To export them, create a backup copy of all directories and files listed in the article about logs.
User avatars
Avatars of the users registered on your TrueConf Server instance are stored in the avatars
folder in the TrueConf Server working directory. Copy this directory to a convenient location on your server.
Move all the files to the selected directory on the Linux machine, for example, in the directory /home/$USER/backups/
.
Step 3. TrueConf Server installation
Check this article to learn how TrueConf Server can be installed from a file and repository.
Step 4: Importing data to Linux
sudo -V
.Database
How to check the current port number
To ensure successful data import, you will need to specify the port used for.connecting to the database. The 5444
port is used by default.
Since the port could be changed at some point in the past (e.g., the port could be set to 5433
after updating TrueConf Server from versions earlier than 5.2.9), run this command in the terminal to check the current port number:
1 |
grep port /opt/trueconf/server/etc/database/postgresql.conf |
Import
Disable TrueConf services and restart the database service to close all active connections:
1 2 3 4 |
sudo systemctl stop trueconf-web sudo systemctl stop trueconf-manager sudo systemctl stop trueconf-php sudo systemctl restart trueconf-db |
Later, you will need to complete the following steps to import the database:
- Open the terminal (if it was previously closed).
- Copy the exported file to the directory with the database:
1sudo cp /home/$USER/backups/tcs.dump /opt/trueconf/server/bin/database - Sign in as the postgres user:
1sudo su postgres - Go to the database directory:
1cd /opt/trueconf/server/bin/database - Run the import command and specify the current port:
1./psql -p 5444 -f tcs.dumpThe data import may take much time, if a large number of chats is stored on the server. - Sign out of the postgres user account by running this command:
1exit
Registry
To import the registry from a backup file, you will need to delete the lines that are not compatible with Linux. To do it, run the following commands in the terminal:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 |
sed -i '/install_version/d' /home/$USER/backups/registry.csv sed -i '/Configuration,Working Directory/d' /home/$USER/backups/registry.csv sed -i '/ConfDefault,Working Directory/d' /home/$USER/backups/registry.csv sed -i '/Configuration,Executable Path/d' /home/$USER/backups/registry.csv sed -i '/Configuration,Recordings Path/d' /home/$USER/backups/registry.csv sed -i '/Configuration,Ffmpeg Path/d' /home/$USER/backups/registry.csv sed -i '/Configuration,Push Script/d' /home/$USER/backups/registry.csv sed -i '/Configuration,File Storage Path/d' /home/$USER/backups/registry.csv sed -i '/Configuration,version/d' /home/$USER/backups/registry.csv sed -i '/Configuration,DB Connection String/d' /home/$USER/backups/registry.csv sed -i '/Configuration\\ConfDefault,Working Directory/d' /home/$USER/backups/registry.csv sed -i '/WebManager,server_dir/d' /home/$USER/backups/registry.csv sed -i '/WebManager,db_port/d' /home/$USER/backups/registry.csv sed -i '/WebManager,group_security/d' /home/$USER/backups/registry.csv sed -i '/WebManager,group_admin/d' /home/$USER/backups/registry.csv sed -i '/WebManager,client_path/d' /home/$USER/backups/registry.csv sed -i '/Transceivers/d' /home/$USER/backups/registry.csv sed -i '/WebManager\\API\\AccessTokens/d' /home/$USER/backups/registry.csv sed -i '/WebManager\\API\\RefreshTokens\\/d' /home/$USER/backups/registry.csv sed -i 's/ffmpeg\.exe/\/opt\/trueconf\/server\/bin\/ffmpeg\/ffmpeg\//' /home/$USER/backups/registry.csv |
If your new server has a different IP address, run the following command in the terminal (this command uses blank spaces as delimiters):
1 |
sed -i "s x.x.x.x y.y.y.y " /home/$USER/backups/registry.csv |
where:
x.x.x.x
is the previous IP address with dots (.) escaped, for example, 192.168.0.1
.
y.y.y.y
is the new IP address where dots are not escaped, for example: 192.168.1.1
.
Then import the registry settings with this command:
1 |
sudo /opt/trueconf/server/bin/vcs/tc_regkey import "" /home/$USER/backups/registry.csv |
When all the data is imported, restart the following TrueConf services by running these commands consecutively:
1 2 3 4 |
sudo systemctl restart trueconf-db sudo systemctl start trueconf-manager sudo systemctl start trueconf-web sudo systemctl start trueconf-php |
LDAP
If integration with LDAP was previously configured, you will need to restore default settings because in Windows and Linux, different default values are used for LDAP parameters. To do it, you will need to open the TrueConf Server control panel, go to the LDAP/Active Directory → LDAP settings → Advanced section, and click the Default and Apply buttons consecutively. If you specified some other parameters in the Advanced section, you will need to specify them again and save settings.
Files
Move the files to the default directory /opt/trueconf/server/var/lib/files
.
Name length
When moving files, one should keep in mind that some files may not be saved. This problem occurs due to different OS restrictions on file name length. The NTFS file system used in Windows supports file names with up to 256 characters encoded in UTF-16. The ext4 file system, which is usually used in Linux, supports at most 255 bytes in UTF-8 encoding. In other words, it can support names with up to 255 Latin characters or 127 characters of other alphabets (e.g., Cyrillic alphabet).
So, the file with a non-English name may not be saved due to the restrictions imposed by the Linux kernel.
Solution
To fix this issue, you may use a different file system for Linux or save at-risk files (the ones with long names) so that they could be later sent to users.
SCP use
The following errors may occur when the files are moved with the help of SCP (Secure Copy Protocol):
- Unexpected file name
- The file was renamed because its previous name included non-Latin characters.
Some systems do not support certain characters in file names. So, an error may occur if the file name includes such characters.
Solution
After moving the files, please make sure that all the files, which have non-Latin characters in their names, were transferred correctly. Otherwise, you should manually rename these files based on the information from the original server.
Editing absolute paths
To make sure that the files can be correctly downloaded in chats, you need to edit the absolute paths in all utility files *.resume_data. To do it, go to the directory where the files are stored and run this command in the terminal (in this case, blank spaces are used as delimiters):
1 |
sed -i 's save_path[1-9]*:C:\\TrueConf\\files\\ save_path75:/opt/trueconf/server/var/lib/files/ ' *.resume_data |
HTTPS settings
- Copy the exported folder with the ssl key and certificate to this directory
/opt/trueconf/server/etc/webmanager/ssl
. - Go to the TrueConf Server control panel.
- In the Web → HTTPS section, apply the same key and certificate settings that were used on the previous instance of TrueConf Server.
Additional data
Copy other data saved in Step 2 to the corresponding directories:
- Calls and conference recordings – to the
recordings
folder of the working directory (selected by default) - Logs – to the directory
/opt/trueconf/server/var/log directory
- User avatars – to the
avatars
directory in the working folder.
When all the settings are imported, restart the following TrueConf Server services by running these commands consecutively:
1 2 3 |
sudo systemctl restart trueconf-manager sudo systemctl restart trueconf-web sudo systemctl restart trueconf-php |
Step 5. Testing data migration
Go to the control panel and check if the following data were moved correctly:
- Users and their avatars
- Conferences
- Chat messages
- SMTP settings
- Gateway settings
- Reports
- Other types of information.
Besides, with client applications you can test these features:
- Authorization on the server, including SSO/ADFS if they were configured
- Address book, chat list, conferences in the scheduler
- Availability of chat files for download.
Go to the control panel and check if all the data (avatars, reports, chat messages, users, conferences and other types of information) were correctly imported. If some errors occurred , for example, you mistyped a command and some of the data was not exported, uninstall the server completely and repeat steps 2 and 3.
If all the data was successfully imported, please contact the technical support to reset the hardware key (HW key) to which your license is bound. TrueConf technical support will reset the hardware key for free. You will need to submit a ticket and specify the ID of your server. When the technical support resets the hardware key, please register the server again.
Happy video conferencing!