Migrating the Files Advanced Web Server and Gateway databases
On the original server, where Tomcat/Gateway/PostgreSQL are running now:
Note: If your Files Advanced Web Server database is very large, several gigabytes, you may want to use a different backup and restore method for your database. Please contact our technical support at https://support.acronis.com/mobility for help and instructions.
Stop the Files Advanced Tomcat service
Open the Files Advanced PostgreSQL Administrator tool. You can find it in Windows Start menu, under the Files Advanced folder. Connect to the database server. You may be prompted to enter the password for your postgres user.
Expand Databases and right-click on the acronisaccess_production database.
Choose Maintenance and select the Vacuum radio button and the ANALYZE checkbox. Press OK.
Expand the database, expand Schemas and expand Public. Take note of the number of the Tables section. This can help you verify that the database restore is successful after a recovery.
Close the PostgreSQL Administrator tool and open an elevated command prompt.
In the command prompt, navigate to the PostgreSQL bin directory.
Note: You will need to edit the path to point to your PostgreSQL bin folder if you use an older or a custom installation (e.g. C:\Program Files (x86)\Acronis\Access\Common\PostgreSQL\9.4\bin\).
Enter the following command: pg_dumpall --host localhost --port 5432 --username postgres --file alldbs.sql
alldbs.sql will be the filename of the backup. It will be saved in the PostgreSQL bin directory. You can use a path in the above command if you wish to save it somewhere else - e.g. change the last part of the command above like so: --file D:\Backups\alldbs.sql
If you are using a non-default port, change 5432 to the correct port number.
If you are not using the default PSQL administrative account postgres, please change postgres to the name of your administrative account in the command above.
You will be prompted to enter the postgres user'spassword several times for this process. For each prompt, enter the password and hit Enter.
Note: Typing the password will not result in any visual changes in the Command Prompt window.
Copy the backup file to the new machine that will host the Files Advanced Web Server.
Copy the certificates you use for the Files Advanced Web Server to the new machine.
If you plan to migrate the File Store, copy over those files. For a large File Store this could take some time. For more information, read Moving the FileStore to a different location.
Backup the Gateway Server's database
Stop the Files Advanced Gateway service.
Go to the Gateway Server database folder, by default located at:
Copy the mobilEcho.sqlite3 file to the new machine that will host the Gateway Server.
If you have made changes to any of these files, it is recommended to make backups so you can transfer your settings when restoring or migrating your Files Advanced product.
The postgresql.conf file as it may contain important settings relevant to your database. It is typically located in C:\Program Files (x86)\Acronis\Files Advanced\Common\PostgreSQL\<version>\Data.
web.xml located by default at C:\Program Files (x86)\Acronis\Files Advanced\Access Server\Web Application\WEB-INF\. Contains Single Sign-On settings.
server.xml located by default at C:\Program Files (x86)\Acronis\Files Advanced\Common\apache-tomcat-<version>\conf. Contains Tomcat settings.
krb5.conf located by default at C:\Program Files (x86)\Acronis\Files Advanced\Common\apache-tomcat-<version>\conf. Contains Single Sign-On settings.
login.conf located by default at C:\Program Files (x86)\Acronis\Files Advanced\Common\apache-tomcat-<version>\conf.
Your certificates and keys used for Files Advanced.
acronisaccess.cfg located by default at C:\Program Files (x86)\Acronis\Files Advanced\Access Server.
Custom color schemes located by default at C:\Program Files (x86)\Acronis\Files Advanced\Access Server\Web Application\customizations\.
pg_hba.conf located by default at C:\Program Files (x86)\Acronis\Files Advanced\Common\PostgreSQL\<version>\Data.
newrelic.yml file if you are using New Relic to monitor your Files Advanced server.
On the new server that will be hosting the Files Advanced Server, perform the following steps:
Install Files Advanced
Start the Files Advanced installer and press Next. Read and accept the license agreement.
Choose Install and follow the installer screens.
Note: If the Files Advanced Web Server, PostgreSQL, Gateway are going on separate machines, choose Custom and select the desired component(s).
On the PostgreSQL Configuration screen enter the same password for the PostgreSQL superuser that was used on the original server. Press Next.
Review the components being installed and press Install.
Once the installer is done, press Exit and dialog will come up telling you the Configuration Utility will run next.
When the Configuration Utility comes up, leave it open without pressing OK or Apply.
Open the Services control panel and stop the Files Advanced Tomcat service.
Note: For load-balanced configurations, stop all Files Advanced Tomcat services.
Open the Files Advanced PostgreSQL Administrator application, connect to the local database server, select Databases, and confirm there is a database called acronisaccess_production.
Right-click on the database and select Refresh.
Expand it and expand Schemas, expand Public and verify that there are zero (0) Tables.
If there are any tables in the database, right click on the database and rename it to oldacronisaccess_production. Finally, go to Databases, right-click and create a new database called acronisaccess_production.
Close the PostgreSQL Administrator and open an elevated command prompt.
In the command prompt, navigate to the PostgreSQL bin directory.
Copy the database backup file alldbs.sql (or whatever you have named it) into the bin directory.
In the command prompt, enter the following command: psql -U postgres -f alldbs.sql
Enter your postgres password when prompted for it.
Note: Depending on the size of your database, the restore can take some time.
After the restore is complete, close the command prompt window.
Open the Files Advanced PostgreSQL Administrator again and connect to the local database server.
Select Databases.
Expand the acronisaccess_production database, expand Schemas and expand Public. Verify that the number of Tables is the same as it was on the original server.
Note: If the Files Advanced Web Server version you restore the database to is newer than the Files Advanced Web Server version from your database backup, and the Files Advanced Tomcat service has already been started, the number of tables in the new Files Advanced Web Server database could be larger than the number of tables you had when you did the backup.
Restore the Gateway Server database
Copy the mobliEcho.sqlite3 Gateway Server database that came from the old server into the new Gateway Server's database folder (by default C:\Program Files (x86)\Acronis\Files Advanced\Gateway Server\database) replacing the existing file.
Configure your new server
Note: It is highly recommended that you do not change the DNS names used by Files Advanced, only the IP addresses they are pointing to.The following instructions assume you are re-using the DNS names of the previous instance of Files Advanced.
Go back to the Files Advanced Configuration Utility that you left open and set the settings for the Gateway Server, Files Advanced Web Server and File Repository.
Click Apply, and then OK. At the next dialog click OK and a browser will launch with the Files Advanced web interface.
Log into the Access server.
Click on Administration. Navigate to the Mobile Access -> Gateway Servers page.
In the list of Gateway Servers you should see your Gateway server listed.
If the address for your gateway server is a DNS entry you should not need to make any changes to the server as long as the DNS entry is now pointing to your new server machine. If the address for your gateway is an IP address, then you will need to edit the gateway server.
Verify Files Advanced administrative settings
Once you have successfully finished your database's restoration, we highly recommend that you login to the web interface and verify that your settings have carried over and that they are still relevant before proceeding with anything else. Here are some examples of important items to check:
Audit Logging - Make sure that the new Files Advanced logs folder has all the necessary permissions so that logs can be written.
New Relic - If you are using New Relic, copy the newrelic.yml file from the old machine to this one and make sure that the path in the Files Advanced web interface points to the file.
Administration settings - Make sure all your LDAP, SMTP and general administrative settings are correct.
Gateway Servers and Data Sources - Make sure all your Gateway Servers are still reachable on the correct addresses and check if all your Data Sources have valid paths.