REST API tape information
How to use the REST API to gather information about IBM Storage Archive Enterprise Edition tapes.
- Request URLs
-
/ibmsa/v2/tapes/ /ibmsa/v2/tape/list/ /ibmsa/v2/tapes/<barcode> /ibmsa/v2/tape/show/<barcode>
- Request data
- No request data.
- Response data
- If an
barcode
is specified, a JSON object that represents the tape with that ID is returned. If nobarcode
is specified, an array of JSON objects is returned.Each JSON object has the following fields:- id: <string>
- The tape ID. Because the bar code is unique within a tape library only, the ID is in the format
of
<barcode>@<library_id>
. Example:TAPE01L7@0000VLIBRARY_LL0
.
- barcode: <string>
- The bar code of the tape.
- state: <string>
- The
<string>
indicates the state of the tape. If the state isunexpected_cond
an error probably occurred. For a list of the possible tape states, the severity of each state, a description of each state, and a possible next action to take, see Tape state information.
- status: <string>
- The
<string>
indicates the severity level of the tape's status. For a list of the possible tape states, and the severity of each state, see Tape state information.
- media_type: <string>
- The media type of a tape. This field is set even if the tape is not yet assigned to any pool.
The
<string>
is empty if the tape is not supported by IBM Storage Archive Enterprise Edition.
- media_generation: <string>
- The media generation of a tape, which determines a possible format in which the tape can be written.
- format_density: <string>
- The format of a tape. The
<string>
is empty if the tape is not assigned to any pool.
- worm: <bool>
- Whether WORM (write-one, read-many) is enabled for the tape.
- capacity: <number>
- The usable capacity of the tape, in bytes. The capacity = used_space + free_space + non_appendable.
- appendable: <string>
- A tape that can be written in the format that is specified by the pool attributes, and on the
cartridge media type that is specified by the pool attributes, is appendable. The format and the
cartridge media type are provided as attributes of the pool to which the tape belongs. The
<string>
can be eitheryes
,no
, or it can be empty. If the tape falls into a state such aswrite_fence
, the<string>
becomesno
. If the<string>
is empty, the tape is not assigned to any pool.
- non_appendable: <string>
- The non-writable space of the tape, in bytes. If the tape is appendable, the value is 0.
- used_space: <number>
- The used capacity of the tape, in bytes. The used_space = active_space + reclaimable_space.
- free_space: <number>
- The available capacity on the tape, in bytes. If the tape is non-appendable, the value is 0.
- active_space: <number>
- The active space (used space that is consumed by the active-referred files) of the tape, in bytes.
- reclaimable_space: <number>
- The reclaimable space of the pool, in bytes. Reclaimable space is used space that is consumed by unreferenced files. This space is the estimated size of the unreferenced space that is available for reclamation on the tape.
- address: <number>
- The address of this tape.
- drive_id: <string>
- The serial number of the drive on which the tape is mounted. If the
<string>
is empty, the tape is not mounted.
- offline_msg: <string>
- The offline message that can be specified when you use the eeadm tape offline command.
- task_id: <string>
- The task ID of the task that is using this tape.
- location_type: <string>
- The location type of the tape. The
<string>
can be one of the following location types, or it can be empty:- drive
- homeslot
- ieslot
- robot
<string>
is empty, the tape is missing.
- library_id: <string>
- The ID of the library (the library serial number) to which the pool belongs.
- library_name: <string>
- The name of the library to which the pool belongs.
- pool_id: <string>
- The ID of the pool to which the tape is assigned. If the
<string>
is empty, the tape is not assigned to any pool.
- pool_name: <string>
- The pool name to which the tape is assigned. If the
<string>
is empty, the tape is not assigned to any pool.
- Parameters
-
- library_name: <string>
- Filter the list of tapes by the library name. Only the tapes that match the criteria are
returned in the response. Example:
library_name=ts4500
.
- pool_id: <string>
- Filter the list of tapes by the pool id. Only the tapes that match the criteria are returned in the response.
- pool_name: <string>
- Filter the list of tapes by the pool name. Only the tapes that match the criteria are returned in the response.