Storage Volume Problems

This section lists problems you might encounter while creating and using storage volumes.

Can’t attach a storage volume to an instance

Description

When I try to attach my storage volume to an instance, the following error occurs:

APIConflictError: Attachment index 1 is already in use on instance /Compute-acmecorp/acmeadmin/dev2/6073c806-f7da-47eb-9678-6e618931b29a

Solution

The index number that you’re trying to assign to this storage volume is already used for another storage volume. Select a different index number and try again.

Note:

The disk number that you specify here determines the device name. The disk attached at index 1 is named /dev/xvdb, the disk at index 2 is /dev/xvdc, the disk at index 3 is /dev/xvdd, and so on.

To view the set of index numbers that are already in use for an instance using CLI, use the opc compute storage-attachment list command.

For help with that command, run the command with the -h option. For the instructions to install the CLI client, see Preparing to Use the Compute Classic CLI in CLI Reference for Oracle Cloud Infrastructure Compute Classic.

Can’t access a storage volume on my instance

Description

I successfully created a storage volume by using the web console, but I can't see that disk when I log in to my instance.

Solution

After creating a storage volume, you must attach it to your instance. Then you must format the volume and mount it on your instance. See Attaching a Storage Volume to an Instance and Mounting and Unmounting a Storage Volume.

I can no longer access my storage volume from my instance

Description

I had mounted a storage volume on my instance some time ago, but I don’t see it in the list of devices mounted on the instance today.

Solution

In certain circumstances, storage volumes that were attached to and mounted on your instance might need to be attached and mounted again. This happens if your instance stopped and was re-created automatically, or if you deleted your instance and re-created it. Consider the following:

  • Is your instance set up to boot from a nonpersistent disk?

    If yes, then when the instance is re-created, all the attached storage volumes must be mounted again.

  • Did you attach the storage volume to the instance after creating the instance?

    If yes, then when the instance is re-created, you must attach the storage volume again.

Note that, though you might need to attach and mount a storage volume again after an instance is re-created, the data stored on the storage volume isn’t lost.

Can't detach a storage volume from an instance

Description

I've attached three storage volumes to my instance. Now I want to delete the instance. So I started to detach the storage volumes. I detached two of the storage volumes, but can’t detach the third one.

Solution

You can detach storage volumes that were attached to an instance after the instance was created. You can’t detach storage volumes that were attached during instance creation.

Can't delete a storage volume

Description

I want to delete a storage volume that I no longer need, but the web console doesn’t show the delete option for the storage volume.

Solution

You can't delete a storage volume if it’s attached to an instance. To find out whether a storage volume is attached to an instance, view the storage volume information in the web console. Click the Storage tab, scroll down to the storage volume that you want to delete, and check the displayed details. If the storage volume that you want to delete is attached to an instance, then you must detach it first. See Detaching a Storage Volume from an Instance.

You can also use CLI commands to find out if a storage volumes is attached to an instance. Use the opc compute storage-attachment list CLI command with the --storage_volume_name option to view the details of storage attachments for a specified storage volume. Then use the opc compute storage-attachment delete CLI command to detach a storage volume from an instance.

For help with these commands, run each command with the -h option. For the instructions to install the CLI client, see Preparing to Use the Compute Classic CLI in CLI Reference for Oracle Cloud Infrastructure Compute Classic.

Also, you can’t delete a storage volume if you’ve created any colocated snapshots of the storage volume. See Backing Up and Restoring Storage Volumes Using Snapshots.

Can't delete a storage volume snapshot

Description

I want to delete a storage snapshot that I no longer need, but the Delete option for that snapshot is disabled in the web console.

Solution

You can't delete a colocated storage volume snapshot if you’ve created a clone from that snapshot. The Storage Snapshots page shows you information about each colocated storage snapshot including storage volumes cloned from a snapshot, if any. You can make a note of the clones and then view them on the Storage Volumes page. To delete a colocated snapshot, first delete all the clones created from the storage snapshot. See Deleting a Storage Volume.