Created
May 23, 2019 16:15
-
-
Save fredericalix/3ea057e7f23412b057b8d4550ee9f352 to your computer and use it in GitHub Desktop.
terraform and openstack ovh: impossible to destroy plan when volume is attached
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
resource "openstack_blockstorage_volume_v3" "src_zpool" { | |
region = "GRA5" | |
name = "src_zpool" | |
description = "freebsd source code zpool" | |
size = 20 | |
} | |
resource "openstack_compute_instance_v2" "build-kernel" { | |
count = "1" | |
name = "build-kernel" | |
image_name = "${var.image}" | |
availability_zone = "${var.availability_zone}" | |
flavor_name = "${var.flavor}" | |
region = "GRA5" | |
key_pair = "${var.ssh_key_pair}" | |
security_groups = ["${var.security_group}"] | |
network { | |
name = "${var.network-ext}" | |
} | |
} | |
resource "openstack_compute_volume_attach_v2" "vsrc_a" { | |
instance_id = "${openstack_compute_instance_v2.build-kernel.id}" | |
volume_id = "${openstack_blockstorage_volume_v3.src_zpool.id}" | |
region = "GRA5" | |
} | |
================= | |
openstack_compute_volume_attach_v2.vsrc_a: Still destroying... (ID: 5b2e5097-5370-4845-84ce-6db5b0250487/764890e8-018a-45a9-af90-bd1d5251a7dc, 3m30s elapsed) | |
2019-05-23T11:55:13.104+0200 [DEBUG] plugin.terraform-provider-openstack_v1.18.0_x4: 2019/05/23 11:55:13 [DEBUG] openstack_compute_volume_attach_v2 attempting to detach OpenStack volume 764890e8-018a-45a9-af90-bd1d5251a7dc from instance 5b2e5097-5370-4845-84ce-6db5b0250487 | |
2019-05-23T11:55:13.104+0200 [DEBUG] plugin.terraform-provider-openstack_v1.18.0_x4: 2019/05/23 11:55:13 [DEBUG] OpenStack Request URL: GET https://compute.gra5.cloud.ovh.net/v2.1/025fbc6fc1b54c0595ce1a90904ec6e0/servers/5b2e5097-5370-4845-84ce-6db5b0250487/os-volume_attachments/764890e8-018a-45a9-af90-bd1d5251a7dc | |
2019-05-23T11:55:13.104+0200 [DEBUG] plugin.terraform-provider-openstack_v1.18.0_x4: 2019/05/23 11:55:13 [DEBUG] OpenStack Request Headers: | |
2019-05-23T11:55:13.104+0200 [DEBUG] plugin.terraform-provider-openstack_v1.18.0_x4: Accept: application/json | |
2019-05-23T11:55:13.104+0200 [DEBUG] plugin.terraform-provider-openstack_v1.18.0_x4: User-Agent: Terraform/0.11.12 gophercloud/2.0.0 | |
2019-05-23T11:55:13.104+0200 [DEBUG] plugin.terraform-provider-openstack_v1.18.0_x4: X-Auth-Token: *** | |
2019-05-23T11:55:13.380+0200 [DEBUG] plugin.terraform-provider-openstack_v1.18.0_x4: 2019/05/23 11:55:13 [DEBUG] OpenStack Response Code: 200 | |
2019-05-23T11:55:13.380+0200 [DEBUG] plugin.terraform-provider-openstack_v1.18.0_x4: 2019/05/23 11:55:13 [DEBUG] OpenStack Response Headers: | |
2019-05-23T11:55:13.380+0200 [DEBUG] plugin.terraform-provider-openstack_v1.18.0_x4: Content-Length: 194 | |
2019-05-23T11:55:13.381+0200 [DEBUG] plugin.terraform-provider-openstack_v1.18.0_x4: Content-Type: application/json | |
2019-05-23T11:55:13.381+0200 [DEBUG] plugin.terraform-provider-openstack_v1.18.0_x4: Date: Thu, 23 May 2019 09:55:14 GMT | |
2019-05-23T11:55:13.381+0200 [DEBUG] plugin.terraform-provider-openstack_v1.18.0_x4: Openstack-Api-Version: compute 2.1 | |
2019-05-23T11:55:13.381+0200 [DEBUG] plugin.terraform-provider-openstack_v1.18.0_x4: Strict-Transport-Security: max-age=15768000 | |
2019-05-23T11:55:13.381+0200 [DEBUG] plugin.terraform-provider-openstack_v1.18.0_x4: Vary: OpenStack-API-Version | |
2019-05-23T11:55:13.381+0200 [DEBUG] plugin.terraform-provider-openstack_v1.18.0_x4: Vary: X-OpenStack-Nova-API-Version | |
2019-05-23T11:55:13.381+0200 [DEBUG] plugin.terraform-provider-openstack_v1.18.0_x4: X-Compute-Request-Id: req-99116f1d-49ad-4c07-a0c9-fdf810b64f83 | |
2019-05-23T11:55:13.381+0200 [DEBUG] plugin.terraform-provider-openstack_v1.18.0_x4: X-Iplb-Instance: 20795 | |
2019-05-23T11:55:13.381+0200 [DEBUG] plugin.terraform-provider-openstack_v1.18.0_x4: X-Openstack-Nova-Api-Version: 2.1 | |
2019-05-23T11:55:13.381+0200 [DEBUG] plugin.terraform-provider-openstack_v1.18.0_x4: 2019/05/23 11:55:13 [DEBUG] OpenStack Response Body: { | |
2019-05-23T11:55:13.381+0200 [DEBUG] plugin.terraform-provider-openstack_v1.18.0_x4: "volumeAttachment": { | |
2019-05-23T11:55:13.381+0200 [DEBUG] plugin.terraform-provider-openstack_v1.18.0_x4: "device": "/dev/vdb", | |
2019-05-23T11:55:13.381+0200 [DEBUG] plugin.terraform-provider-openstack_v1.18.0_x4: "id": "764890e8-018a-45a9-af90-bd1d5251a7dc", | |
2019-05-23T11:55:13.381+0200 [DEBUG] plugin.terraform-provider-openstack_v1.18.0_x4: "serverId": "5b2e5097-5370-4845-84ce-6db5b0250487", | |
2019-05-23T11:55:13.381+0200 [DEBUG] plugin.terraform-provider-openstack_v1.18.0_x4: "volumeId": "764890e8-018a-45a9-af90-bd1d5251a7dc" | |
2019-05-23T11:55:13.381+0200 [DEBUG] plugin.terraform-provider-openstack_v1.18.0_x4: } | |
2019-05-23T11:55:13.381+0200 [DEBUG] plugin.terraform-provider-openstack_v1.18.0_x4: } | |
2019-05-23T11:55:13.381+0200 [DEBUG] plugin.terraform-provider-openstack_v1.18.0_x4: 2019/05/23 11:55:13 [DEBUG] OpenStack Request URL: DELETE https://compute.gra5.cloud.ovh.net/v2.1/025fbc6fc1b54c0595ce1a90904ec6e0/servers/5b2e5097-5370-4845-84ce-6db5b0250487/os-volume_attachments/764890e8-018a-45a9-af90-bd1d5251a7dc | |
2019-05-23T11:55:13.381+0200 [DEBUG] plugin.terraform-provider-openstack_v1.18.0_x4: 2019/05/23 11:55:13 [DEBUG] OpenStack Request Headers: | |
2019-05-23T11:55:13.381+0200 [DEBUG] plugin.terraform-provider-openstack_v1.18.0_x4: Accept: application/json | |
2019-05-23T11:55:13.381+0200 [DEBUG] plugin.terraform-provider-openstack_v1.18.0_x4: User-Agent: Terraform/0.11.12 gophercloud/2.0.0 | |
2019-05-23T11:55:13.381+0200 [DEBUG] plugin.terraform-provider-openstack_v1.18.0_x4: X-Auth-Token: *** | |
2019-05-23T11:55:14.208+0200 [DEBUG] plugin.terraform-provider-openstack_v1.18.0_x4: 2019/05/23 11:55:14 [DEBUG] OpenStack Response Code: 400 | |
2019-05-23T11:55:14.208+0200 [DEBUG] plugin.terraform-provider-openstack_v1.18.0_x4: 2019/05/23 11:55:14 [DEBUG] OpenStack Response Headers: | |
2019-05-23T11:55:14.208+0200 [DEBUG] plugin.terraform-provider-openstack_v1.18.0_x4: Content-Length: 253 | |
2019-05-23T11:55:14.208+0200 [DEBUG] plugin.terraform-provider-openstack_v1.18.0_x4: Content-Type: application/json; charset=UTF-8 | |
2019-05-23T11:55:14.208+0200 [DEBUG] plugin.terraform-provider-openstack_v1.18.0_x4: Date: Thu, 23 May 2019 09:55:15 GMT | |
2019-05-23T11:55:14.208+0200 [DEBUG] plugin.terraform-provider-openstack_v1.18.0_x4: Openstack-Api-Version: compute 2.1 | |
2019-05-23T11:55:14.208+0200 [DEBUG] plugin.terraform-provider-openstack_v1.18.0_x4: Strict-Transport-Security: max-age=15768000 | |
2019-05-23T11:55:14.208+0200 [DEBUG] plugin.terraform-provider-openstack_v1.18.0_x4: Vary: OpenStack-API-Version | |
2019-05-23T11:55:14.209+0200 [DEBUG] plugin.terraform-provider-openstack_v1.18.0_x4: Vary: X-OpenStack-Nova-API-Version | |
2019-05-23T11:55:14.209+0200 [DEBUG] plugin.terraform-provider-openstack_v1.18.0_x4: X-Compute-Request-Id: req-e20a7a80-11b1-41de-8d73-dfd8af202d56 | |
2019-05-23T11:55:14.209+0200 [DEBUG] plugin.terraform-provider-openstack_v1.18.0_x4: X-Iplb-Instance: 20799 | |
2019-05-23T11:55:14.209+0200 [DEBUG] plugin.terraform-provider-openstack_v1.18.0_x4: X-Openstack-Nova-Api-Version: 2.1 | |
2019-05-23T11:55:14.209+0200 [DEBUG] plugin.terraform-provider-openstack_v1.18.0_x4: 2019/05/23 11:55:14 [DEBUG] OpenStack Response Body: { | |
2019-05-23T11:55:14.209+0200 [DEBUG] plugin.terraform-provider-openstack_v1.18.0_x4: "badRequest": { | |
2019-05-23T11:55:14.209+0200 [DEBUG] plugin.terraform-provider-openstack_v1.18.0_x4: "code": 400, | |
2019-05-23T11:55:14.209+0200 [DEBUG] plugin.terraform-provider-openstack_v1.18.0_x4: "message": "Invalid input received: Invalid volume: Unable to detach volume. Volume status must be 'in-use' and attach_status must be 'attached' to detach. (HTTP 400) (Request-ID: req-76663bb3-16ed-422e-9ea9-e79ac790a844)" | |
2019-05-23T11:55:14.209+0200 [DEBUG] plugin.terraform-provider-openstack_v1.18.0_x4: } | |
2019-05-23T11:55:14.209+0200 [DEBUG] plugin.terraform-provider-openstack_v1.18.0_x4: } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment