I got some PMs about sharing how I do my fusion upgrades, so thought I would post this here. would love some critique from the experts, as I certainly am not one. I have assumed a basic knowledge of fusion / linux so am not providing all the commands. I like this route as I just move the external IP from the old box to the new Box, any issues and I can just move it back. you also get a brand new clean up to date OS. I only do this about once a year, so dont mind the extra work.
- deploy clean new fusion install using your usual method
- grab a backup from your old server, I use the generic fusion backup script thats on the website, I uncomment the line so it creates a package with everything in - upload to new server and extract, dont overwrite any of the new server stuff
- get new server db password
cat /etc/fusionpbx/config.conf | grep password - get backup db file location from extracted file, i.e /home/admin/var/backups/fusionpbx/postgresql
- create a restore script, input password from step 3 and sql file location from step 4
-
Code:
nano restore.sh #!/bin/sh database_host=127.0.0.1 database_port=5432 export PGPASSWORD="INSERT new server db password here" #remove the old database psql --host=$database_host --port=$database_port --username=fusionpbx -c 'drop schema public cascade;' psql --host=$database_host --port=$database_port --username=fusionpbx -c 'create schema public;' #restore the database pg_restore -v -Fc --host=$database_host --port=$database_port --dbname=fusionpbx --username=fusionpbx PATH TO SQL BACKUP HERE #restart freeswitch systemctl service freeswitch restart echo "Restore Complete";
- chmod +x restore.sh and run script
- reboot server
- update db schema, run twice
cd /var/www/fusionpbx
php /var/www/fusionpbx/core/upgrade/upgrade.php - login with U & P from your old install
- login to GUI and run all GUI updates
- copy recordings, VM recordings etc
cd /home/admin/var/lib
cp -R freeswitch /var/lib - reboot server
- Login to the web interface
- From the dashboard press the SETTINGS button.
- If you changed the groups assigned in the Dashboard.
- Then print the page and save it to a PDF for reference later.
- Select the first checkbox this will select all the ones below it.
- Then press the DELETE button
- Then go to the Menu and press Advanced then click on Upgrade.
- Put a checkmark in App Defaults then press the Execute
Last edited: