Barrack API Documentation
  1. Volumes
Barrack API Documentation
  • Platform Documentation
    • Getting Started
    • Authentication & Access
    • Account Management
    • API Keys
    • GPU Models
    • Regions
    • Instance
      • OS Images
      • Bootsource Management
      • Deploy Instance
      • Instance Management
      • Hibernation
      • View Instances
    • SSH Keys
      • Add SSH Keys
      • Manage SSH Keys
    • Volumes
      • Overview
      • Create Volume
      • List and View Volumes
      • Attach Volumes
      • Detach Volumes
      • Clone Volumes
      • Resize Volume
      • Delete Volume
    • Advanced Configurations
      • Network And Security
      • Cloudinit Script
      • Startup Script
    • Firewall
      • Manage Firewall
      • Rules and Attachment
    • Snapshot
      • Overview
      • Manage Snapshots
      • Restore Snapshots
    • Custom Images
      • Overview
      • Create and Manage Images
    • dashboard
      • "Dashboard Overview"
      • "VM Management"
    • AI Chat
      • AI Chat
  • Balance
    • Get credit balance
      GET
  • GPU Stocks
    • Get GPU stock availability
      GET
  • GPU Specs
    • Get GPU specifications
      GET
  • Regions
    • List available regions
  • Pricing
    • Get pricing information
    • Get pricing information
  • Deploy Instance
    • Create a new instance
  • Instance management
    • List instances
    • Get instance details
    • Get instance billing
    • Start instance
    • Stop instance
    • Reboot instance
    • Hibernate instance
    • Restore hibernated instance
    • Toggle public IP for instance
    • Add instance security rule
    • Remove instance security rule
    • Delete instance
  • OS Images
    • List OS images
  • SSH Keys
    • List SSH keys
    • Get SSH key
    • Create SSH key
    • Delete SSH key
  • Volumes
    • List volumes
    • Create volume
    • Get volume details
    • Delete volume
    • Resize volume
    • Clone volume
    • Attach volumes to instance
    • Detach volumes from instance
    • List available volume types
    • Get volume billing
  • Firewalls
    • List firewalls
    • Get firewall details
    • Get supported protocols
    • Get firewalls attached to instance
    • List instances available for firewall attachment
    • Create firewall
    • Delete firewall
    • Add firewall rule
    • Remove firewall rule
    • Attach firewall to instances
  • Scripts
    • List all startup scripts
    • Get startup script details
    • Create a startup script
    • Update a startup script
    • Delete a startup script
    • Delete multiple startup scripts
  • Snapshots
    • List snapshots
    • Get snapshot details
    • List Instance eligible for snapshot creation
    • Get snapshot billing
    • Create snapshot
    • Delete snapshot
    • Restore snapshot
  • Images
    • List custom images
    • Get image details
    • Create image from snapshot
    • Delete custom image
    • Get snapshot-image relationship
    • Get snapshot-image relationship list
  • AI Chat
    • Get available AI models
    • Chat with AI
    • Get AI usage summary
    • Get AI usage history
  • Schemas
    • AITransaction
    • AddFirewallRuleRequest
    • AddFirewallRuleResponse
    • AddVMSecurityRuleResponse
    • AttachFirewallRequest
    • AggregatedBillingResponse
    • AttachFirewallResponse
    • AttachVolumesRequest
    • AttachVolumesResponse
    • AttachedFirewall
    • BatchSnapshotImageRelationshipResponse
    • Balance
    • Billing
    • ChatCompletionsRequest
    • ChatCompletionsResponse
    • CloneVolumeRequest
    • BillingRecord
    • CloneVolumeResponse
    • BillingSummary
    • CreateFirewallRequest
    • CreateFirewallResponse
    • CreateImageFromSnapshotRequest
    • CreateSSHKeyRequest
    • CreateScriptRequest
    • CreateSnapshotRequest
    • CreateSnapshotResponse
    • CreateSSHKeyResponse
    • CurrencyEnum
    • Data
    • CreditBalanceResponse
    • DeleteFirewallResponse
    • CreateVolumeRequest
    • DeleteSnapshotResponse
    • CreateVolumeResponse
    • DeleteVMResponse
    • DetachVolumesRequest
    • DetachVolumesResponse
    • DeploymentRequest
    • DirectionEnum
    • DeploymentResponse
    • EthertypeEnum
    • ErrorResponse
    • FirewallAttachment
    • DeleteVolumeResponse
    • DeleteSSHKeyResponse
    • FirewallEnvironment
    • FirewallResponse
    • FirewallRule
    • FirewallVM
    • GetBatchSnapshotImageRelationshipsRequest
    • GetFirewallDetailsResponse
    • GPUStockConfiguration
    • GPUSpec
    • GetHibernatedVMsResponse
    • GPUStockItem
    • GPUSpecsResponse
    • GetSupportedProtocolsResponse
    • GPUStocksResponse
    • GetVMAttachedFirewallsResponse
    • GetVolumeTypesResponse
    • HibernateVMResponse
    • HibernationBillingMetrics
    • ListFirewallsResponse
    • ListUserVMsResponse
    • ListVMsResponse
    • ModelsResponse
    • GetSSHKeysResponse
    • Pagination
    • PricingRequest
    • OSImage
    • PricingResponse
    • OSImagesResponse
    • Protocol
    • GpuCountEnum
    • ProtocolEnum
    • Image
    • GpuModelEnum
    • GetVolumeDetailsResponse
    • RebootVMResponse
    • ImageCreateResponse
    • RecentHibernation
    • ImageDeleteResponse
    • GetVolumesWithNextNameResponse
    • RemoveFirewallRuleResponse
    • ImageDetailResponse
    • RemoveVMSecurityRuleResponse
    • Region
    • ImageListResponse
    • ResizeVolumeRequest
    • RegionsResponse
    • Price
    • ResizeVolumeResponse
    • ResourceTypeEnum
    • RestoreSnapshotRequest
    • RestoreSnapshotResponse
    • RestoreVMResponse
    • Snapshot
    • SnapshotImageRelationshipResponse
    • Specs
    • StartVMResponse
    • StopVMResponse
    • TierEnum
    • UpdateScriptRequest
    • UsageHistoryResponse
    • UsageSummaryResponse
    • RegionEnum
    • UserVM
    • VMDetailsResponse
    • VMFlavor
    • VMImage
    • VMInstance
    • VMResponse
    • SpecsMetadata
    • VMSecurityRule
    • VMSecurityRuleRequest
    • VMStatus
    • VMVolumeAttachment
    • Script
    • VolumeTypeEnum
    • SSHKeyResponse
    • ScriptListResponse
    • ToggleVMPublicIPResponse
    • VolumeBillingRecord
    • VolumeBillingSummary
    • VolumeHourlyBillingResponse
    • VolumeResponse
  1. Volumes

