iSCSI Resources

GlobalConfiguration

The Global Configuration resource represents the configuration settings for iSCSI.

List resource

GET /api/v1.0/services/iscsi/globalconfiguration/

Returns the iSCSI Global Configuration settings dictionary.

Example request:

GET /api/v1.0/services/iscsi/globalconfiguration/ HTTP/1.1
Content-Type: application/json

Example response:

HTTP/1.1 200 OK
Vary: Accept
Content-Type: application/json

  {
          "iscsi_maxconnect": 8,
          "iscsi_luc_authnetwork": "",
          "iscsi_iotimeout": 30,
          "iscsi_lucip": "127.0.0.1",
          "iscsi_firstburst": 65536,
          "iscsi_r2t": 32,
          "iscsi_discoveryauthmethod": "None",
          "iscsi_defaultt2w": 2,
          "iscsi_maxrecdata": 262144,
          "iscsi_basename": "iqn.2011-03.org.example.istgt",
          "iscsi_defaultt2r": 60,
          "iscsi_nopinint": 20,
          "iscsi_discoveryauthgroup": null,
          "iscsi_maxburst": 262144,
          "iscsi_toggleluc": false,
          "iscsi_lucport": 3261,
          "iscsi_luc_authgroup": null,
          "iscsi_maxsesh": 16,
          "iscsi_luc_authmethod": "",
          "iscsi_maxoutstandingr2t": 16,
          "id": 1
  }
Response Headers:
 
  • Content-Type – content type of the response
Status Codes:
  • 200 – no error

Update resource

PUT /api/v1.0/services/iscsi/globalconfiguration/

Update Global Configuration.

Example request:

PUT /api/v1.0/services/iscsi/globalconfiguration/ HTTP/1.1
Content-Type: application/json

  {
          "iscsi_maxconnect": 16
  }

Example response:

HTTP/1.1 200 OK
Vary: Accept
Content-Type: application/json

  {
          "iscsi_maxconnect": 16,
          "iscsi_luc_authnetwork": "",
          "iscsi_iotimeout": 30,
          "iscsi_lucip": "127.0.0.1",
          "iscsi_firstburst": 65536,
          "iscsi_r2t": 32,
          "iscsi_discoveryauthmethod": "None",
          "iscsi_defaultt2w": 2,
          "iscsi_maxrecdata": 262144,
          "iscsi_basename": "iqn.2011-03.org.example.istgt",
          "iscsi_defaultt2r": 60,
          "iscsi_nopinint": 20,
          "iscsi_discoveryauthgroup": null,
          "iscsi_maxburst": 262144,
          "iscsi_toggleluc": false,
          "iscsi_lucport": 3261,
          "iscsi_luc_authgroup": null,
          "iscsi_maxsesh": 16,
          "iscsi_luc_authmethod": "",
          "iscsi_maxoutstandingr2t": 16,
          "id": 1
  }
Json Parameters:
 
  • iscsi_basename (string) – base name (e.g. iqn.2007-09.jp.ne.peach.istgt, see RFC 3720 and 3721 for details)
  • iscsi_discoveryauthmethod (string) – None, Auto, CHAP, CHAP Mutual
  • iscsi_discoveryauthgroup (string) – id of auth group
  • iscsi_iotimeout (string) – I/O timeout in seconds
  • iscsi_nopinint (string) – NOPIN sending interval in seconds
  • iscsi_maxsesh (string) – maximum number of sessions holding at same time
  • iscsi_maxconnect (string) – maximum number of connections in each session
  • iscsi_r2t (string) – maximum number of pre-send R2T in each connection
  • iscsi_maxoutstandingr2t (string) – MaxOutstandingR2T
  • iscsi_firstburst (string) – first burst length
  • iscsi_maxburst (string) – max burst length
  • iscsi_maxrecdata (string) – max receive data segment length
  • iscsi_defaultt2w (string) – DefaultTime2Wait
  • iscsi_defaultt2r (string) – DefaultTime2Retain
  • iscsi_toggleluc (string) – Enable LUC
  • iscsi_lucip (string) – Controller IP address
  • iscsi_lucport (string) – Controller TCP port
  • iscsi_luc_authnetwork (string) – Controller Authorized Network
  • iscsi_luc_authmethod (string) – None, Auto, CHAP, CHAP Mutual
  • iscsi_luc_authgroup (string) – id of auth group
