Retrieve image registration status

URL

/v1/imageimport/{import_id}/status

Note: {import_id} is the import ID returned by the virtual server import request API.

Method

GET

Request header

Refer to "Request headers" for details on the request headers of this API.

Table 1. Request headers
Request header Value Description
X-Auth-Token String Tokens that were retrieved using the Identity service.

Request body

This API does not accept request parameters. Any content specified for the request body will be ignored.

Response body

Refer to "Response parameters", "List of response parameters when import fails", "List of detailed error messages when import fails" and "Response parameters when an error occurs" for details on the response parameters of this API. Each parameter is output in JSON format in the response body.

If import_status is "succeeded" or "processing", the content of "Response parameters" is returned.

If import_status is "failed", the content of "Response parameters", "List of response parameters when import fails" and "List of detailed error messages when import fails" is returned.

If API "failed", the content of "Response parameters when an error occurs" is returned. Refer to "Detailed error information list" for details on error information returned when an error occurs.

Table 2. Response parameters
Parameter Value Description
import_status String Status of the import process. One of the following is returned.

keyword
Description
succeeded:
Indicates that the import process was completed successfully.
failed:
Indicates that the import process failed.
processing:
Indicates that the import process is in progress.
queued:
Indicates that the import process is waiting to start.

Status might repeat the state of processing and queued.

progress int Progress status of the import process. Value from 0 to 100.
name String Image name
disk_format String Format of the disk to store in the service.
container_format String Format of the container to store in the service.
location String URL of object storage where VM image files from the transfer source are deployed.
id String Unique ID of the image registered in the service.
min_ram int The minimum RAM (MB) required for using images.
min_disk int The minimum disk capacity (GB) required for using images.
properties String As this value is not used, "" (a null character) is displayed.
ovf_location String As this value is not used, "" (a null character) is displayed.
conversion boolean Indicates whether images are converted.
os_type String OS type in VM image at transfer source.
user_name String User name (*1)
password String * (*1)(*2)
domain_name String Domain name (*1)
kms hash KMS license authentication setting.
server_info String The FQDN and port number of the KMS license server.
activate boolean Activation setting of KMS license server.

*1: This item is not used in newer versions, but it is output as it was for older versions when it is set in the request body of the image registration API.

*2: The input value is converted to * by the image registration API, and the Base64-encoded password string is not saved.

Table 3. List of response parameters when import fails
Parameter Value Description
message String Detailed error message.

Table 4. List of detailed error messages when import fails
Messages Reason for occurrence Action
Specified image is not found. The image specified for location does not exist in the object storage. Confirm the existence of the file in the path specified for the location parameter.
Specified id already exists. An ID that has already been used in image registration was specified. Execute the image registration API using another newly generated UUID.
Import process has stopped unexpectedly. The import process has stopped. Contact support.
Import process takes too long time. Import process has not completed in 7 days after import started. Reduce the size of the virtual machine image being imported. If this does not resolve the problem, contact support.
VMimport process is failed (supplementary information) In cases where supplementary information is "fail to convert image"

There is an error in the virtual machine image to import.

Review and correct the virtual machine image to import.
VMimport process is failed (supplementary information) In cases where supplementary information is "fail to download image"

A timeout occurred while retrieving the virtual machine image to import.

Execute the image registration API again.
VMimport process is failed (supplementary information) In cases where supplementary information is "fail to upload image"

progress = less than 85:
A timeout occurred during the image registration process.
progress = 85 or more:
There is an error in the parameters specified for the image registration API.

progress = less than 85:
Execute the image registration API again.
progress = 85 or more:
Correct the parameters specified for the image registration API and execute it again.
VMimport process is failed (supplementary information) Other than above. Contact support.

Table 5. Response parameters when an error occurs
Parameter Value Description
error_code String Detailed error code.
message String Detailed error message.

Table 6. Detailed error information list
Status code Detailed error code Detailed error message Action
403 40301 You cannot execute this API. Check with the Administrator about your account privileges.
404 40401 Invalid import_id. Modify the request URL.
500 50001 Internal server error. Contact support.
500 50002 Internal server error. Contact support.

Status code

Refer to "Status codes" for details on the status codes returned by this API.

Table 7. Status codes
Status code Description
200 Indicates that retrieval of the virtual server import process status was successful.
401 Indicates an invalid token.
403 Indicates that the virtual server import execution privileges do not exist.
404 The import_id specified in the URL is invalid.

The status is stored for 7 days after import completion. This status code is returned when the API is run after this period.

500 Retrieval of the virtual server import status failed.

Example response body

An example response body is shown below.


{"import_status":"succeeded","progress":100,"name":"sample_image",
"disk_format":"raw","container_format":"bare","location":
"/v1/AUTH_100f1c092038413a8dd6771a455b17f5/test_container/test_image.vmdk",
"id":"14294f46-d9fe-45bb-ba5f-0b93a69c4416","min_ram":0,"min_disk":0,
"properties":{},"ovf_location":"","conversion":true,"os_type":"centos",
"user_name":"testuser","password":"*","domain_name":"testdomain",
"kms":{"server_info":"kms.jp-east-1.cloud.global.fujitsu.com:1688","activate":true}
}