r1877-readme.txt 3.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687
  1. Migration Instructions
  2. FusionPBX 2.0 to 3.0.x
  3. Need assistance: http://www.fusionpbx.com/support.php
  4. 1. Check revision number.
  5. svn info
  6. 2. If you are below version 1877 then update to the version 1877.
  7. svn update -r1877
  8. 3. Make sure the current system is updated with the latest database structure.
  9. cd /var/www/fusionpbx
  10. php /var/www/fusionpbx/core/upgrade/upgrade.php
  11. 4. Ensure that you can login and see the menu before upgrading further.
  12. 5. If using MySQL or Postgres Create a new database one way to do that is using advanced -> adminer.
  13. Any database name you want to use will work for these instructions we will use a database name of fusionpbx3.
  14. 6. Download the export PHP Script
  15. cd /var/www/fusionpbx
  16. wget http://fusionpbx.googlecode.com/svn/trunk/scripts/upgrade/r1877-export.php
  17. 7. Make a backup of the FusionPBX PHP directory and the FreeSWITCH conf directory.
  18. cp -R /var/www/fusionpbx var/www/fusionpbx-bak
  19. cp -R /usr/local/freeswitch/conf /usr/local/freeswitch/conf-bak
  20. 8. Change the top of the script where and set the database you want to export the data to.
  21. $db_type = "sqlite"; //pgsql, sqlite, mysql
  22. 9. Upload it to the root of your server
  23. 10. Login to the using the web interface.
  24. 11. Run the 1877-export.php script if it was placed in the web directory you would run it with the following url.
  25. http://x.x.x.x/r1877-export.php
  26. 12. Save the sql file.
  27. 13. Move the sql file to the server then import the sql code into the database.
  28. a. For postgres you can import the sql file into the database by using the following command.
  29. su postgres
  30. psql -U postgres -d fusionpbx3 -f /tmp/database_backup.sql -L sql.log
  31. b. For sqlite you need to use sqlite by command line.
  32. 1. Assuming fusionpbx is installed to /var/www/fusionpbx and the database is called fusionpbx.db
  33. 2. Move the old database to a new name
  34. mv /var/www/fusionpbx/secure/fusionpbx.db /var/www/fusionpbx/secure/fusionpbx-version2.db
  35. 3. Import the sql file into the sqlite database
  36. Debian / Ubuntu Server
  37. apt-get install sqlite3
  38. sqlite3 /var/www/fusionpbx/secure/fusionpbx.db < /tmp/database_backup.sql
  39. 4. Make sure the database is writeable
  40. 14. Edit fusionpbx/resources/config.php change the database name to the new database.
  41. 15. Update the source code to 3.0.x
  42. svn update
  43. 16. Run logout.php from the browser to clear the session then login to the GUI with the web browser.
  44. 17. Update the menu by going to:
  45. http://x.x.x.x/core/menu/menu.php then edit the menu and press 'restore default'
  46. 18. Update the permissions.
  47. Go to advanced -> group manager edit the permissions for the superadmin group
  48. Select the permissions that you want to enable and then press save.
  49. 19. Logout of the web interface to clear the session.
  50. 20. For multi-tenant systems delete the domain based dialplan xml files in.
  51. rm /usr/local/freeswitch/conf/dialplans/replace_with_the_domain_name.xml
  52. 21. For Single tenant systems go to Advanced -> Default Settings
  53. Remove /default off the end of all of the paths. Should see it in 2 places.
  54. 22. Upgrade FusionPBX
  55. cd /var/www/fusionpbx
  56. /usr/bin/php /var/www/fusionpbx/core/upgrade/upgrade.php
  57. 23. Go to Advanced -> XML Editor
  58. Expand 'autoload_configs'
  59. Click on xml_cdr.conf.xml
  60. At <param name="url" remove /mod/ and replace it with /app/
  61. Status -> SIP Status press 'reloadxml'
  62. System -> Modules restart XML CDR.
  63. 24. Upgrade is complete.