Request Headers:
 
  • Content-Type – the request content type
Response Headers:
 
  • Content-Type – the response content type
Status Codes:
  • 202 – no error

Extent

The Extent resource represents extents for the iSCSI targets.

List resource

GET /api/v1.0/services/iscsi/extent/

Returns a list of all extents.

Example request:

GET /api/v1.0/services/iscsi/extent/ HTTP/1.1
Content-Type: application/json

Example response:

HTTP/1.1 200 OK
Vary: Accept
Content-Type: application/json

[
  {
          "iscsi_target_extent_comment": "",
          "iscsi_target_extent_type": "File",
          "iscsi_target_extent_name": "extent",
          "iscsi_target_extent_filesize": "10MB",
          "id": 1,
          "iscsi_target_extent_path": "/mnt/tank/iscsi"
  }
]
Query Parameters:
 
  • offset – offset number. default is 0
  • limit – limit number. default is 30
Response Headers:
 
  • Content-Type – content type of the response
Status Codes:
  • 200 – no error

Create resource

POST /api/v1.0/services/iscsi/extent/

Creates a new extent and returns the new extent object.

Example request:

POST /api/v1.0/services/iscsi/extent/ HTTP/1.1
Content-Type: application/json

  {
          "iscsi_target_extent_type": "File",
          "iscsi_target_extent_name": "extent",
          "iscsi_target_extent_filesize": "10MB",
          "iscsi_target_extent_path": "/mnt/tank/iscsi"
  }

Example response:

HTTP/1.1 201 Created
Vary: Accept
Content-Type: application/json

  {
          "iscsi_target_extent_comment": "",
          "iscsi_target_extent_type": "File",
          "iscsi_target_extent_name": "extent",
          "iscsi_target_extent_filesize": "10MB",
          "id": 1,
          "iscsi_target_extent_path": "/mnt/tank/iscsi"
  }
Json Parameters:
 
  • iscsi_target_extent_name (string) – identifier of the extent
  • iscsi_target_extent_type (string) – File, Device, ZFS Volume
  • iscsi_target_extent_path (string) – path to the extent
  • iscsi_target_extent_filesize (string) – size of extent, 0 means auto, a raw number is bytes, or suffix with KB, MB, TB for convenience
  • iscsi_target_extent_comment (string) – user description
Request Headers:
 
  • Content-Type – the request content type
Response Headers:
 
  • Content-Type – the response content type
Status Codes:
  • 201 – no error

Update resource

PUT /api/v1.0/services/iscsi/extent/(int: id)/

Update extent id.

Example request:

PUT /api/v1.0/services/iscsi/extent/1/ HTTP/1.1
Content-Type: application/json

  {
          "iscsi_target_extent_filesize": "20MB"
  }

Example response:

HTTP/1.1 200 OK
Vary: Accept
Content-Type: application/json

  {
          "iscsi_target_extent_comment": "",
          "iscsi_target_extent_type": "File",
          "iscsi_target_extent_name": "extent",
          "iscsi_target_extent_filesize": "20MB",
          "id": 1,
          "iscsi_target_extent_path": "/mnt/tank/iscsi"
  }
Json Parameters:
 
  • iscsi_target_extent_name (string) – identifier of the extent
  • iscsi_target_extent_type (string) – File, Device, ZFS Volume
  • iscsi_target_extent_path (string) – path to the extent
  • iscsi_target_extent_filesize (string) – size of extent, 0 means auto, a raw number is bytes, or suffix with KB, MB, TB for convenience
  • iscsi_target_extent_comment (string) – user description
