Abiquo Documentation Cookies Policy

Our Documentation website uses cookies to improve your experience. Please visit our Cookie Policy page for more information about cookies and how we use them.


Abiquo 2.6


Skip to end of metadata
Go to start of metadata

Storage Device Resource

Exposed Resources Hierarchy
Storage Device Resource

Contents:

Abiquo supports external storage, and is able to manage volumes in different storage technologies. This resource provides storage device management features so cloud administrators can add their storage devices into the Abiquo platform and enable self-service storage features for end users.

Main URI of the Resource

This class operates mainly over the Resource URI: /admin/datacenters/{datacenter}/storage/devices

Exposed Methods

List the existing storage devices

List all storage devices that have been added to the platform.

Synopsis: GET http://example.com/api/admin/datacenters/{datacenter}/storage/devices
Roles Required: ROLE_PHYS_DC_RETRIEVE_DETAILS
Request Headers: Accept: application/vnd.abiquo.storagedevices+xml; version=2.4; Content-type: ;
Request Parameters:

Parameter

Required

Default Value

Description

 

 

 

 

Request Message Body Entity:
Response Message Body Entity: StorageDevices Media Type
Request Example:

 Click here to show or hide the request example
List the existing storage devices example
curl http://example.com/api/admin/datacenters/1/storage/devices \
    -v -u user:pass \
    -X GET \
    -H "Accept: application/vnd.abiquo.storagedevices+xml;version=2.4"
    
GET http://example.com/api/admin/datacenters/1/storage/devices HTTP/1.1
Authorization: Basic YWRtaW46eGFiaXF1bw==
Accept: application/vnd.abiquo.storagedevices+xml;version=2.4

HTTP/1.1 200 OK
Date: Mon, 28 Jan 2013 10:55:21 GMT
Keep-Alive: timeout=15, max=8
Set-Cookie: JSESSIONID=BC3D109369D8F3E24322B0C183CDCA2D.node1; Path=/api
Set-Cookie: auth=YWRtaW46MTM1OTM3MjMyMTM0NTpmNWFjNTQ3MDM2ODk5NjYzZjA3ZWRlMzVhMTJjODhkNDpBQklRVU8; Expires=Mon, 28-Jan-2013 11:25:21 GMT; Path=/api
Connection: Keep-Alive
Content-Type: application/vnd.abiquo.storagedevices+xml;version=2.4
Content-Length: 913

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<devices>
    <device>
        <link rel="datacenter" type="application/vnd.abiquo.datacenter+xml" href="http://example.com/api/admin/datacenters/1"/>
        <link rel="edit" type="application/vnd.abiquo.storagedevice+xml" href="http://example.com/api/admin/datacenters/1/storage/devices/1"/>
        <link rel="pools" type="application/vnd.abiquo.storagepools+xml" href="http://example.com/api/admin/datacenters/1/storage/devices/1/pools"/>
        <link rel="tiers" type="application/vnd.abiquo.tiers+xml" href="http://example.com/api/admin/datacenters/1/storage/tiers"/>
        <id>1</id>
        <name>JC-ca0e96b0-ad6</name>
        <storageTechnology>LVM</storageTechnology>
        <managementIp>10.60.12.177</managementIp>
        <managementPort>8180</managementPort>
        <iscsiIp>10.60.12.177</iscsiIp>
        <iscsiPort>3260</iscsiPort>
        <username>foo</username>
        <password>bar</password>
    </device>
</devices>


Create a storage device

Add a new storage device to the platform.

Synopsis: POST http://example.com/api/admin/datacenters/{datacenter}/storage/devices
Roles Required: ROLE_PHYS_DC_ALLOW_MODIFY_STORAGE
Request Headers: Accept: application/vnd.abiquo.storagedevice+xml; version=2.4; Content-type: application/vnd.abiquo.storagedevice+xml; version=2.4;
Request Parameters:

Parameter

Required

Default Value

Description

 

 

 

 

Request Message Body Entity: StorageDevice Media Type
Response Message Body Entity: StorageDevice Media Type
Request Example:

 Click here to show or hide the request example
