Move to new server

Status
Not open for further replies.

mrjoli021

Member
Jul 20, 2017
133
2
18
47
I have an old FusionPBX that has been running for years without any issues. It is running on a cloud provider with Debian 8 and Freeswitch 1.6. I am moving cloud providers and have built a new Debian 10 box on a the new provider. I would like to move all the domains and configs for each domain including extensions, custom scripts and any vm's. What is the recommended process to move the config to the new server. Is it just a back of the old one and then a restore, or is there something special, or a different way of doing this?
 

Patrick_S

Member
Oct 21, 2021
33
0
6
35
I would also like some insight on this I am moving from GCP to Azure and the restore file fails because the directories do not exist. I feel like I am missing something very simple I just dont know what it is.
 

ad5ou

Active Member
Jun 12, 2018
892
204
43
The exact methods sort of depend on your environment. Usually the easiest way to restore a setup from a different machine or from a saved backup is to start with a fresh OS install and install a fresh copy of fusionpbx to get all of the needed software ready. Then use a version of the script found at docs.fusionpbx.com to get the backed up data into the new server. Database passwords between old and new will be different unless you set correct password in config.sh before installing new system so you may need to copy/save /etc/fusionpbx/config.php and config.lua to maintain access to database.

Basic steps:
Create a backup of everything needed for fusionpbx (backup script available on most installs already or can be found at docs.fusionpbx.com)
Copy backup to safe location if using same server instance
Install fresh copy of whichever OS you plan on using
Install new copy of fusionpbx from instructions. (optionally edit 'resources/config.sh' for matching database password from old setup before running 'install.sh')
Copy backup tar and sql files to new server

Next steps are typically done in a script.
Remove freshly installed files from /var/www/fusionpbx
Extract the tarball so all old files are in place
Drop the fusionpbx database
Use backup sql file to restore database structure and data.
Restart Freeswitch.

There may be other customizations such as certificates and IP address items to correct, but that is generally the restore process.
 

Patrick_S

Member
Oct 21, 2021
33
0
6
35
I finally got the backup/restore to run with no errors but when I try and go to the url it gives me the error below.

1644690582896.png
 

Adrian Fretwell

Well-Known Member
Aug 13, 2017
1,498
413
83
The function tells you if magic quotes is switched on in the php configuration. Having magic quotes was always a bad policy and I believe it has now been removed for security reasons.

You are probably safe to just delete the whole IF statement in php.php.
 

Patrick_S

Member
Oct 21, 2021
33
0
6
35
@ Adrian Fretwell Thank you I commented out those lines and I no longer get the error also part of the problem was that the sql database would not accept the DB password from the server we were migrating from so I had to manually drop the new server db and change the password for the fusionpbx user to the db password of the server we were migrating from and now I am able to get to the url with no errors but non of my credentials work so I am going to do a password recovery for the superadmin and see if that works.
 
Status
Not open for further replies.