Request Headers:
 
  • Content-Type – the request content type
Response Headers:
 
  • Content-Type – the response content type
Status Codes:
  • 202 – no error

Delete resource

DELETE /api/v1.0/services/iscsi/extent/(int: id)/

Delete extent id.

Example request:

DELETE /api/v1.0/services/iscsi/extent/1/ HTTP/1.1
Content-Type: application/json

Example response:

HTTP/1.1 204 No Response
Vary: Accept
Content-Type: application/json
Status Codes:
  • 204 – no error

Authorized Initiator

The Authorized Initiator resource represents network authorized to access to the iSCSI target.

List resource

GET /api/v1.0/services/iscsi/authorizedinitiator/

Returns a list of all authorized initiators.

Example request:

GET /api/v1.0/services/iscsi/authorizedinitiator/ HTTP/1.1
Content-Type: application/json

Example response:

HTTP/1.1 200 OK
Vary: Accept
Content-Type: application/json

[
  {
          "iscsi_target_initiator_initiators": "ALL",
          "iscsi_target_initiator_comment": "",
          "iscsi_target_initiator_auth_network": "ALL",
          "id": 1,
          "iscsi_target_initiator_tag": 1
  }
]
Query Parameters:
 
  • offset – offset number. default is 0
  • limit – limit number. default is 30
Response Headers:
 
  • Content-Type – content type of the response
Status Codes:
  • 200 – no error

Create resource

POST /api/v1.0/services/iscsi/authorizedinitiator/

Creates a new authorized initiator and returns the new object.

Example request:

POST /api/v1.0/services/iscsi/authorizedinitiator/ HTTP/1.1
Content-Type: application/json

  {
          "iscsi_target_initiator_initiators": "ALL",
          "iscsi_target_initiator_auth_network": "ALL",
  }

Example response:

HTTP/1.1 201 Created
Vary: Accept
Content-Type: application/json

  {
          "iscsi_target_initiator_initiators": "ALL",
          "iscsi_target_initiator_comment": "",
          "iscsi_target_initiator_auth_network": "ALL",
          "id": 1,
          "iscsi_target_initiator_tag": 1
  }
Json Parameters:
 
  • iscsi_target_initiator_initiators (string) – initiator authorized to access to the iSCSI target
  • iscsi_target_initiator_auth_network (string) – network authorized to access to the iSCSI target, it takes IP or CIDR addresses or “ALL” for any IPs
  • scsi_target_initiator_comment (string) – description for your reference
Request Headers:
 
  • Content-Type – the request content type
Response Headers:
 
  • Content-Type – the response content type
Status Codes:
  • 201 – no error

Update resource

PUT /api/v1.0/services/iscsi/authorizedinitiator/(int: id)/

Update authorized initiator id.

Example request:

PUT /api/v1.0/services/iscsi/authorizedinitiator/1/ HTTP/1.1
Content-Type: application/json

  {
          "iscsi_target_initiator_auth_network": "192.168.3.0/24"
  }

Example response:

HTTP/1.1 200 OK
Vary: Accept
Content-Type: application/json

  {
          "iscsi_target_initiator_initiators": "ALL",
          "iscsi_target_initiator_comment": "",
          "iscsi_target_initiator_auth_network": "192.168.3.0/24",
          "id": 1,
          "iscsi_target_initiator_tag": 1
  }
Json Parameters:
 
  • iscsi_target_initiator_initiators (string) – initiator authorized to access to the iSCSI target
  • iscsi_target_initiator_auth_network (string) – network authorized to access to the iSCSI target, it takes IP or CIDR addresses or “ALL” for any IPs
  • scsi_target_initiator_comment (string) – description for your reference
Request Headers:
 
  • Content-Type – the request content type
Response Headers:
 
  • Content-Type – the response content type