Create a storage device example
curl http://example.com/api/admin/datacenters/1/storage/devices \
    -v -u user:pass \
    -X POST \
    -d @entity.xml \
    -H "Accept: application/vnd.abiquo.storagedevice+xml;version=2.4" \
    -H "Content-Type: application/vnd.abiquo.storagedevice+xml;version=2.4"
    
POST http://example.com/api/admin/datacenters/1/storage/devices HTTP/1.1
Authorization: Basic YWRtaW46eGFiaXF1bw==
Accept: application/vnd.abiquo.storagedevice+xml;version=2.4
Content-Type: application/vnd.abiquo.storagedevice+xml;version=2.4
Content-Length: 409

HTTP/1.1 201 Created
Date: Mon, 28 Jan 2013 10:55:02 GMT
Location: http://example.com/api/admin/datacenters/1/storage/devices/1
Keep-Alive: timeout=15, max=87
Set-Cookie: JSESSIONID=9A436BBC10EF1C586CCA3BE4B113AAE9.node1; Path=/api
Set-Cookie: auth=YWRtaW46MTM1OTM3MjMwMjUyODplZmY4NzI1YmFhM2EzZjNmYjVhOTJlMzI0ZDZiYjA4NDpBQklRVU8; Expires=Mon, 28-Jan-2013 11:25:02 GMT; Path=/api
Connection: Keep-Alive
Content-Type: application/vnd.abiquo.storagedevice+xml;version=2.4
Content-Length: 896

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<device>
    <link rel="edit" type="application/vnd.abiquo.storagedevice+xml" href="http://example.com/api/admin/datacenters/1/storage/devices/1"/>
    <link rel="datacenter" type="application/vnd.abiquo.datacenter+xml" href="http://example.com/api/admin/datacenters/1"/>
    <link rel="pools" type="application/vnd.abiquo.storagepools+xml" href="http://example.com/api/admin/datacenters/1/storage/devices/1/pools"/>
    <link rel="tiers" type="application/vnd.abiquo.tiers+xml" href="http://example.com/api/admin/datacenters/1/storage/tiers"/>
    <id>1</id>
    <name>JC-Storage Device</name>
    <storageTechnology>LVM</storageTechnology>
    <managementIp>10.60.12.177</managementIp>
    <managementPort>8180</managementPort>
    <iscsiIp>10.60.12.177</iscsiIp>
    <iscsiPort>3260</iscsiPort>
    <username>foo</username>
    <password>bar</password>
</device>


Download a template

You can download the template of the entity here (click right mouse button and 'Save Link As..')

Get the supported storage devices

Get the storage devices that are supported by the Abiquo platform.

Synopsis: GET http://example.com/api/admin/datacenters/{datacenter}/storage/devices/action/supported
Roles Required: ROLE_PHYS_DC_RETRIEVE_DETAILS
Request Headers: Accept: application/vnd.abiquo.storagedevicesmetadata+xml; version=2.4; Content-type: ;
Request Parameters:

Parameter

Required

Default Value

Description

 

 

 

 

Request Message Body Entity:
Response Message Body Entity: StorageDevicesMetadata Media Type
Request Example:

 Click here to show or hide the request example
Get the supported storage devices example
curl http://example.com/api/admin/datacenters/1/storage/devices/action/supported \
    -v -u user:pass \
    -X GET \
    -H "Accept: application/vnd.abiquo.storagedevicesmetadata+xml;version=2.4"

GET http://example.com/api/admin/datacenters/1/storage/devices/action/supported HTTP/1.1
Authorization: Basic YWRtaW46eGFiaXF1bw==
Accept: application/vnd.abiquo.storagedevicesmetadata+xml;version=2.4

