Restoring the target system on VMware
Restore the saved configuration and backups from the source system onto the target system.
Restoring the management subsystem
- Copy the toolkit CLI
apic executable to your FFM directory. See Installing the
toolkit. Ensure that your toolkit CLI version matches
the API Connect version of your target management VM.
You created the FFM directory in Preparing the source system. The FFM directory contains Python scripts, YAML files, and a data directory that contains your exported source system data.
- Login to your target management VM with SSH, and switch to the root
user:
ssh apicadm@<management hostname>
sudo -i
If you deployed a three replica management profile, then login to just one of the VMs.
- Copy the FFM directory to your target management VM.
- Ensure that the FFM directory is set first in your
PATH
variable:export PATH=<FFM directory>:$PATH
Note: The API Connect VMs have an executable that is called apic in thePATH
variable. The toolkit CLI apic must come before it in thePATH
so that the restore scripts run correctly. - Run the management database restore script:
python3 restore_management_db.py -n default
Tip: To get help information with the restore scripts, run them with the flag--help
.python3 <script name> --help
The script output shows the progress and when the restore is complete.
- Edit the gateway_portal_mapping.yaml file and set the endpoints on right side of the file to the endpoints defined for your target VM. The endpoint values can be obtained from the apiconnect-up-v10.yml file in your project directory.
- Run the register gateway and portals script:
python3 register_gateway_portals_in_target.py -s <platform API endpoint> -u admin -p <password> -r admin/default-idp-1 -n default -silent
where- <platform API endpoint> is defined in the apiconnect-up-v10.yml file in your project directory.
- <password> is the admin password that is used on your source system.
- Run the update portals
script:
python3 update_to_new_portals.py -s <platform API endpoint> -u admin -p <password> -r admin/default-idp-1 -n default -api_manager_hostname <platform API endpoint> -silent
- Run the update gateways
script:
python3 update_to_new_gateways.py -s <platform API endpoint> -u admin -p <password> -r admin/default-idp-1 -n default -api_manager_hostname <platform API endpoint> -silent
Restoring the portal subsystem
- Login to your target portal VM with SSH, and switch to the root
user:
ssh apicadm@<portal hostname>
sudo -i
If you deployed a three replica portal profile, then login to just one of the VMs.
- Copy the FFM directory from the management VM to your portal VM.
- Ensure that the FFM directory is set first in your
PATH
variable:export PATH=<FFM directory>:$PATH
Note: The API Connect VMs have an executable that is called apic in thePATH
variable. The toolkit CLI apic must come before it in thePATH
so that the restore scripts run correctly. - Run the restore portal sites
script:
python3 restore_portal_db.py -n default