Status Codes:
  • 202 – no error

Delete resource

DELETE /api/v1.0/services/iscsi/authorizedinitiator/(int: id)/

Delete authorized initiator id.

Example request:

DELETE /api/v1.0/services/iscsi/authorizedinitiator/1/ HTTP/1.1
Content-Type: application/json

Example response:

HTTP/1.1 204 No Response
Vary: Accept
Content-Type: application/json
Status Codes:
  • 204 – no error

Auth Credential

The Auth Credential resource represents user credentials to access the iSCSI target.

List resource

GET /api/v1.0/services/iscsi/authcredential/

Returns a list of all auth credentials.

Example request:

GET /api/v1.0/services/iscsi/authcredential/ HTTP/1.1
Content-Type: application/json

Example response:

HTTP/1.1 200 OK
Vary: Accept
Content-Type: application/json

[
  {
          "iscsi_target_auth_secret": "secret",
          "iscsi_target_auth_peeruser": "peeruser",
          "iscsi_target_auth_peersecret": "peersecret",
          "iscsi_target_auth_user": "user",
          "iscsi_target_auth_tag": 1,
          "id": 1
  }
]
Query Parameters:
 
  • offset – offset number. default is 0
  • limit – limit number. default is 30
Response Headers:
 
  • Content-Type – content type of the response
Status Codes:
  • 200 – no error

Create resource

POST /api/v1.0/services/iscsi/authcredential/

Creates a new auth credential and returns the new object.

Example request:

POST /api/v1.0/services/iscsi/authcredential/ HTTP/1.1
Content-Type: application/json

  {
          "iscsi_target_auth_secret": "secret",
          "iscsi_target_auth_peeruser": "peeruser",
          "iscsi_target_auth_peersecret": "peersecret",
          "iscsi_target_auth_user": "user",
          "iscsi_target_auth_tag": 1
  }

Example response:

HTTP/1.1 201 Created
Vary: Accept
Content-Type: application/json

  {
          "iscsi_target_auth_secret": "secret",
          "iscsi_target_auth_peeruser": "peeruser",
          "iscsi_target_auth_peersecret": "peersecret",
          "iscsi_target_auth_user": "user",
          "iscsi_target_auth_tag": 1,
          "id": 1
  }
Json Parameters:
 
  • iscsi_target_auth_tag (string) – group id
  • iscsi_target_auth_user (string) – target side user name
  • iscsi_target_auth_secret (string) – target side secret
  • iscsi_target_auth_peeruser (string) – initiator side user name
  • iscsi_target_auth_peersecret (string) – initiator side secret
Request Headers:
 
  • Content-Type – the request content type
Response Headers:
 
  • Content-Type – the response content type
Status Codes:
  • 201 – no error

Update resource

PUT /api/v1.0/services/iscsi/authcredential/(int: id)/

Update auth credential id.

Example request:

PUT /api/v1.0/services/iscsi/authcredential/1/ HTTP/1.1
Content-Type: application/json

  {
          "iscsi_target_auth_peeruser": "myuser"
  }

Example response:

HTTP/1.1 200 OK
Vary: Accept
Content-Type: application/json

  {
          "iscsi_target_auth_secret": "secret",
          "iscsi_target_auth_peeruser": "myuser",
          "iscsi_target_auth_peersecret": "peersecret",
          "iscsi_target_auth_user": "user",
          "iscsi_target_auth_tag": 1,
          "id": 1
  }
Json Parameters:
 
  • iscsi_target_auth_tag (string) – group id
  • iscsi_target_auth_user (string) – target side user name
  • iscsi_target_auth_secret (string) – target side secret
  • iscsi_target_auth_peeruser (string) – initiator side user name
  • iscsi_target_auth_peersecret (string) – initiator side secret
Request Headers:
 
  • Content-Type – the request content type
Response Headers:
 
  • Content-Type – the response content type