HTTP/1.1 200 OK
Date: Mon, 28 Jan 2013 10:55:02 GMT
Keep-Alive: timeout=15, max=88
Set-Cookie: JSESSIONID=EDA0B6ABF06314BA906E411F761F0CAD.node1; Path=/api
Set-Cookie: auth=YWRtaW46MTM1OTM3MjMwMjMwNjo0NTdiY2IxMzM2MTMzYzc4NGE5MGVhYjFiMDM0YzdhYzpBQklRVU8; Expires=Mon, 28-Jan-2013 11:25:02 GMT; Path=/api
Connection: Keep-Alive
Content-Type: application/vnd.abiquo.storagedevicesmetadata+xml;version=2.4
Content-Length: 819

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<devicesmetadata>
    <device>
        <type>GENERIC_ISCSI</type>
        <defaultManagementPort>3260</defaultManagementPort>
        <defaultIscsiPort>3260</defaultIscsiPort>
        <requiresAuthentication>false</requiresAuthentication>
    </device>
    <device>
        <type>LVM</type>
        <defaultManagementPort>8180</defaultManagementPort>
        <defaultIscsiPort>3260</defaultIscsiPort>
        <requiresAuthentication>false</requiresAuthentication>
    </device>
    <device>
        <type>NEXENTA</type>
        <defaultManagementPort>2000</defaultManagementPort>
        <defaultIscsiPort>3260</defaultIscsiPort>
        <requiresAuthentication>true</requiresAuthentication>
    </device>
    <device>
        <type>NETAPP</type>
        <defaultManagementPort>80</defaultManagementPort>
        <defaultIscsiPort>3260</defaultIscsiPort>
        <requiresAuthentication>true</requiresAuthentication>
    </device>
</devicesmetadata>

Get the information about a storage device

Get the information about a storage device.

Synopsis: GET http://example.com/api/admin/datacenters/{datacenter}/storage/devices/{device}
Roles Required: ROLE_PHYS_DC_RETRIEVE_DETAILS
Request Headers: Accept: application/vnd.abiquo.storagedevice+xml; version=2.4; Content-type: ;
Request Parameters:

Parameter

Required

Default Value

Description

 

 

 

 

Request Message Body Entity:
Response Message Body Entity: StorageDevice Media Type
Request Example:

 Click here to show or hide the request example
Get the information about a storage device example
curl http://example.com/api/admin/datacenters/1/storage/devices/1 \
    -v -u user:pass \
    -X GET \
    -H "Accept: application/vnd.abiquo.storagedevice+xml;version=2.4"

GET http://example.com/api/admin/datacenters/1/storage/devices/1 HTTP/1.1
Authorization: Basic YWRtaW46eGFiaXF1bw==
Accept: application/vnd.abiquo.storagedevice+xml;version=2.4

HTTP/1.1 200 OK
Date: Mon, 28 Jan 2013 10:55:21 GMT
Keep-Alive: timeout=15, max=2
Set-Cookie: JSESSIONID=34E55E4692B01C149452E4B1C426DCD5.node1; Path=/api
Set-Cookie: auth=YWRtaW46MTM1OTM3MjMyMTUzMDpmZjNjZmNlNWJkZTk2YmFiOGVkN2U4OWY0YTdkOThlNjpBQklRVU8; Expires=Mon, 28-Jan-2013 11:25:21 GMT; Path=/api
Connection: Keep-Alive
Content-Type: application/vnd.abiquo.storagedevice+xml;version=2.4
Content-Length: 901

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<device>
    <link rel="datacenter" type="application/vnd.abiquo.datacenter+xml" href="http://example.com/api/admin/datacenters/1"/>
    <link rel="edit" type="application/vnd.abiquo.storagedevice+xml" href="http://example.com/api/admin/datacenters/1/storage/devices/1"/>
    <link rel="pools" type="application/vnd.abiquo.storagepools+xml" href="http://example.com/api/admin/datacenters/1/storage/devices/1/pools"/>
    <link rel="tiers" type="application/vnd.abiquo.tiers+xml" href="http://example.com/api/admin/datacenters/1/storage/tiers"/>
    <id>1</id>
    <name>Storage device</name>
    <storageTechnology>LVM</storageTechnology>
    <managementIp>10.60.12.177</managementIp>
    <managementPort>8180</managementPort>
    <iscsiIp>10.60.12.177</iscsiIp>
    <iscsiPort>3260</iscsiPort>
    <username>foo</username>
    <password>bar</password>
</device>



Modify a storage device

Update the information about a storage device.

Synopsis: PUT http://example.com/api/admin/datacenters/{datacenter}/storage/devices/{device}
Roles Required: ROLE_PHYS_DC_ALLOW_MODIFY_STORAGE
Request Headers: Accept: application/vnd.abiquo.storagedevice+xml; version=2.4; Content-type: application/vnd.abiquo.storagedevice+xml; version=2.4;
Request Parameters:

