The Bare Metal Management feature is provided in a separate module. Before you can use this feature, you need to purchase the Plus License of Bare Metal Management, in addition to the Base License.
POST zstack/v1/baremetal/chassis
Authorization: OAuth the-session-uuid
{ "params": { "name": "test", "clusterUuid": "bf598e729e61382ab2486ac40f25c425", "ipmiAddress": "1.1.1.1", "ipmiPort": "623.0", "ipmiUsername": "root", "ipmiPassword": "password" }, "systemTags": [], "userTags": [] }
curl -H "Content-Type: application/json;charset=UTF-8" \ -H "Authorization: OAuth b86c9016b4f24953a9edefb53ca0678c" \ -X POST -d '{"params":{"name":"test","clusterUuid":"bf598e729e61382ab2486ac40f25c425","ipmiAddress":"1.1.1.1","ipmiPort":"623.0","ipmiUsername":"root","ipmiPassword":"password"}}' http://localhost:8080/zstack/v1/baremetal/chassis
Name | Type | Location | Description | Optional Value | Starting Version |
---|---|---|---|---|---|
name | String | body (contained in the params structure) | The name of the bare metal chassis. | 2.6.0 | |
description | String | body (contained in the params structure) | Optional. The detailed description of the bare metal chassis. | 2.6.0 | |
clusterUuid | String | body (contained in the params structure) | The UUID of the cluster where the bare metal chassis resides. | 2.6.0 | |
ipmiAddress | String | body (contained in the params structure) | The IPMI address of the bare metal chassis. | 2.6.0 | |
ipmiPort | Integer | body (contained in the params structure) | Optional. The IPMI port of the bare metal chassis. | 2.6.0 | |
ipmiUsername | String | body (contained in the params structure) | The IPMI username. | 2.6.0 | |
ipmiPassword | String | body (contained in the params structure) | The IPMI password. | 2.6.0 | |
resourceUuid | String | body (contained in the params structure) | The UUID of the bare metal chassis. | 2.6.0 | |
systemTags | List | body | Optional. The system tags. | 2.6.0 | |
userTags | List | body | Optional. The user tags. | 2.6.0 |
{ "inventory": { "uuid": "40fae70b4c573bdfad57d031eaba0eb0", "ipmiAddress": "1.1.1.1", "ipmiPort": 623.0, "ipmiUsername": "root", "ipmiPassword": "password", "state": "Enabled", "status": "HWInfoUnknown" } }
Name | Type | Description | Starting Version |
---|---|---|---|
error | ErrorCode | The error code. If not null, the operation fails, or vice versa. For more information, see error | 2.6.0 |
inventory | BaremetalChassisInventory | See inventory | 2.6.0 |
Name | Type | Description | Starting Version |
---|---|---|---|
code | String | The error code, which is a numbered or alphanumeric code that specifies an error. For example, SYS.1000, HOST.1001. | 2.6.0 |
description | String | The brief description of the error. | 2.6.0 |
details | String | The details about the error. | 2.6.0 |
elaboration | String | The reserved field. Default value: null. | 2.6.0 |
opaque | LinkedHashMap | The reserved field. Default value: null. | 2.6.0 |
cause | ErrorCode | The root error, which is the associated root cause of the current error. If no root error exists, this parameter is null. | 2.6.0 |
Name | Type | Description | Starting Version |
---|---|---|---|
uuid | String | The UUID of the bare metal chassis. | 2.6.0 |
name | String | The name of the bare metal chassis. | 2.6.0 |
description | String | The detailed description of the bare metal chassis. | 2.6.0 |
zoneUuid | String | The zone UUID. | 2.6.0 |
clusterUuid | String | The cluster UUID. | 2.6.0 |
pxeServerUuid | String | 3.1.1 | |
ipmiAddress | String | The IPMI address of the bare metal chassis. | 2.6.0 |
ipmiPort | Integer | The IPMI port of the bare metal chassis. | 2.6.0 |
ipmiUsername | String | The IPMI username. | 2.6.0 |
state | String | 2.6.0 | |
status | String | 2.6.0 | |
createDate | Timestamp | The time when the bare metal chassis was created. | 2.6.0 |
lastOpDate | Timestamp | The time when the bare metal chassis was last modified. | 2.6.0 |
CreateBaremetalChassisAction action = new CreateBaremetalChassisAction(); action.name = "test"; action.clusterUuid = "bf598e729e61382ab2486ac40f25c425"; action.ipmiAddress = "1.1.1.1"; action.ipmiPort = "623.0"; action.ipmiUsername = "root"; action.ipmiPassword = "password"; action.sessionId = "b86c9016b4f24953a9edefb53ca0678c"; CreateBaremetalChassisAction.Result res = action.call();
CreateBaremetalChassisAction action = CreateBaremetalChassisAction() action.name = "test" action.clusterUuid = "bf598e729e61382ab2486ac40f25c425" action.ipmiAddress = "1.1.1.1" action.ipmiPort = "623.0" action.ipmiUsername = "root" action.ipmiPassword = "password" action.sessionId = "b86c9016b4f24953a9edefb53ca0678c" CreateBaremetalChassisAction.Result res = action.call()
DELETE zstack/v1/baremetal/chassis/{uuid}
Authorization: OAuth the-session-uuid
curl -H "Content-Type: application/json;charset=UTF-8" \ -H "Authorization: OAuth b86c9016b4f24953a9edefb53ca0678c" \ -X DELETE http://localhost:8080/zstack/v1/baremetal/chassis/b4962c6429d23e93b9473f5aee202496
Name | Type | Location | Description | Optional Value | Starting Version |
---|---|---|---|---|---|
uuid | String | url | The UUID of the bare metal chassis. | 2.6.0 | |
deleteMode | String | body | Optional. The mode under which the bare metal chassis is deleted. | 2.6.0 | |
systemTags | List | body | Optional. The system tags. | 2.6.0 | |
userTags | List | body | Optional. The user tags. | 2.6.0 |
When the API succeeded, an empty JSON structure {} is returned. When the API failed, the returned JSON structure includes an error field. For example,
{ "error": { "code": "SYS.1001", "description": "A message or a operation timeout", "details": "Create VM on KVM timeout after 300s" } }
DeleteBaremetalChassisAction action = new DeleteBaremetalChassisAction(); action.uuid = "b4962c6429d23e93b9473f5aee202496"; action.deleteMode = "Permissive"; action.sessionId = "b86c9016b4f24953a9edefb53ca0678c"; DeleteBaremetalChassisAction.Result res = action.call();
DeleteBaremetalChassisAction action = DeleteBaremetalChassisAction() action.uuid = "b4962c6429d23e93b9473f5aee202496" action.deleteMode = "Permissive" action.sessionId = "b86c9016b4f24953a9edefb53ca0678c" DeleteBaremetalChassisAction.Result res = action.call()
Back to Top
Email Us
contact@zstack.ioEmail Us
contact@zstack.ioEmail Us
contact@zstack.ioThe download link is sent to your email address.
If you don't see it, check your spam folder, subscription folder, or AD folder. After receiving the email, click the URL to download the documentation.Thank you for using ZStack products and services.
Submit successfully.
We'll connect soon.Thank you for using ZStack products and services.