Status Codes:
  • 202 – no error

Delete resource

DELETE /api/v1.0/services/iscsi/authcredential/(int: id)/

Delete auth credential id.

Example request:

DELETE /api/v1.0/services/iscsi/authcredential/1/ HTTP/1.1
Content-Type: application/json

Example response:

HTTP/1.1 204 No Response
Vary: Accept
Content-Type: application/json
Status Codes:
  • 204 – no error

Target

The Target resource represents user credentials to access the iSCSI target.

List resource

GET /api/v1.0/services/iscsi/target/

Returns a list of all targets.

Example request:

GET /api/v1.0/services/iscsi/target/ HTTP/1.1
Content-Type: application/json

Example response:

HTTP/1.1 200 OK
Vary: Accept
Content-Type: application/json

[
  {
          "iscsi_target_logical_blocksize": 512,
          "iscsi_target_portalgroup": 1,
          "iscsi_target_initialdigest": "Auto",
          "iscsi_target_queue_depth": 32,
          "iscsi_target_name": "target",
          "iscsi_target_initiatorgroup": 1,
          "iscsi_target_alias": null,
          "iscsi_target_type": "Disk",
          "iscsi_target_authgroup": null,
          "iscsi_target_authtype": "Auto",
          "iscsi_target_serial": "10000001",
          "iscsi_target_flags": "rw",
          "id": 1
  }
]
Query Parameters:
 
  • offset – offset number. default is 0
  • limit – limit number. default is 30
Response Headers:
 
  • Content-Type – content type of the response
Status Codes:
  • 200 – no error

Create resource

POST /api/v1.0/services/iscsi/target/

Creates a new target and returns the new object.

Example request:

POST /api/v1.0/services/iscsi/target/ HTTP/1.1
Content-Type: application/json

  {
          "iscsi_target_name": "target",
          "iscsi_target_portalgroup": 1,
          "iscsi_target_initiatorgroup": 1
  }

Example response:

HTTP/1.1 201 Created
Vary: Accept
Content-Type: application/json

  {
          "iscsi_target_logical_blocksize": 512,
          "iscsi_target_portalgroup": 1,
          "iscsi_target_initialdigest": "Auto",
          "iscsi_target_queue_depth": 32,
          "iscsi_target_name": "target",
          "iscsi_target_initiatorgroup": 1,
          "iscsi_target_alias": null,
          "iscsi_target_type": "Disk",
          "iscsi_target_authgroup": null,
          "iscsi_target_authtype": "Auto",
          "iscsi_target_serial": "10000001",
          "iscsi_target_flags": "rw",
          "id": 1
  }
Json Parameters:
 
  • iscsi_target_name (string) – Base Name will be appended automatically when starting without “iqn.”.
  • iscsi_target_alias (string) – optional user-friendly string of the target
  • iscsi_target_serial (string) – serial number for the logical unit
  • iscsi_target_flags (string) – rw, ro
  • iscsi_target_portalgroup (integer) – id of a portal group
  • iscsi_target_initiatorgroup (integer) – id of a initiator group
  • iscsi_target_authtype (string) – None, Auto, CHAP, CHAP Mutual
  • iscsi_target_authgroup (integer) – Authentication Group ID
  • iscsi_target_initialdigest (string) – the method can be accepted by the target. Auto means both none and authentication
  • iscsi_target_queue_depth (integer) – 0=disabled, 1-255=enabled command queuing with specified depth. The recommended queue depth is 32
  • iscsi_target_logical_blocksize (integer) – yYou may specify logical block length (512 by default)
Request Headers:
 
  • Content-Type – the request content type
Response Headers:
 
  • Content-Type – the response content type
Status Codes:
  • 201 – no error

Update resource

PUT /api/v1.0/services/iscsi/target/(int: id)/

Update target id.

Example request:

PUT /api/v1.0/services/iscsi/target/1/ HTTP/1.1
Content-Type: application/json

  {
          "iscsi_target_queue_depth": 64
  }