Attach Volumes

Attach Volumes#

Connect persistent storage volumes to your instances for data storage and retrieval. Volumes provide independent storage that persists across instance shutdowns and restarts.

Attachment Requirements#

Before attaching a volume, ensure these conditions are met:
Volume Status
Must Be "Available"
Not currently attached to another instance
Not in "Creating" status
Shows "Available" badge on volume card
Instance Status
Must Be "SHUTOFF"
Instance is powered off
Not running (ACTIVE)
Not creating, hibernated, or suspended
Shut down instance before attachment
Region Match
Same Region Required
Volume and instance in identical region
No cross-region attachment supported
Verify regions match before proceeding
Volume Types
All Types Supported
SSD volumes (CANADA-1)
NVMe volumes (FINLAND-1/2/3, ICELAND-1)
HDD volumes (FINLAND-1/2/3, ICELAND-1)
OS/bootable volumes have special restrictions
OS/Bootable Volume Special Rules:
Can be attached to only one instance (first attachment is permanent)
Cannot be re-attached to different instances after detachment
Only available in CANADA-1 region
Non-bootable volumes can be moved between instances freely

Attaching a Volume#

1
Navigate & Select Volume
Go to barrack.ai/volumes
Use the region dropdown to filter volumes by your instance's region
Locate the volume you want to attach
Verify Before Proceeding:
Volume status shows "Available"
Volume region matches target instance region
Attach button is enabled (not grayed out)
Click the Attach button on the volume card
2
Select Instance
The instance selection modal opens
What You'll See:
Only SHUTOFF instances appear in the list
Only instances in the same region as the volume
Instance name, ID, and status displayed
Select the target instance by clicking on it
If No Instances Appear:
This means no instances meet the requirements (SHUTOFF status and same region). See Troubleshooting section below for resolution steps.
3
Confirm Attachment
Click the Attach button in the modal to confirm
Processing:
Request is sent to the backend
Volume is attached to the instance
Typically completes in 5-10 seconds
Success notification appears when complete
The modal closes automatically

Post-Attachment Status#

After successful attachment, these changes occur:

Volume Changes#

Status Updates:
Status badge changes from "Available" to "Attached"
Instance name appears on volume card
Instance ID displayed on volume card
Button Changes:
Attach button is hidden
Detach button appears (for non-OS volumes)
Delete button becomes disabled

Instance Information#

The volume card now displays:
Which instance the volume is attached to
Instance status (may show VM state)
Instance region

Billing Impact#

No Change in Billing:
Volume billing continues at the same rate
Attachment does not affect billing charges
Credits deducted hourly based on volume size and type
Same rate whether attached or available

Troubleshooting#

Instance must be in SHUTOFF state
Volume and instance must be in the same region
Volume is already attached
OS/Bootable volumes already attached cannot be attached to other instances
Instance not available in current currency context
No instances appearing in attachment modal
Attach button is disabled
Attachment fails after instance selection

Instance State Reference#

Understanding instance states is critical for successful volume attachment:
SHUTOFF (Required)
ACTIVE (Invalid)
CREATING (Invalid)
HIBERNATED (Invalid)
Description: Instance is powered off and not consuming compute resources
Volume Operations:
✅ Attach volumes allowed
✅ Detach volumes allowed
How to Achieve:
1.
Navigate to instances page
2.
Click shutdown/stop button on instance card
3.
Wait for status to change to SHUTOFF
Verification: Instance card shows "SHUTOFF" status badge

Next Steps#

After attaching volumes:
1
Start Instance
Navigate to the instances page and start the instance with the attached volume
2
Configure Volume in OS
SSH into the instance and configure the volume:
Identify the volume device using lsblk
Create a filesystem if it's a new volume
Mount the volume to your desired location
Configure automatic mounting in /etc/fstab
3
Verify Attachment
Confirm successful attachment:
Volume appears in volume list with "Attached" status
Instance information displayed on volume card
Volume is accessible and usable in instance OS
4
Monitor Usage
Track your volume usage:
Monitor volume billing in account settings
Track storage utilization in your instance
Plan for resize if approaching capacity

Support#

Email Support
Attachment Issues Help
Contact for:
Attachment errors
Instance state problems
Region mismatch issues
Include: volume ID and name, instance ID and name, error messages, screenshots
Detach Volumes
Volume Detachment Guide
Learn how to:
Disconnect volumes from instances
Requirements for detachment
Handle OS/bootable volumes
Prepare for re-attachment
Previous
List and View Volumes
Next
Detach Volumes
Built with