Parameter

Required

Default Value

Description

 

 

 

 

Request Message Body Entity: StorageDevice Media Type
Response Message Body Entity: StorageDevice Media Type
Request Example:

 Click here to show or hide the request example
Modify a storage device example
curl http://example.com/api/admin/datacenters/1/storage/devices/1 \
    -v -u user:pass \
    -X PUT \
    -d @entity.xml \
    -H "Accept: application/vnd.abiquo.storagedevice+xml;version=2.4" \
    -H "Content-Type: application/vnd.abiquo.storagedevice+xml;version=2.4"

PUT http://example.com/api/admin/datacenters/1/storage/devices/1 HTTP/1.1
Authorization: Basic YWRtaW46eGFiaXF1bw==
Accept: application/vnd.abiquo.storagedevice+xml;version=2.4
Content-Type: application/vnd.abiquo.storagedevice+xml;version=2.4
Content-Length: 969

HTTP/1.1 200 OK
Date: Mon, 28 Jan 2013 10:55:21 GMT
Keep-Alive: timeout=15, max=3
Set-Cookie: JSESSIONID=F809C33A8F75B14D5A64140DCC0FAA01.node1; Path=/api
Set-Cookie: auth=YWRtaW46MTM1OTM3MjMyMTQ3NzowY2E2NjIxMmJiNzJmMjMwYTk3NTMxODAzMzdkZDY0MDpBQklRVU8; Expires=Mon, 28-Jan-2013 11:25:21 GMT; Path=/api
Connection: Keep-Alive
Content-Type: application/vnd.abiquo.storagedevice+xml;version=2.4
Content-Length: 901

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<device>
    <link rel="datacenter" type="application/vnd.abiquo.datacenter+xml" href="http://example.com/api/admin/datacenters/1"/>
    <link rel="edit" type="application/vnd.abiquo.storagedevice+xml" href="http://example.com/api/admin/datacenters/1/storage/devices/1"/>
    <link rel="pools" type="application/vnd.abiquo.storagepools+xml" href="http://example.com/api/admin/datacenters/1/storage/devices/1/pools"/>
    <link rel="tiers" type="application/vnd.abiquo.tiers+xml" href="http://example.com/api/admin/datacenters/1/storage/tiers"/>
    <id>1</id>
    <name>Updated storage device</name>
    <storageTechnology>LVM</storageTechnology>
    <managementIp>10.60.12.177</managementIp>
    <managementPort>8180</managementPort>
    <iscsiIp>10.60.12.177</iscsiIp>
    <iscsiPort>3260</iscsiPort>
    <username>foo</username>
    <password>bar</password>
</device>



Download a template

You can download the template of the entity here (click right mouse button and 'Save Link As..')

Remove a storage device

Remove a storage device from the platform.

Synopsis: DELETE http://example.com/api/admin/datacenters/{datacenter}/storage/devices/{device}
Roles Required: ROLE_PHYS_DC_ALLOW_MODIFY_STORAGE
Request Headers: Accept: ; Content-type: ;
Request Parameters:

Parameter

Required

Default Value

Description

 

 

 

 

Request Message Body Entity:
Response Message Body Entity:
Request Example:

 Click here to show or hide the request example
Remove a storage device example
curl http://example.com/api/admin/datacenters/1/storage/devices/1 \
    -v -u user:pass \
    -X DELETE

DELETE http://example.com/api/admin/datacenters/1/storage/devices/1 HTTP/1.1
Authorization: Basic YWRtaW46eGFiaXF1bw==

HTTP/1.1 204 No Content
Date: Mon, 28 Jan 2013 10:56:33 GMT
Keep-Alive: timeout=15, max=58
Set-Cookie: JSESSIONID=9839AD4C51B1BB6329048AD9058FB490.node1; Path=/api
Set-Cookie: auth=YWRtaW46MTM1OTM3MjM5MzE1MjoxZWM5ODdlNGE2Yjc0ZTk3MjljMDc1Y2MzMGI5ZjAzNjpBQklRVU8; Expires=Mon, 28-Jan-2013 11:26:33 GMT; Path=/api
Connection: Keep-Alive

  • No labels