In today’s post will see below things.
How to move resources like custom images, block volumes of one region to other.
Regions subscribed are FRANKFURT and ASHBURN.
I already created an instance INST01_FRANKFURT with attached block volume BV01_FRANKFURT in compartment comp01_FRANKFURT in FRANKFURT region.
Now want to take image of instance INST01_FRANKFURT and create the instance in ASHBURN region, copy the backup of block volume BV01_FRANKFURT to ASHBURN region and create the block volume from backup and attach to the instance in ASHUBRN region.
Custom images export and import to other regions:
Copying Backup Block volumes across the regions:
In FRANKFURT region:
- Create a compartment called comp01_FRANKFURT.
- Create a VCN comp01_FRANKFURT_vcn01 with CIDR 10.0.0.0/16.
- Create SUBNET A (10.0.1.0/24), SUNBET B (10.0.2.0/24), SUBNET C (10.0.3.0/24)
- Create Internet Gateway comp01_FRANKFURT_IGW01.
- Create instance INST01_FRANKFURT using the VCN comp01_FRANKFURT_vcn01.
- Create a block volume BV01_FRANKFURT and attach to instance INST01_FRANKFURT
- Create the custom image of INST01_FRANKFURT.
- Create a bucket in object storage.
- Export the image of instance to bucket in object storage.
- Create pre-authentication URL for the object exported in object storage.
- Create a backup of the block volume.
- Copy the backup of the block volume to ASHBURN region using the same compartment.
In ASHBURN region:
- Create a compartment called comp02_ASHBURN.
- Create a VCN comp02_ASHBURN_VCN01 with CIDR 220.127.116.11/16.
- Create SUBNET A (18.104.22.168/24), SUBNET B (22.214.171.124/24), SUBNET C (126.96.36.199/24)
- Import the custom image of FRANKFURT region using pre-authentication URL created.
- Create the instance INST02_ASHBURN using the imported custom image.
- Create a block volume from the backup in the compartment comp02_ASHBURN.
- Attach the same block volume to the instance.
- Rename the logical volumes and volume group names and mount the same in the instance.
Created instance INST01_FRANKFURT with block volume BV01_FRANKFURT attached in FRANKFURT region.
Stop the instance and take the custom image backup.
Create the bucket in object storage and export the image backup to bucket.
Exporting Image to bucket.
Creating Pre-authenticated URL for the image object in the bucket.
Copy the URL and keep it in the notepad, we have to use this URL when importing image from other region.
Now going to ASHBURN region custom images and import the image through the pre-authenticated URL.
Importing the image.
After successful image import, create the instance using the imported image.
Provisioning the instance:
Instance created successfully using the imported image in ASHBURN region.
Connect to the instance created.
Take the backup of block volume in FRANKFURT region and copy the backup to ASHBURN region.
Once the backup of block volume copied, create the block volume from backup in the comp02_ashburn compartment and attach to the instance.
After successful attachment of block volume to the instance, execute the iscsi commands and mount the same.
When the instantiation of iscsi done, automatically it will mount with previous mount point. So, change the names of LV’s, VG’s and mount to new directory.
Hope this post find’s you well !!
Happy learning !!
Firoz Hussain K.