Recover access to a volume-based instance when SSH keys are lost


DreamCompute instances are created with a specified SSH key which is used for gaining initial access. This guide covers some basic steps to attempt to retrieve the data and gain access again if desired.


Things to keep in mind

  • IP addresses will change

    Logging back into an instance requires re-creating it. The new instance receives new IPv4 and IPv6 addresses.

  • Know your instance type

    One can generally find out if an instance used an ephemeral or volume boot disk by looking at the 'Instances' page in the DreamCompute dashboard. There you can see if the name of a custom image or an operating system is listed in the Image Name column. If one is listed, the instance is ephemeral. If one isn’t, it used a volume boot disk.

  • Backup volume booted instance

    When an instance is created, there is an option titled "Delete Volume on Instance Delete". Unfortunately it is difficult to check what that option was set to after creation. If "Yes" was selected, then the volume data will be permanently deleted when the instance is deleted.

    To make a backup, navigate to the 'Compute > Instances' page. To the right of the instance click the Create Snapshot button. This snapshot uses volume storage quota, so additional storage may need to be added in the DreamHost panel for more room. Once this entire process is complete, the snapshot can be deleted and the quota lowered.

Regain access to volume-based instance

  1. Navigate to the Instances page of the DreamCompute dashboard.
  2. If you do not know whether or not "Delete Volume on Instance Delete" was set to "Yes" for your instance when it was created, make sure a snapshot has been created. A snapshot uses as much disk space as the volume, so if the volume is 80GB, confirm there is another 80GB free. You can ensure that there is sufficient volume storage on the Overview page.
  3. Make note of the size of the instance, the name of the instance, the UUID and name of the volume, and any other features that should be retained in the new instance.
  4. Delete the instance (this will leave an available volume).
  5. Click the Launch Instance button to create a new instance. On the Source tab, set Select Boot Source to Volume and click the up arrow symbol next to the newly available volume from the previous instance.
  6. On the Key Pair tab, select the Key Pair to be injected for the default user. If there are no valid keys available, you can use the Create Key Pair or Import Key Pair buttons to associate a new key pair with your project (and this instance).
  7. When you're finished customizing the instance, click the Launch button on the bottom right.
  8. Once the new instance has booted, attempt to log into it with the default username and the new IP address.
  9. If everything looks correct and access has been restored, you should delete the volume snapshot made in step #2 to recover volume storage quota.

Did this article answer your questions?

Article last updated PST.

Still not finding what you're looking for?