Example response:

HTTP/1.1 200 OK
Vary: Accept
Content-Type: application/json

  {
          "iscsi_target_logical_blocksize": 512,
          "iscsi_target_portalgroup": 1,
          "iscsi_target_initialdigest": "Auto",
          "iscsi_target_queue_depth": 64,
          "iscsi_target_name": "target",
          "iscsi_target_initiatorgroup": 1,
          "iscsi_target_alias": null,
          "iscsi_target_type": "Disk",
          "iscsi_target_authgroup": null,
          "iscsi_target_authtype": "Auto",
          "iscsi_target_serial": "10000001",
          "iscsi_target_flags": "rw",
          "id": 1
  }
Json Parameters:
 
  • iscsi_target_name (string) – Base Name will be appended automatically when starting without “iqn.”.
  • iscsi_target_alias (string) – optional user-friendly string of the target
  • iscsi_target_serial (string) – serial number for the logical unit
  • iscsi_target_flags (string) – rw, ro
  • iscsi_target_portalgroup (integer) – id of a portal group
  • iscsi_target_initiatorgroup (integer) – id of a initiator group
  • iscsi_target_authtype (string) – None, Auto, CHAP, CHAP Mutual
  • iscsi_target_authgroup (integer) – Authentication Group ID
  • iscsi_target_initialdigest (string) – the method can be accepted by the target. Auto means both none and authentication
  • iscsi_target_queue_depth (integer) – 0=disabled, 1-255=enabled command queuing with specified depth. The recommended queue depth is 32
  • iscsi_target_logical_blocksize (integer) – yYou may specify logical block length (512 by default)
Request Headers:
 
  • Content-Type – the request content type
Response Headers:
 
  • Content-Type – the response content type
Status Codes:
  • 202 – no error

Delete resource

DELETE /api/v1.0/services/iscsi/target/(int: id)/

Delete target id.

Example request:

DELETE /api/v1.0/services/iscsi/target/1/ HTTP/1.1
Content-Type: application/json

Example response:

HTTP/1.1 204 No Response
Vary: Accept
Content-Type: application/json
Status Codes:
  • 204 – no error

Target To Extent

The Target To Extent resource represents association between targets and extents.

List resource

GET /api/v1.0/services/iscsi/targettoextent/

Returns a list of all target to extent.

Example request:

GET /api/v1.0/services/iscsi/targettoextent/ HTTP/1.1
Content-Type: application/json

Example response:

HTTP/1.1 200 OK
Vary: Accept
Content-Type: application/json

[
  {
  }
]
Query Parameters:
 
  • offset – offset number. default is 0
  • limit – limit number. default is 30
Response Headers:
 
  • Content-Type – content type of the response
Status Codes:
  • 200 – no error

Create resource

POST /api/v1.0/services/iscsi/targettoextent/

Creates a new target to extent and returns the new object.

Example request:

POST /api/v1.0/services/iscsi/targettoextent/ HTTP/1.1
Content-Type: application/json

  {
          "iscsi_target": 1,
          "iscsi_extent": 1
  }

Example response:

HTTP/1.1 201 Created
Vary: Accept
Content-Type: application/json

  {
          "iscsi_target": 1,
          "iscsi_extent": 1,
          "id": 1
  }
Json Parameters:
 
  • iscsi_target (integer) – id of the target object
  • iscsi_extent (integer) – id of the extent object
Request Headers:
 
  • Content-Type – the request content type
Response Headers:
 
  • Content-Type – the response content type
Status Codes:
  • 201 – no error

Update resource

PUT /api/v1.0/services/iscsi/targettoextent/(int: id)/

Update target to extent id.

Example request:

PUT /api/v1.0/services/iscsi/targettoextent/1/ HTTP/1.1
Content-Type: application/json

  {
          "iscsi_extent": 2
  }

Example response:

HTTP/1.1 200 OK
Vary: Accept
Content-Type: application/json

  {
          "iscsi_target": 1,
          "iscsi_extent": 2,
          "id": 1
  }
Json Parameters:
 
  • iscsi_target (integer) – id of the target object
  • iscsi_extent (integer) – id of the extent object
Request Headers:
 
  • Content-Type – the request content type
Response Headers:
 
  • Content-Type – the response content type
Status Codes:
  • 202 – no error

Delete resource

DELETE /api/v1.0/services/iscsi/targettoextent/(int: id)/

Delete target to extent id.

Example request:

DELETE /api/v1.0/services/iscsi/targettoextent/1/ HTTP/1.1
Content-Type: application/json

Example response:

HTTP/1.1 204 No Response
Vary: Accept
Content-Type: application/json
Status Codes:
  • 204 – no error

Portal

The Portal resource represents IPs and ports which the daemon will listen to.

List resource

GET /api/v1.0/services/iscsi/portal/

Returns a list of all portals.

Example request:

GET /api/v1.0/services/iscsi/portal/ HTTP/1.1
Content-Type: application/json

Example response:

HTTP/1.1 200 OK
Vary: Accept
Content-Type: application/json

[
  {
          "iscsi_target_portal_tag": 1,
          "id": 1,
          "iscsi_target_portal_ips": [
                  "0.0.0.0:3260"
          ],
          "iscsi_target_portal_comment": ""
  }
]
Query Parameters:
 
  • offset – offset number. default is 0
  • limit – limit number. default is 30
Response Headers:
 
  • Content-Type – content type of the response
Status Codes:
  • 200 – no error

Create resource

POST /api/v1.0/services/iscsi/portal/

Creates a new portal and returns the new object.

Example request:

POST /api/v1.0/services/iscsi/portal/ HTTP/1.1
Content-Type: application/json

  {
          "iscsi_target_portal_ips": [
                  "0.0.0.0:3260"
          ]
  }

Example response:

HTTP/1.1 201 Created
Vary: Accept
Content-Type: application/json

  {
          "iscsi_target_portal_tag": 1,
          "id": 1,
          "iscsi_target_portal_ips": [
                  "0.0.0.0:3260"
          ],
          "iscsi_target_portal_comment": ""
  }
Json Parameters:
 
  • iscsi_target_portal_comment (string) – user description
  • iscsi_target_portal_ips (list(string)) – IP:PORT to listen to
Request Headers:
 
  • Content-Type – the request content type
Response Headers:
 
  • Content-Type – the response content type
Status Codes:
  • 201 – no error

Update resource

PUT /api/v1.0/services/iscsi/portal/(int: id)/

Update portal id.

Example request:

PUT /api/v1.0/services/iscsi/portal/1/ HTTP/1.1
Content-Type: application/json

  {
          "iscsi_target_portal_ips": [
                  "192.168.3.20:3260"
          ]
  }

Example response:

HTTP/1.1 200 OK
Vary: Accept
Content-Type: application/json

  {
          "iscsi_target_portal_tag": 1,
          "id": 1,
          "iscsi_target_portal_ips": [
                  "192.168.3.20:3260"
          ],
          "iscsi_target_portal_comment": ""
  }
Json Parameters:
 
  • iscsi_target_portal_comment (string) – user description
  • iscsi_target_portal_ips (list(string)) – IP:PORT to listen to
Request Headers:
 
  • Content-Type – the request content type
Response Headers:
 
  • Content-Type – the response content type
Status Codes:
  • 202 – no error

Delete resource

DELETE /api/v1.0/services/iscsi/portal/(int: id)/

Delete portal id.

Example request:

DELETE /api/v1.0/services/iscsi/portal/1/ HTTP/1.1
Content-Type: application/json

Example response:

HTTP/1.1 204 No Response
Vary: Accept
Content-Type: application/json
Status Codes:
  • 204 – no error