Block Storage for VPC volume data are common way to add storage to VPC virtual server instances. In this blog post, we will discuss how you can utilize the additional features where you can add VPC snapshot as data volume and its use-cases.
- This is useful in use case where you have a snapshot and want to attach it as data volume to be able to access in new VPC VSI or existing server.
- Another use case that it can be utilize in situations where the server became inaccessible and there are no possible way to access the data residing on boot volume. The snapshot of the boot volume can be taken in such cases and then data can be accessed by deploying another VSI and then attached the taken snapshot as data volume.
Add VPC snapshot as data volume:
Let's utilize the snapshot and add as data volume. Navigate to https://cloud.ibm.com/vpc-ext/storage/snapshots In this case, we assume that the snapshot is already taken.
If not, you can take a snapshot of by using action >> Create Snapshot. You can follow the guide here described to know more.
https://cloud.ibm.com/docs/vpc?topic=vpc-snapshots-vpc-create
There are two ways you can utilize this snapshot:
1. Attach to new VSI while deploying
- While deploying you will find option to attach the data volume
- Click on Create
- Click/toggle import from snapshot
- You will be able to find the taken snapshot in the list. Choose appropriate
- Provide a name and also you can choose to Automatically delete the volume when the attached virtual server instance is deleted. You can change this setting later on the virtual server details page as well.
- You will be able to see the data volume attached.
- Now you can mount it and access the data depending upon the OS.
2. Attach to existing VSI
The method to attach on the existing is similar. On the VSI page click attach on Storage volumes
- Select >> Create a data volume
- Toggle import from snapshot
- Fill required details such as name etc and click save
Depending upon the OS, mount it in the OS to be able to access the volume and its data.
That's all, now you can access the data volume :
You may refer below docs to learn more: