Migrating from VitalPBX 4 to 4.5 follows a similar approach to the migration
process from version 3 to 4. Below is a detailed guide to help you complete
the migration process smoothly.
Debian 12 Server Preparation
- Set up a new server with a fresh installation of Debian 12.
- Install VitalPBX 4.5 by following the official installation instructions
here. - Install the same add-ons used on your current production server.
- Complete the wizard setup for the Sonata and VitXi modules. Use
placeholder credentials during the setup; these will be replaced when
the backup is restored. - If OpenVPN is installed and configured on your existing server, install
and configure it on the new Debian 12 server.
Actions on the Debian 11 Server
- Use the Backup and Restore module in VitalPBX to create a backup of
your settings. - For large CDR data and call recordings, transfer these manually
(instructions below). - Save the backup file to your local machine.
- Revoke the VitalPBX license(s) from your current production server.
Importing the Backup to VitalPBX 4.5 (Debian 12)
- Activate the necessary license(s) on the new server.
- Use the Backup and Restore module to import and restore the backup
file. - Run the following commands to ensure all settings are applied
correctly
vitalpbx build-db
vitalpbx fully-gen-conf
- If the CDR and call recordings were migrated manually, execute the
commands above after transferring the data.
Manually Moving Call Recordings and CDR Data
Call Recordings
To transfer call recordings from /var/spool/asterisk/monitor on the Debian
11 server to the same path on the Debian 12 server, run the following rsync
command on the Debian 12 server.
rsync -avz root@<Debian11_IP>:/var/spool/asterisk/monitor/ /var/spool/asterisk/monitor/
Replace <Debian11_IP> with the IP address of the Debian 11 server
CDR Data
To migrate CDR data from the Debian 11 server to the Debian 12 server follow
the steps below.
- Create a MySQL Backup on the Debian 11 server.
mysqldump -u root --add-drop-table --ignore-table=asterisk.cel asterisk > cdr_backup.sql
- Use SCP to transfer the backup file to the Debian 12
scp cdr_backup.sql root@<Debian12_IP>:/root/
- On the Debian 12 server, restore the database.
mysql -u root asterisk < /root/cdr_backup.sql
Post-Migration Testing
- Verify all settings, trunks, extensions, and modules.
- Test critical features like inbound/outbound calls, voicemail, and call
recordings. - Confirm that CDR data and call recordings are accessible and accurate.