- This line was added.
- This line was removed.
- Formatting was changed.
Read this document completely before starting the migration process, to ensure the necessary access is available to complete all steps. For these steps, the new appliance is the system the Ubersmith Appliance is being migrated to, and the old appliance is the system the Ubersmith Appliance is being migrated from. It is assumed that the Ubersmith host is upgraded first, and that the Ubersmith Appliance will be installed to the following default directory:
If you would prefer to have Ubersmith perform your migration, please contact Ubersmith Support to discuss the scope of the project and to arrange for a quote from our Managed Services team.
Preparing for the Migration
Perform these steps before migration day.
- Ensure that the old appliance can reach the new appliance via SSH.
- Ensure that the Ubersmith host can reach the new appliance. The new appliance will accept connections on
- Configure an SSH key between the two appliances to ease file copying and database dumps. See this online resource to perform this configuration task.
Deploying the New Ubersmith Appliance
- Ensure that the new appliance system is compatible with Ubersmith and install the Ubersmith Installation and Upgrade Utility prerequisites.
- Deploy the Ubersmith Appliance on the new appliance using the Ubersmith Installation and Upgrade Utility.
- Once the installation is complete, disable the
app_croncontainer on the new appliance environment. This ensures that the new system does not start polling your devices before you are ready to use it.
docker-compose rm -sf app_cron
Scheduling Downtime/Dry Run
To get a time estimate of how long the Ubersmith Appliance will be offline, perform a dry run by performing the migration day steps, but not the post migration steps.
Note the timing for the following events:
- RRD transfer
Ubersmith Appliance upgrade
Based on the details of the dry run, schedule downtime with your users. For extended downtime, consider performing the migration after hours or on a weekend. Appliances with large data sets will experience significant downtime during the RRD transfer phase.
These steps perform the migration and may cause the Ubersmith Appliance to be unavailable.
Exporting the Database
By default, the Ubersmith Appliance database is named
uberappand is stored in the
Complete a logical export using
mysqldump, which is likely already installed on the system. See the
mysqldumpdocumentation for MySQL 5.67. In most circumstances, the Ubersmith Appliance database is small, and will be at most a few hundred megabytes.
Example usage of
First, open a shell within the Ubersmith Appliance Database container. Next, use
mysqldumpto create a backup of the database:
docker-compose exec app_db bash
mysqldump -u root -
p$MYSQL_ROOT_PASSWORD uberapp > /ubersmith_appliance_export.sql
In this command the
rootuser logs into MySQL, the password is prompted for and entered on the command lineentered using an environment variable, the
uberappdatabase is exported, and saved to a file in the root of the filesystem named
Once the database export is complete, use the
exitcommand to leave the
docker cpcommand to copy the database dump out of the container's filesystem.
docker cp ubersmith_app_db_1:/ubersmith_appliance_export.sql .
tailcommand to examine the end of the file to ensure it completed successfully.
tail -n1 ubersmith
A successful completion will show the output
-- Dump completed onwith a date and timestamp.
Copying the Database
Copy the appliance database export file from the old appliance to the new appliance, using
Copy the appliance database export file into the new appliance’s
app_dbcontainer, using the
docker cp ubersmith_appliance_export.sql ubersmith_app_db_1:/
Enter a shell in the new appliance database container (
app_db) to begin the restore:
docker-compose exec app_db bash
Within the new appliance's shell in the database container, restore the database:
mysql -u root -p$MYSQL_ROOT_PASSWORD uberapp < /ubersmith_appliance_export.sql
Upgrading the Ubersmith Appliance
On the new appliance, run the
appliance_upgrade.shscript which is part of the Ubersmith Installation and Upgrade Utility.
- To run the upgrade manually in the event the script is not present, run:
docker-compose exec app_web php /var/www/appliance_root/www/upgrade.php
Disabling Poll Tasks
- If simultaneous polling between two appliances is not desirable, stop the polling tasks on the old appliance. Run the following command to stop and remove the Appliance Cron container.
docker-compose rm -sf app_cron
- Disabling these tasks ensures that the old appliance does not poll your infrastructure during the migration process. If this step is not performed now, be sure to perform it once the migration is complete.
Migrating RRD Files
- Copy (
sftp)the existing RRD files from the old appliance to the new appliance. The existing RRD files can be found on the old appliance in the directory:
- On the new appliance, the RRD files are stored in a Docker volume named
ubersmith_rrds. The simplest way to migrate the RRDs is to copy them directly into Docker's storage location for the volume:
These steps finalize the migration and configure Ubersmith to use the new appliance.
Enabling Scheduled Tasks
On the new appliance, recreate the cron container, so that the Ubersmith Appliance can perform scheduled polling tasks.
docker-compose up -d app_cron
- Permissions must be set on the RRD files within the Ubersmith Appliance cron container, so that the cron tasks can write to them. Execute the following command in
docker-compose exec app_cron chown -R ubersmith:ubersmith /var/www/appliance_root/rrds
Updating Ubersmith's Appliance Configuration
When you are satisfied that the Ubersmith Appliance is functioning properly, renumber the new appliance with the IP address from the old appliance, or update Ubersmith's Appliance configuration (Settings → Appliances) to use the new address.
Do not delete the existing Appliance entry in Settings → Appliances, as this will remove the appliance configuration from your existing Device Module configurations.
- Be sure to disable polling on the old appliance if it was not performed earlier in the migration process.
On this page: