Automate to Automate HA
Warning
Standalone Chef Automate or Chef Automate with embedded Chef Infra Server can migrate to Automate HA, with
minimum version of Chef Automate: 20201230192246Chef Automate user running Chef Infra Server in external mode should not migrate to Automate HA.
Upgrade with FileSystem Backup Locally
- Create Backup of Chef Automate Standalone using the following command:
chef-automate backup create
chef-automate bootstrap bundle create bootstrap.abb
- The first command will create the backup to the
/var/opt/chef-automate/backup
location unless you specify the location inconfig.toml
file. - The second command will create the
bootstrap.abb
. - Once the backup is completed, save the backup Id. For example:
20210622065515
.
- Create Bundle using the following command:
tar -cvf backup.tar.gz path/to/backup/<backup_id>/ /path/to/backup/automatebackup-elasticsearch/ /path/to/backup/.tmp/
Transfer the
tar
bundle to one of the Chef Automate HA Frontend Nodes.Transfer the
bootstrap.abb
file to all the Chef Automate HA FrontEnd Nodes (both Chef Automate and Chef Infra Server).Go the Chef Automate HA, where we copied the
tar
file. Unzip the bundle using:
tar -xf backup.tar.gz -C /mnt/automate_backups
- Stop all the services at frontend nodes in Automate HA Cluster. Run the following command to all the Automate and Chef Infra Server nodes:
sudo chef-automate stop
- Run the following command at Chef-Automate node of Automate HA cluster to get the applied
config
:
sudo chef-automate config show > current_config.toml
Note
In Automate 4.x.y version onwards, OpenSearch credentials are not stored in the config. Add the OpenSearch password to the generated config above. For example:
[global.v1.external.opensearch.auth.basic_auth]
username = "admin"
password = "admin"
- Restore in Chef-Automate HA using the following command:
automate_version_number=4.x.y ## Please change this to the version of Chef Automate HA installed. Look for /var/tmp/frontend-4.x.y.aib file
chef-automate backup restore /mnt/automate_backups/backups/<backup_id>/ --patch-config current_config.toml --airgap-bundle /var/tmp/frontend-${automate_version_number}.aib --skip-preflight
- Unpack the
bootstrap.abb
file on all the Frontend nodes:
Login to Each Frontend Node and then run after copying the bootstrap.abb
file.
chef-automate bootstrap bundle unpack bootstrap.abb
- Start the Service in All the Frontend Nodes with the command shown below:
sudo chef-automate start
Upgrade with FileSystem Backup via Volume Mount
- Create Backup of Chef Automate Standalone using the following command:
chef-automate backup create
chef-automate bootstrap bundle create bootstrap.abb
- The first command will create the backup at the file mount location mentioned in the
config.toml
file. - The second command will create the
bootstrap.abb
. - Once the backup is completed, save the backup Id. For example:
20210622065515
Detach the File system from Standalone Chef-Automate.
Attach and Mount the same file system to the Automate-HA all the nodes:
- Make sure that it should have permission for hab user
- Stop all the services at frontend nodes in Automate HA Cluster. Run the below command to all the Automate and Chef Infra Server nodes
sudo chef-automate stop
Get the Automate HA version number from the location
/var/tmp/
in Automate instance. For example :frontend-4.x.y.aib
Run the command at Chef-Automate node of Automate HA cluster to get the applied config:
sudo chef-automate config show > current_config.toml
Note: From Automate 4.x.y
version onwards, OpenSearch credentials are not stored in the config. Add the OpenSearch password to the generated config above. For example:
[global.v1.external.opensearch.auth.basic_auth]
username = "admin"
password = "admin"
- Run the restore command in one of the Chef Automate node in Chef-Automate HA cluster:
automate_version_number=4.x.y ## Please change this to the version of Chef Automate HA installed. Look for /var/tmp/frontend-4.x.y.aib file
chef-automate backup restore /mnt/automate_backups/backups/<backup_id>/ --patch-config current_config.toml --airgap-bundle /var/tmp/frontend-${automate_version_number}.aib --skip-preflight
Copy the
bootstrap.abb
file to all the Chef Automate HA FrontEnd Nodes (both Chef Automate and Chef Infra Server).Upack the
bootstrap.abb
file on all the Frontend nodes.ssh
to Each Frontend Node and run the following command:
chef-automate bootstrap bundle unpack bootstrap.abb
- Start the Service in All the Frontend Nodes with command shown below:
sudo chef-automate start
Was this page helpful?