How to Migrate Amanda Enterprise From One Server to Another
This article outlines the process for migrating Zmanda from one server to another. It is applicable for versions 3.3, 3.5 and 3.6.
Pre-Migration Checks:
Before you begin the migration process, it is important to perform these checks to ensure a smooth transfer.
Ensure that all the steps involved in the migration are performed as the ‘root’ user.
Install the same version of Amanda Enterprise (AE) on the new server.
Make sure that any patches present on the old AE server are installed on the new AE server.
Temporarily deactivate all backup schedules before initiating the migration process.
Confirm that no ongoing backup or restore operations are in progress during the migration.
The migration involves collecting and transferring configurations and data from your existing setup to the new server. You have the flexibility to migrate either configurations only or both data and configurations.
Migration from Old AE Server:
For a successful migration, the following configuration files and directories need to be migrated to the new server.
/etc/amanda
/etc/zmanda/zmc/zmc_ags/device_profiles
/etc/zmanda/zmc/zmc_aee/zmc_user_dumptypes
/etc/zmanda/zmanda_license
/var/lib/amanda/.am_passphrase
Dump of the ZMC database.
Migrating Backup Data:
If the backups are stored on the Zmanda server and you wish to migrate the backup data, you can include the storage paths in the ‘tar‘ command mentioned below in Step 3. The storage locations can be found on the Admin > Devices page in ZMC.
If the backup data is migrated separately, make sure that the same storage paths are created on the new AE server with the same permissions. The storage directories should be owned by amandabackup user and disk group.
If you are using any attached storage devices like NAS or SAN, you need to reattach the storage device to the new server on the same path where it was mounted on the old AE server. The permissions on the mount points should also remain the same.
Steps for Migration:
Create a new directory to temporarily store the data to be migrated. Make sure this directory has enough free space to store the data collected during the migration. Run the following commands from this directory.
Generate a mysqldump of the ZMC database using the packaged mysql utilities. Make sure the output file has an extension of ‘.sql‘. /opt/zmanda/amanda/mysql/bin/mysqldump -uroot “-p$(awk -F\” ‘/^zmc_mysql_root_password/ {print $(NF-1)}’ /etc/zmanda/zmc/zmc_aee/zmc_aee.cnf)” zmc > dbbackup.sql
Create a tar archive of all the configuration files. tar czpf old_config.tar.gz /etc/amanda /etc/zmanda/zmc/zmc_ags/device_profiles /etc/zmanda/zmc/zmc_aee/zmc_user_dumptypes /etc/zmanda/zmanda_license /var/lib/amanda/.am_passphrase
Copy the files to the new AE server. scp old_config.tar.gz dbbackup.sql root@new-AE:
Configuring the New AE Server:
Go to the directory where the migrated files are stored and extract the config archive. tar xzvf old_config.tar.gz -C /
Contact us for a free 30-minute consultation and learn how our fully managed solution can protect your business and streamline your operations. Get started with Zmanda Pro today!