You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
A VSI created using terraform, we would like to restore a VSI retaining the primary IP address, VSI tags, VSI name, VSI Hostname.
Restore from a snapshot consistency group snapshot (includes boot and data)
Get the VSI to a previous state by retaining IP address / Network interface, VSI tags, VSI name, VSI Hostname
Needs to be available for customers to consume via a deployable architecture and/or IBM Cloud Schematics
We had a similar scenario where a number of VSIs have been deployed via landing zone and we needed to be able to restore a VSI's storage volumes from snapsnots on demand.
After some discussions on the topic, I believe this operation should be done outside of the context of the terraform that provisions the VSIs to begin with.
Landing zone usually provisions multiple VSIs using the same configuration element - e.g. across several zones or multiple instances into a zone. When one of them needs to get restored, it's not feasible to "carve" it out of the configuration and specify the source snapshots for its volumes in the original configuration that used to deploy it.
Even if there is only one instance in the landing zone configuration, changing the original configuration now ties the environment deployment to a snapshot which will be used from now on for that instance, so the snapshot has to be retained forever.
If the restored volumes and the new VSI (you cannot attach a new boot volume to an existing VSI) are created in a different terraform state, now you have the original state that is no longer in sync and a new "parallel" one for the restored instance.
The only option to keep the original terraform configuration and state consistent and not tied to the specific snapshot is to import the new resoruces (VSI, volumes, etc) into the original terraform state after the restore has been done with creating a new VSI. But I think that may be too risky.
Description
A VSI created using terraform, we would like to restore a VSI retaining the primary IP address, VSI tags, VSI name, VSI Hostname.
Restore from a snapshot consistency group snapshot (includes boot and data)
Get the VSI to a previous state by retaining IP address / Network interface, VSI tags, VSI name, VSI Hostname
Needs to be available for customers to consume via a deployable architecture and/or IBM Cloud Schematics
New or affected modules
terraform-ibm-landing-zone-vsi/main.tf
Line 92 in ca728d0
By submitting this issue, you agree to follow our Code of Conduct
The text was updated successfully, but these errors were encountered: