)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"2f3ed97908994f99f18e1231cf822e1f77f7cc37","unresolved":false,"context_lines":[{"line_number":8,"context_line":""},{"line_number":9,"context_line":"The spec is describing the operation of rebuild the volume-backed"},{"line_number":10,"context_line":"server."},{"line_number":11,"context_line":""},{"line_number":12,"context_line":"Change-Id: I646041c872c4172219df2527820a672a0a2cb736"},{"line_number":13,"context_line":"Implements:blueprint volume-backed-server-rebuild"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":4,"id":"df7087c5_cfcd4a5e","line":11,"updated":"2018-03-08 22:40:19.000000000","message":"Add the APIImpact tag.","commit_id":"f687654141375f883b4b05af6b30ba2ee37991f3"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"2f717033663a2bf9ee3c817313c9b1946143d66b","unresolved":false,"context_lines":[{"line_number":7,"context_line":"Support volume-backed server rebuild"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"The spec is describing the operation of rebuild the volume-backed"},{"line_number":10,"context_line":"server."},{"line_number":11,"context_line":""},{"line_number":12,"context_line":"Change-Id: I646041c872c4172219df2527820a672a0a2cb736"},{"line_number":13,"context_line":"Implements:blueprint volume-backed-server-rebuild"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":12,"id":"3f79a3b5_663005ec","line":10,"updated":"2018-11-14 10:25:02.000000000","message":"nit: \" with a new image\"\n\nSince it\u0027s possible to rebuild a volume-backed server today as long as the underlying image does not change.","commit_id":"434d34a7adedfd96b61d3b2dd2396a906f7ee004"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"341d8125465649e5add42743b9e447106e0e86fc","unresolved":false,"context_lines":[{"line_number":7,"context_line":"Support volume-backed server rebuild"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"The spec is describing the operation of rebuild the volume-backed"},{"line_number":10,"context_line":"server."},{"line_number":11,"context_line":""},{"line_number":12,"context_line":"Change-Id: I646041c872c4172219df2527820a672a0a2cb736"},{"line_number":13,"context_line":"Implements:blueprint volume-backed-server-rebuild"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":14,"id":"3f79a3b5_f159545b","line":10,"range":{"start_line":10,"start_character":6,"end_line":10,"end_character":7},"updated":"2018-11-28 15:22:48.000000000","message":"\" with a new image.\"","commit_id":"071d7a97b942d6862f963b7c94804d7c36c661bf"}],"specs/rocky/approved/volume-backed-server-rebuild.rst":[{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"2f3ed97908994f99f18e1231cf822e1f77f7cc37","unresolved":false,"context_lines":[{"line_number":10,"context_line":""},{"line_number":11,"context_line":"https://blueprints.launchpad.net/nova/+spec/volume-backed-server-rebuild"},{"line_number":12,"context_line":""},{"line_number":13,"context_line":"Now nova rebuild the volume-backed instance as make it a fast failure"},{"line_number":14,"context_line":"in the API. But we have been offering volume-backed instance for more"},{"line_number":15,"context_line":"than 4 years and our users love it."},{"line_number":16,"context_line":""},{"line_number":17,"context_line":""},{"line_number":18,"context_line":"Problem description"}],"source_content_type":"text/x-rst","patch_set":4,"id":"df7087c5_2fe96619","line":15,"range":{"start_line":13,"start_character":0,"end_line":15,"end_character":35},"updated":"2018-03-08 22:40:19.000000000","message":"This could use some work. Maybe something like:\n\n\"Currently, the compute API will fail if a user tries to rebuild a volume-backed server with a new image. This spec proposes to add support for rebuilding a volume-backed server with a new image.\"","commit_id":"f687654141375f883b4b05af6b30ba2ee37991f3"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"2f3ed97908994f99f18e1231cf822e1f77f7cc37","unresolved":false,"context_lines":[{"line_number":18,"context_line":"Problem description"},{"line_number":19,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"},{"line_number":20,"context_line":""},{"line_number":21,"context_line":"Currently Nova rebuild is only support instances which are booted from images."},{"line_number":22,"context_line":"The volume-backed instance cannot be rebuild. Trying to rebuild a volume-backed"},{"line_number":23,"context_line":"instance will raise a InvalidRequest exception."},{"line_number":24,"context_line":""}],"source_content_type":"text/x-rst","patch_set":4,"id":"df7087c5_eff28e06","line":21,"range":{"start_line":21,"start_character":23,"end_line":21,"end_character":38},"updated":"2018-03-08 22:40:19.000000000","message":"only supports","commit_id":"f687654141375f883b4b05af6b30ba2ee37991f3"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"2f3ed97908994f99f18e1231cf822e1f77f7cc37","unresolved":false,"context_lines":[{"line_number":19,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"},{"line_number":20,"context_line":""},{"line_number":21,"context_line":"Currently Nova rebuild is only support instances which are booted from images."},{"line_number":22,"context_line":"The volume-backed instance cannot be rebuild. Trying to rebuild a volume-backed"},{"line_number":23,"context_line":"instance will raise a InvalidRequest exception."},{"line_number":24,"context_line":""},{"line_number":25,"context_line":"Use Cases"}],"source_content_type":"text/x-rst","patch_set":4,"id":"df7087c5_6fe67e47","line":22,"range":{"start_line":22,"start_character":0,"end_line":22,"end_character":45},"updated":"2018-03-08 22:40:19.000000000","message":"\"The volume-backed instance cannot be rebuilt when a new image is supplied.\"\n\nIt\u0027s the new image that the API refuses:\n\nhttps://review.openstack.org/#/c/520660/\n\nThe spec should reference that change for context.","commit_id":"f687654141375f883b4b05af6b30ba2ee37991f3"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"2f3ed97908994f99f18e1231cf822e1f77f7cc37","unresolved":false,"context_lines":[{"line_number":20,"context_line":""},{"line_number":21,"context_line":"Currently Nova rebuild is only support instances which are booted from images."},{"line_number":22,"context_line":"The volume-backed instance cannot be rebuild. Trying to rebuild a volume-backed"},{"line_number":23,"context_line":"instance will raise a InvalidRequest exception."},{"line_number":24,"context_line":""},{"line_number":25,"context_line":"Use Cases"},{"line_number":26,"context_line":"---------"}],"source_content_type":"text/x-rst","patch_set":4,"id":"df7087c5_8fe3d233","line":23,"range":{"start_line":23,"start_character":22,"end_line":23,"end_character":36},"updated":"2018-03-08 22:40:19.000000000","message":"HTTPBadRequest","commit_id":"f687654141375f883b4b05af6b30ba2ee37991f3"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"2f3ed97908994f99f18e1231cf822e1f77f7cc37","unresolved":false,"context_lines":[{"line_number":25,"context_line":"Use Cases"},{"line_number":26,"context_line":"---------"},{"line_number":27,"context_line":""},{"line_number":28,"context_line":"When user need to rebuild the volume-backed server."},{"line_number":29,"context_line":""},{"line_number":30,"context_line":"Proposed change"},{"line_number":31,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"}],"source_content_type":"text/x-rst","patch_set":4,"id":"df7087c5_2fd2c65d","line":28,"updated":"2018-03-08 22:40:19.000000000","message":"with a new image.","commit_id":"f687654141375f883b4b05af6b30ba2ee37991f3"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"2f3ed97908994f99f18e1231cf822e1f77f7cc37","unresolved":false,"context_lines":[{"line_number":30,"context_line":"Proposed change"},{"line_number":31,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"},{"line_number":32,"context_line":""},{"line_number":33,"context_line":"Change existing API for rebuild the volume-backed server firstly.Then"},{"line_number":34,"context_line":"go through the original rebuild the image-backed server \u0027s process. Until we"},{"line_number":35,"context_line":"get root_bdm in manager. we create a new volume with the new image, if the"},{"line_number":36,"context_line":"image is the snapshot for volume-backed server, we create a new image"}],"source_content_type":"text/x-rst","patch_set":4,"id":"df7087c5_4fd7fa4c","line":33,"range":{"start_line":33,"start_character":64,"end_line":33,"end_character":69},"updated":"2018-03-08 22:40:19.000000000","message":". Then...","commit_id":"f687654141375f883b4b05af6b30ba2ee37991f3"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"2f3ed97908994f99f18e1231cf822e1f77f7cc37","unresolved":false,"context_lines":[{"line_number":31,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"},{"line_number":32,"context_line":""},{"line_number":33,"context_line":"Change existing API for rebuild the volume-backed server firstly.Then"},{"line_number":34,"context_line":"go through the original rebuild the image-backed server \u0027s process. Until we"},{"line_number":35,"context_line":"get root_bdm in manager. we create a new volume with the new image, if the"},{"line_number":36,"context_line":"image is the snapshot for volume-backed server, we create a new image"},{"line_number":37,"context_line":"according to the snapshot, else, we create the new volume according to"}],"source_content_type":"text/x-rst","patch_set":4,"id":"df7087c5_efcb6ea2","line":34,"range":{"start_line":34,"start_character":49,"end_line":34,"end_character":58},"updated":"2018-03-08 22:40:19.000000000","message":"server\u0027s","commit_id":"f687654141375f883b4b05af6b30ba2ee37991f3"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"2f3ed97908994f99f18e1231cf822e1f77f7cc37","unresolved":false,"context_lines":[{"line_number":31,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"},{"line_number":32,"context_line":""},{"line_number":33,"context_line":"Change existing API for rebuild the volume-backed server firstly.Then"},{"line_number":34,"context_line":"go through the original rebuild the image-backed server \u0027s process. Until we"},{"line_number":35,"context_line":"get root_bdm in manager. we create a new volume with the new image, if the"},{"line_number":36,"context_line":"image is the snapshot for volume-backed server, we create a new image"},{"line_number":37,"context_line":"according to the snapshot, else, we create the new volume according to"},{"line_number":38,"context_line":"the image. In the process of creating volume we should ensure the new"}],"source_content_type":"text/x-rst","patch_set":4,"id":"df7087c5_8fbc3206","line":35,"range":{"start_line":34,"start_character":68,"end_line":35,"end_character":25},"updated":"2018-03-08 22:40:19.000000000","message":"This isn\u0027t a complete sentence, I\u0027m not sure what you\u0027re trying to say here.\n\nTo be clear, I don\u0027t mean to nit-pick on non-native English here, but I need to be able to understand the proposed change.","commit_id":"f687654141375f883b4b05af6b30ba2ee37991f3"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"2f3ed97908994f99f18e1231cf822e1f77f7cc37","unresolved":false,"context_lines":[{"line_number":32,"context_line":""},{"line_number":33,"context_line":"Change existing API for rebuild the volume-backed server firstly.Then"},{"line_number":34,"context_line":"go through the original rebuild the image-backed server \u0027s process. Until we"},{"line_number":35,"context_line":"get root_bdm in manager. we create a new volume with the new image, if the"},{"line_number":36,"context_line":"image is the snapshot for volume-backed server, we create a new image"},{"line_number":37,"context_line":"according to the snapshot, else, we create the new volume according to"},{"line_number":38,"context_line":"the image. In the process of creating volume we should ensure the new"},{"line_number":39,"context_line":"volume \u0027s property the same as the old volume, such as the type, this"},{"line_number":40,"context_line":"is kind of important, particularly for BFV."},{"line_number":41,"context_line":""}],"source_content_type":"text/x-rst","patch_set":4,"id":"df7087c5_ef592efe","line":38,"range":{"start_line":35,"start_character":25,"end_line":38,"end_character":10},"updated":"2018-03-08 22:40:19.000000000","message":"This part could probably just be simply explained that the compute manager will do similar to how boot from volume works where nova creates the volume based on an image or volume snapshot, i.e. where the BDM source_type is \u0027image\u0027 or \u0027snapshot\u0027.","commit_id":"f687654141375f883b4b05af6b30ba2ee37991f3"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"2f3ed97908994f99f18e1231cf822e1f77f7cc37","unresolved":false,"context_lines":[{"line_number":36,"context_line":"image is the snapshot for volume-backed server, we create a new image"},{"line_number":37,"context_line":"according to the snapshot, else, we create the new volume according to"},{"line_number":38,"context_line":"the image. In the process of creating volume we should ensure the new"},{"line_number":39,"context_line":"volume \u0027s property the same as the old volume, such as the type, this"},{"line_number":40,"context_line":"is kind of important, particularly for BFV."},{"line_number":41,"context_line":""},{"line_number":42,"context_line":"Update the root BDM to point to the new volume."}],"source_content_type":"text/x-rst","patch_set":4,"id":"df7087c5_2f6086a5","line":39,"range":{"start_line":39,"start_character":47,"end_line":39,"end_character":63},"updated":"2018-03-08 22:40:19.000000000","message":"Today you can\u0027t pass through the volume type during boot from volume (BFV) when nova creates the volume. I assume that as part of the rebuild with a volume-backed server, if nova creates a new volume, we will have to pass the existing volume\u0027s type to cinder (which could fail if that volume type no longer exists).\n\nIt would probably be good to have a list of known error conditions that we could hit.  A few I can think of:\n\n* The volume type no longer exists in Cinder.\n* The volume create fails due to the project being over quota.\n* The volume create could fail for some unknown reason, or it could timeout (see how ComputeManager._await_block_device_map_created is used).\n\nWhat do we do in those cases? I think we would just abort the rebuild operation, raise an exception in the compute manager which should log a fault for the instance, and the instance should go back to it\u0027s original vm_state (ACTIVE, STOPPED or ERROR).","commit_id":"f687654141375f883b4b05af6b30ba2ee37991f3"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"2f3ed97908994f99f18e1231cf822e1f77f7cc37","unresolved":false,"context_lines":[{"line_number":41,"context_line":""},{"line_number":42,"context_line":"Update the root BDM to point to the new volume."},{"line_number":43,"context_line":""},{"line_number":44,"context_line":"Delete the old volume."},{"line_number":45,"context_line":""},{"line_number":46,"context_line":"Alternatives"},{"line_number":47,"context_line":"------------"}],"source_content_type":"text/x-rst","patch_set":4,"id":"df7087c5_cf70ea75","line":44,"updated":"2018-03-08 22:40:19.000000000","message":"What if the BDM has the delete_on_termination flag set to False?","commit_id":"f687654141375f883b4b05af6b30ba2ee37991f3"},{"author":{"_account_id":27594,"name":"Jie Li","email":"lijie@unitedstack.com","username":"ramboman"},"change_message_id":"62132f558e6f55213dedd054e47a14835d6b28d4","unresolved":false,"context_lines":[{"line_number":41,"context_line":""},{"line_number":42,"context_line":"Update the root BDM to point to the new volume."},{"line_number":43,"context_line":""},{"line_number":44,"context_line":"Delete the old volume."},{"line_number":45,"context_line":""},{"line_number":46,"context_line":"Alternatives"},{"line_number":47,"context_line":"------------"}],"source_content_type":"text/x-rst","patch_set":4,"id":"df7087c5_7ac81121","line":44,"in_reply_to":"df7087c5_205fd972","updated":"2018-03-14 02:51:36.000000000","message":"Can we add a \"delete_old_root_volume\" flag, if it is true, we will delete the old volume, else, retain the old volume.The flag default is true.This flag \u0027s priority is higher than the \"delete on termination\" flag.","commit_id":"f687654141375f883b4b05af6b30ba2ee37991f3"},{"author":{"_account_id":7198,"name":"Jay Bryant","email":"jungleboyj@electronicjungle.net","username":"jsbryant"},"change_message_id":"b2a56576e49c9771d31693cc624f8408b6ee1d93","unresolved":false,"context_lines":[{"line_number":41,"context_line":""},{"line_number":42,"context_line":"Update the root BDM to point to the new volume."},{"line_number":43,"context_line":""},{"line_number":44,"context_line":"Delete the old volume."},{"line_number":45,"context_line":""},{"line_number":46,"context_line":"Alternatives"},{"line_number":47,"context_line":"------------"}],"source_content_type":"text/x-rst","patch_set":4,"id":"df7087c5_205fd972","line":44,"in_reply_to":"df7087c5_2606161f","updated":"2018-03-13 15:13:35.000000000","message":"I agree with Matt that don\u0027t delete means don\u0027t delete.  If that is not the approach taken there needs to be a big red warning flag associated with this.","commit_id":"f687654141375f883b4b05af6b30ba2ee37991f3"},{"author":{"_account_id":9555,"name":"Matthew Booth","email":"mbooth@redhat.com","username":"MatthewBooth"},"change_message_id":"87863133d0a9438ff1f34d38be0f96bfac8be51f","unresolved":false,"context_lines":[{"line_number":41,"context_line":""},{"line_number":42,"context_line":"Update the root BDM to point to the new volume."},{"line_number":43,"context_line":""},{"line_number":44,"context_line":"Delete the old volume."},{"line_number":45,"context_line":""},{"line_number":46,"context_line":"Alternatives"},{"line_number":47,"context_line":"------------"}],"source_content_type":"text/x-rst","patch_set":4,"id":"df7087c5_a05e890f","line":44,"in_reply_to":"df7087c5_2606161f","updated":"2018-03-13 14:56:11.000000000","message":"I definitely agree this is a \u0027policy\u0027 question and more input, especially from users, would be helpful.\n\nMy 2c is that delete_on_termination means: don\u0027t delete the volume when we kill the instance. Rebuild means: re-initialize this instance in place. Put like that, I don\u0027t think these things conflict. We should re-initialize the existing volume from image, blowing away all the data on it. Especially considering that we don\u0027t currently allow this at all, this seems like the the least surprising behaviour to me.","commit_id":"f687654141375f883b4b05af6b30ba2ee37991f3"},{"author":{"_account_id":16137,"name":"Tobias Urdin","email":"tobias.urdin@binero.com","username":"tobasco"},"change_message_id":"72e9abc2466d60196698768612e55c5b397a017c","unresolved":false,"context_lines":[{"line_number":41,"context_line":""},{"line_number":42,"context_line":"Update the root BDM to point to the new volume."},{"line_number":43,"context_line":""},{"line_number":44,"context_line":"Delete the old volume."},{"line_number":45,"context_line":""},{"line_number":46,"context_line":"Alternatives"},{"line_number":47,"context_line":"------------"}],"source_content_type":"text/x-rst","patch_set":4,"id":"df7087c5_c8c2a559","line":44,"in_reply_to":"df7087c5_7c3803ed","updated":"2018-03-14 15:24:58.000000000","message":"From an operation standpoint I would be fine having another option to allow the deletion of the old root volume. But defaulting to deleting the old root volume would guarantee data loss for some users.","commit_id":"f687654141375f883b4b05af6b30ba2ee37991f3"},{"author":{"_account_id":27594,"name":"Jie Li","email":"lijie@unitedstack.com","username":"ramboman"},"change_message_id":"36acc941c945e0ba4eb30c0088dcd603edca10c6","unresolved":false,"context_lines":[{"line_number":41,"context_line":""},{"line_number":42,"context_line":"Update the root BDM to point to the new volume."},{"line_number":43,"context_line":""},{"line_number":44,"context_line":"Delete the old volume."},{"line_number":45,"context_line":""},{"line_number":46,"context_line":"Alternatives"},{"line_number":47,"context_line":"------------"}],"source_content_type":"text/x-rst","patch_set":4,"id":"df7087c5_7c3803ed","line":44,"in_reply_to":"df7087c5_a05e890f","updated":"2018-03-14 13:20:52.000000000","message":"Yes,you are right,that delete_on_termination means: don\u0027t delete the volume when we kill the instance.And the rebuild is use primary resource to rebuild instance.It is two levels.The delete_on_termination flag is unrelated to rebuild.","commit_id":"f687654141375f883b4b05af6b30ba2ee37991f3"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"f5690dcabbfbd48eb731afa9e952acb888a5b1cd","unresolved":false,"context_lines":[{"line_number":41,"context_line":""},{"line_number":42,"context_line":"Update the root BDM to point to the new volume."},{"line_number":43,"context_line":""},{"line_number":44,"context_line":"Delete the old volume."},{"line_number":45,"context_line":""},{"line_number":46,"context_line":"Alternatives"},{"line_number":47,"context_line":"------------"}],"source_content_type":"text/x-rst","patch_set":4,"id":"df7087c5_3e76da3f","line":44,"in_reply_to":"df7087c5_c8c2a559","updated":"2018-03-15 15:12:00.000000000","message":"\u003e deleting the old root volume would guarantee data loss for some users\n\nThat\u0027s what rebuild does, it blows away the disk. Same thing happens today for non-volume-backed server rebuild.\n\nIf you don\u0027t want to lose your data before rebuilding the server, you\u0027d have to take a snapshot of it. And if you take a snapshot of a volume-backed server, then the volume is going to have a snapshot in cinder and you can\u0027t delete the volume while it has snapshots linked to it...so it\u0027s a mess.","commit_id":"f687654141375f883b4b05af6b30ba2ee37991f3"},{"author":{"_account_id":27594,"name":"Jie Li","email":"lijie@unitedstack.com","username":"ramboman"},"change_message_id":"0e61ea04331212aa0c2dd885420286980a25c275","unresolved":false,"context_lines":[{"line_number":41,"context_line":""},{"line_number":42,"context_line":"Update the root BDM to point to the new volume."},{"line_number":43,"context_line":""},{"line_number":44,"context_line":"Delete the old volume."},{"line_number":45,"context_line":""},{"line_number":46,"context_line":"Alternatives"},{"line_number":47,"context_line":"------------"}],"source_content_type":"text/x-rst","patch_set":4,"id":"df7087c5_da72b8e3","line":44,"in_reply_to":"df7087c5_cf70ea75","updated":"2018-03-12 10:54:22.000000000","message":"Combined with production environment,we always use the rebuild operation when the root volume is bad,so the volume should be deleted.What do you think of it?","commit_id":"f687654141375f883b4b05af6b30ba2ee37991f3"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"65a03912ccf9f9b99c27f5fbf7eb383130e3cbe9","unresolved":false,"context_lines":[{"line_number":41,"context_line":""},{"line_number":42,"context_line":"Update the root BDM to point to the new volume."},{"line_number":43,"context_line":""},{"line_number":44,"context_line":"Delete the old volume."},{"line_number":45,"context_line":""},{"line_number":46,"context_line":"Alternatives"},{"line_number":47,"context_line":"------------"}],"source_content_type":"text/x-rst","patch_set":4,"id":"df7087c5_2606161f","line":44,"in_reply_to":"df7087c5_da72b8e3","updated":"2018-03-13 13:19:45.000000000","message":"I see two problems:\n\n1. The user created a volume-backed server and indicated delete_on_termination\u003dFalse. Deleting the root volume when rebuilding the server with a new image seems to break the intent of the delete_on_termination flag, which tells nova to not touch the volume.\n\n2. If we don\u0027t delete the root volume during rebuild, the number of volumes the project/user owns could build up to the point that the rebuild fails because of volume quota. In this case, the user can either cleanup old volumes they aren\u0027t using anymore, or request more quota.\n\nAre there other reasons that nova *should* delete the root volume?\n\nMaybe this is a question that should be asked in the openstack-dev and openstack-operators mailing lists to get wider input.","commit_id":"f687654141375f883b4b05af6b30ba2ee37991f3"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"2f3ed97908994f99f18e1231cf822e1f77f7cc37","unresolved":false,"context_lines":[{"line_number":56,"context_line":"REST API impact"},{"line_number":57,"context_line":"---------------"},{"line_number":58,"context_line":""},{"line_number":59,"context_line":"Now nova rebuild the volume-backed instance as make it a fast failure in"},{"line_number":60,"context_line":"the API. If achieve this, we will change the rebuild request \u0027s response"},{"line_number":61,"context_line":"code to 202."},{"line_number":62,"context_line":""},{"line_number":63,"context_line":"Security impact"},{"line_number":64,"context_line":"---------------"}],"source_content_type":"text/x-rst","patch_set":4,"id":"df7087c5_6ff0beca","line":61,"range":{"start_line":59,"start_character":0,"end_line":61,"end_character":12},"updated":"2018-03-08 22:40:19.000000000","message":"This needs work.\n\nYou can omit the first sentence as that\u0027s already stated above.\n\nWhat you need to describe here is that we will add a new compute API microversion to indicate the API now supports rebuilding a volume-backed server with a new image (this is for discovery of the capability for API users). Users will have to request the new microversion to rebuild a volume-backed server with a new image.\n\nI think that\u0027s basically it. Nothing changes in the request or response body. The only thing that changes, as noted, is that the 400 response becomes a 202 response.","commit_id":"f687654141375f883b4b05af6b30ba2ee37991f3"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"2f3ed97908994f99f18e1231cf822e1f77f7cc37","unresolved":false,"context_lines":[{"line_number":68,"context_line":"Notifications impact"},{"line_number":69,"context_line":"--------------------"},{"line_number":70,"context_line":""},{"line_number":71,"context_line":"None"},{"line_number":72,"context_line":""},{"line_number":73,"context_line":"Other end user impact"},{"line_number":74,"context_line":"---------------------"}],"source_content_type":"text/x-rst","patch_set":4,"id":"df7087c5_afa25699","line":71,"updated":"2018-03-08 22:40:19.000000000","message":"The rebuild.start and rebuild.end notifications might need some kind of update. Today they assert that they don\u0027t need to include the image id since it\u0027s included in the instance payload [1], but that\u0027s only if instance.image_ref is set, which it\u0027s not for volume-backed instances [2]:\n\n[1] https://github.com/openstack/nova/blob/ff47787e11a0a1b6299298b25b4c982bcfae6e1c/nova/compute/manager.py#L3024\n\n[2] https://github.com/openstack/nova/blob/ff47787e11a0a1b6299298b25b4c982bcfae6e1c/nova/compute/api.py#L3111\n\nHowever, if versioned notifications are configured to include BDMs then the root bdm along with it\u0027s volume ID would be in the notification, so maybe we don\u0027t have anything that we need to change here. It might be worth asking gibi about this.","commit_id":"f687654141375f883b4b05af6b30ba2ee37991f3"},{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"872716860d898d7dffb7d1ad44ccecb9987d96b5","unresolved":false,"context_lines":[{"line_number":68,"context_line":"Notifications impact"},{"line_number":69,"context_line":"--------------------"},{"line_number":70,"context_line":""},{"line_number":71,"context_line":"None"},{"line_number":72,"context_line":""},{"line_number":73,"context_line":"Other end user impact"},{"line_number":74,"context_line":"---------------------"}],"source_content_type":"text/x-rst","patch_set":4,"id":"3f79a3b5_e20dd392","line":71,"in_reply_to":"df7087c5_9a7f25df","updated":"2018-10-18 15:18:38.000000000","message":"Good point Matt. I would go with your option 2) and say that if volume related information is needed in the payload the turn on the bdms_in_notifications CONF option.","commit_id":"f687654141375f883b4b05af6b30ba2ee37991f3"},{"author":{"_account_id":27594,"name":"Jie Li","email":"lijie@unitedstack.com","username":"ramboman"},"change_message_id":"f18a8d459d1f6fef40f77c60399a5823b5460c08","unresolved":false,"context_lines":[{"line_number":68,"context_line":"Notifications impact"},{"line_number":69,"context_line":"--------------------"},{"line_number":70,"context_line":""},{"line_number":71,"context_line":"None"},{"line_number":72,"context_line":""},{"line_number":73,"context_line":"Other end user impact"},{"line_number":74,"context_line":"---------------------"}],"source_content_type":"text/x-rst","patch_set":4,"id":"df7087c5_9a7f25df","line":71,"in_reply_to":"df7087c5_afa25699","updated":"2018-03-14 02:50:02.000000000","message":"@Balázs GibizerCan you give me some advice about this?Thank you.","commit_id":"f687654141375f883b4b05af6b30ba2ee37991f3"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"2f3ed97908994f99f18e1231cf822e1f77f7cc37","unresolved":false,"context_lines":[{"line_number":83,"context_line":"Other deployer impact"},{"line_number":84,"context_line":"---------------------"},{"line_number":85,"context_line":""},{"line_number":86,"context_line":"None"},{"line_number":87,"context_line":""},{"line_number":88,"context_line":"Developer impact"},{"line_number":89,"context_line":"----------------"}],"source_content_type":"text/x-rst","patch_set":4,"id":"df7087c5_efb12ee3","line":86,"updated":"2018-03-08 22:40:19.000000000","message":"One thing here is that even if the API says that it supports rebuilding volume-backed instances with a new image, if the compute host that the instance is running on is old (queens level code), then the rebuild isn\u0027t going to do anything. The API will cast to the compute and we won\u0027t change anything in the root disk, which is bug 1482040.\n\nWhat we\u0027d likely want/need to do is check the nova-compute service version for the host that the instance is running on. If the nova-compute service version is not new enough to support rebuilding volume-backed instances with a new image, then we need to fail the request in the API as we do today.\n\nThis should probably be explained in the \"proposed change\" section.","commit_id":"f687654141375f883b4b05af6b30ba2ee37991f3"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"2f3ed97908994f99f18e1231cf822e1f77f7cc37","unresolved":false,"context_lines":[{"line_number":110,"context_line":""},{"line_number":111,"context_line":"* Create a new volume with the new image_id"},{"line_number":112,"context_line":"* Update the root BDM to point to the new volume"},{"line_number":113,"context_line":"* Delete the old volume"},{"line_number":114,"context_line":""},{"line_number":115,"context_line":""},{"line_number":116,"context_line":"Dependencies"}],"source_content_type":"text/x-rst","patch_set":4,"id":"df7087c5_afcb3651","line":113,"updated":"2018-03-08 22:40:19.000000000","message":"See above, I\u0027m not sure about the BDM.delete_on_termination\u003dFalse case.","commit_id":"f687654141375f883b4b05af6b30ba2ee37991f3"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"2f3ed97908994f99f18e1231cf822e1f77f7cc37","unresolved":false,"context_lines":[{"line_number":126,"context_line":""},{"line_number":127,"context_line":"* Nova unit tests"},{"line_number":128,"context_line":"* Nova functional tests"},{"line_number":129,"context_line":"* Provide image which any format to rebuild"},{"line_number":130,"context_line":""},{"line_number":131,"context_line":"Documentation Impact"},{"line_number":132,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"}],"source_content_type":"text/x-rst","patch_set":4,"id":"df7087c5_6fc51e3c","line":129,"range":{"start_line":129,"start_character":2,"end_line":129,"end_character":43},"updated":"2018-03-08 22:40:19.000000000","message":"I\u0027m not sure what this means.","commit_id":"f687654141375f883b4b05af6b30ba2ee37991f3"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"2f3ed97908994f99f18e1231cf822e1f77f7cc37","unresolved":false,"context_lines":[{"line_number":131,"context_line":"Documentation Impact"},{"line_number":132,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"},{"line_number":133,"context_line":""},{"line_number":134,"context_line":"We will delete the API documentation \u0027s Note about rebuild"},{"line_number":135,"context_line":"the volume-backed server."},{"line_number":136,"context_line":""},{"line_number":137,"context_line":"The following document is updated."},{"line_number":138,"context_line":""}],"source_content_type":"text/x-rst","patch_set":4,"id":"df7087c5_efe60ee9","line":135,"range":{"start_line":134,"start_character":0,"end_line":135,"end_character":25},"updated":"2018-03-08 22:40:19.000000000","message":"and replace it with a note about the required minimum microversion for rebuilding a volume-backed server with a new image.","commit_id":"f687654141375f883b4b05af6b30ba2ee37991f3"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"2f3ed97908994f99f18e1231cf822e1f77f7cc37","unresolved":false,"context_lines":[{"line_number":141,"context_line":"References"},{"line_number":142,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"},{"line_number":143,"context_line":""},{"line_number":144,"context_line":"* This is the discuss about rebuild the volume-backed server"},{"line_number":145,"context_line":"  http://lists.openstack.org/pipermail/openstack-dev/2017-October/123255.html"},{"line_number":146,"context_line":""},{"line_number":147,"context_line":"* This is the patch about rebuild"}],"source_content_type":"text/x-rst","patch_set":4,"id":"df7087c5_0feca2c5","line":144,"range":{"start_line":144,"start_character":14,"end_line":144,"end_character":21},"updated":"2018-03-08 22:40:19.000000000","message":"discussion","commit_id":"f687654141375f883b4b05af6b30ba2ee37991f3"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"2f3ed97908994f99f18e1231cf822e1f77f7cc37","unresolved":false,"context_lines":[{"line_number":144,"context_line":"* This is the discuss about rebuild the volume-backed server"},{"line_number":145,"context_line":"  http://lists.openstack.org/pipermail/openstack-dev/2017-October/123255.html"},{"line_number":146,"context_line":""},{"line_number":147,"context_line":"* This is the patch about rebuild"},{"line_number":148,"context_line":"  https://review.openstack.org/#/c/528740/"},{"line_number":149,"context_line":""},{"line_number":150,"context_line":"* This is the blueprint about rebuild"},{"line_number":151,"context_line":"  https://blueprints.launchpad.net/nova/+spec/volume-backed-server-rebuild"},{"line_number":152,"context_line":""},{"line_number":153,"context_line":"History"},{"line_number":154,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d"}],"source_content_type":"text/x-rst","patch_set":4,"id":"df7087c5_afd016f9","line":151,"range":{"start_line":147,"start_character":0,"end_line":151,"end_character":74},"updated":"2018-03-08 22:40:19.000000000","message":"You can remove these, they are already linked in via launchpad.","commit_id":"f687654141375f883b4b05af6b30ba2ee37991f3"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"535db54c9c9edddfac73dedf3820ff86bf345780","unresolved":false,"context_lines":[{"line_number":19,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"},{"line_number":20,"context_line":""},{"line_number":21,"context_line":"Currently Nova rebuild is only supports instances which are booted from images."},{"line_number":22,"context_line":"The volume-backed instance cannot be rebuild when a new image is supplied."},{"line_number":23,"context_line":"Trying to rebuild a volume-backed instance will raise a HTTPBadRequest"},{"line_number":24,"context_line":"exception."},{"line_number":25,"context_line":""}],"source_content_type":"text/x-rst","patch_set":5,"id":"df7087c5_8b624609","line":22,"range":{"start_line":22,"start_character":37,"end_line":22,"end_character":44},"updated":"2018-03-15 14:59:50.000000000","message":"rebuilt","commit_id":"4628a6a94a7e5b82bf1d0c96a8dc6ea9a5f2f9f0"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"195165cd728392a391c4add5588d831853b31adc","unresolved":false,"context_lines":[{"line_number":34,"context_line":"Change existing API for rebuild the volume-backed server firstly. Then"},{"line_number":35,"context_line":"the compute manager will do similar to how boot from volume works where"},{"line_number":36,"context_line":"the BDM source_type is \u0027image\u0027 or \u0027snapshot\u0027. In the process of creating"},{"line_number":37,"context_line":"volume we should ensure the new volume\u0027s property the same as the old"},{"line_number":38,"context_line":"volume, such as the type, this is kind of important, particularly for BFV."},{"line_number":39,"context_line":"In this process, there are some conditions that we could hit:"},{"line_number":40,"context_line":""}],"source_content_type":"text/x-rst","patch_set":5,"id":"df7087c5_3e533ae4","line":37,"range":{"start_line":37,"start_character":41,"end_line":37,"end_character":49},"updated":"2018-03-15 15:03:29.000000000","message":"type","commit_id":"4628a6a94a7e5b82bf1d0c96a8dc6ea9a5f2f9f0"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"f5690dcabbfbd48eb731afa9e952acb888a5b1cd","unresolved":false,"context_lines":[{"line_number":34,"context_line":"Change existing API for rebuild the volume-backed server firstly. Then"},{"line_number":35,"context_line":"the compute manager will do similar to how boot from volume works where"},{"line_number":36,"context_line":"the BDM source_type is \u0027image\u0027 or \u0027snapshot\u0027. In the process of creating"},{"line_number":37,"context_line":"volume we should ensure the new volume\u0027s property the same as the old"},{"line_number":38,"context_line":"volume, such as the type, this is kind of important, particularly for BFV."},{"line_number":39,"context_line":"In this process, there are some conditions that we could hit:"},{"line_number":40,"context_line":""}],"source_content_type":"text/x-rst","patch_set":5,"id":"df7087c5_9ee4c60e","line":37,"range":{"start_line":37,"start_character":41,"end_line":37,"end_character":49},"in_reply_to":"df7087c5_3e533ae4","updated":"2018-03-15 15:12:00.000000000","message":"Oh I guess you\u0027re being generic about \u0027property\u0027 here, I didn\u0027t read the \u0027such as the type\u0027 part until later.","commit_id":"4628a6a94a7e5b82bf1d0c96a8dc6ea9a5f2f9f0"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"535db54c9c9edddfac73dedf3820ff86bf345780","unresolved":false,"context_lines":[{"line_number":38,"context_line":"volume, such as the type, this is kind of important, particularly for BFV."},{"line_number":39,"context_line":"In this process, there are some conditions that we could hit:"},{"line_number":40,"context_line":""},{"line_number":41,"context_line":"* The volume property no longer exists in Cinder."},{"line_number":42,"context_line":"* The volume create fails due to the project being over quota."},{"line_number":43,"context_line":"* The volume create could fail for some unknown reason, or it could"},{"line_number":44,"context_line":"  timeout (see how ComputeManager._await_block_device_map_created is used)."}],"source_content_type":"text/x-rst","patch_set":5,"id":"df7087c5_4b066e22","line":41,"updated":"2018-03-15 14:59:50.000000000","message":"Does this mean \"the source_type\" property no longer exists? If so, please say that.","commit_id":"4628a6a94a7e5b82bf1d0c96a8dc6ea9a5f2f9f0"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"195165cd728392a391c4add5588d831853b31adc","unresolved":false,"context_lines":[{"line_number":38,"context_line":"volume, such as the type, this is kind of important, particularly for BFV."},{"line_number":39,"context_line":"In this process, there are some conditions that we could hit:"},{"line_number":40,"context_line":""},{"line_number":41,"context_line":"* The volume property no longer exists in Cinder."},{"line_number":42,"context_line":"* The volume create fails due to the project being over quota."},{"line_number":43,"context_line":"* The volume create could fail for some unknown reason, or it could"},{"line_number":44,"context_line":"  timeout (see how ComputeManager._await_block_device_map_created is used)."}],"source_content_type":"text/x-rst","patch_set":5,"id":"df7087c5_5e4e2e38","line":41,"in_reply_to":"df7087c5_4b066e22","updated":"2018-03-15 15:03:29.000000000","message":"I think they mean volume type.","commit_id":"4628a6a94a7e5b82bf1d0c96a8dc6ea9a5f2f9f0"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"535db54c9c9edddfac73dedf3820ff86bf345780","unresolved":false,"context_lines":[{"line_number":39,"context_line":"In this process, there are some conditions that we could hit:"},{"line_number":40,"context_line":""},{"line_number":41,"context_line":"* The volume property no longer exists in Cinder."},{"line_number":42,"context_line":"* The volume create fails due to the project being over quota."},{"line_number":43,"context_line":"* The volume create could fail for some unknown reason, or it could"},{"line_number":44,"context_line":"  timeout (see how ComputeManager._await_block_device_map_created is used)."},{"line_number":45,"context_line":""}],"source_content_type":"text/x-rst","patch_set":5,"id":"df7087c5_fe4f0268","line":42,"updated":"2018-03-15 14:59:50.000000000","message":"This seems like an unfortunate restriction as rebuild is currently a way to change resources that you have, even if you\u0027re over quota already. Can cinder not re-image a volume? If not, are they interested in adding such a feature? Until that point, couldn\u0027t nova-compute do the re-imaging? That would be a more consistent workflow I think, although it would mean nova-compute doing more work.","commit_id":"4628a6a94a7e5b82bf1d0c96a8dc6ea9a5f2f9f0"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"535db54c9c9edddfac73dedf3820ff86bf345780","unresolved":false,"context_lines":[{"line_number":41,"context_line":"* The volume property no longer exists in Cinder."},{"line_number":42,"context_line":"* The volume create fails due to the project being over quota."},{"line_number":43,"context_line":"* The volume create could fail for some unknown reason, or it could"},{"line_number":44,"context_line":"  timeout (see how ComputeManager._await_block_device_map_created is used)."},{"line_number":45,"context_line":""},{"line_number":46,"context_line":"For those cases, we would just abort the rebuild operation, raise an exception"},{"line_number":47,"context_line":"in the compute manager which should log a fault for the instance, and the"}],"source_content_type":"text/x-rst","patch_set":5,"id":"df7087c5_3e49fa5e","line":44,"updated":"2018-03-15 14:59:50.000000000","message":"Another good reason not to create a new volume for this case, IMHO.","commit_id":"4628a6a94a7e5b82bf1d0c96a8dc6ea9a5f2f9f0"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"535db54c9c9edddfac73dedf3820ff86bf345780","unresolved":false,"context_lines":[{"line_number":51,"context_line":""},{"line_number":52,"context_line":"Add a \"delete_old_root_volume\" flag, if it is true, we will delete the old"},{"line_number":53,"context_line":"volume, else, retain the old volume.The flag default is true. This flag\u0027s"},{"line_number":54,"context_line":"priority is higher than the \"delete on termination\" flag."},{"line_number":55,"context_line":""},{"line_number":56,"context_line":"Alternatives"},{"line_number":57,"context_line":"------------"}],"source_content_type":"text/x-rst","patch_set":5,"id":"df7087c5_1ea196f8","line":54,"updated":"2018-03-15 14:59:50.000000000","message":"IMHO, rebuild implies losing the data in the original root disk, regardless of where it\u0027s held. I think we should just be consistent here and always delete/overwrite the original root volume.","commit_id":"4628a6a94a7e5b82bf1d0c96a8dc6ea9a5f2f9f0"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"f5690dcabbfbd48eb731afa9e952acb888a5b1cd","unresolved":false,"context_lines":[{"line_number":51,"context_line":""},{"line_number":52,"context_line":"Add a \"delete_old_root_volume\" flag, if it is true, we will delete the old"},{"line_number":53,"context_line":"volume, else, retain the old volume.The flag default is true. This flag\u0027s"},{"line_number":54,"context_line":"priority is higher than the \"delete on termination\" flag."},{"line_number":55,"context_line":""},{"line_number":56,"context_line":"Alternatives"},{"line_number":57,"context_line":"------------"}],"source_content_type":"text/x-rst","patch_set":5,"id":"df7087c5_fea382b0","line":54,"in_reply_to":"df7087c5_1ea196f8","updated":"2018-03-15 15:12:00.000000000","message":"There are a wide range of thoughts on this in the ML:\n\nhttp://lists.openstack.org/pipermail/openstack-operators/2018-March/014952.html\n\nWe should at least link to that thread in the References section below.","commit_id":"4628a6a94a7e5b82bf1d0c96a8dc6ea9a5f2f9f0"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"7daf61bea8f6301959f9e5edacd0a4d70b527c57","unresolved":false,"context_lines":[{"line_number":52,"context_line":"Add a \"delete_old_root_volume\" flag, if it is true, we will delete the old"},{"line_number":53,"context_line":"volume, else, retain the old volume.The flag default is true. This flag\u0027s"},{"line_number":54,"context_line":"priority is higher than the \"delete on termination\" flag."},{"line_number":55,"context_line":""},{"line_number":56,"context_line":"Alternatives"},{"line_number":57,"context_line":"------------"},{"line_number":58,"context_line":""}],"source_content_type":"text/x-rst","patch_set":5,"id":"df7087c5_21531b19","line":55,"updated":"2018-03-15 15:29:03.000000000","message":"Something else that came up in IRC today is, we need to consider the implications of multiattach volumes. You can have a multiattach volume as the root volume for a server, so what happens in that case?\n\nYou can\u0027t delete a multiattach volume while it has attachments to another server, and re-imaging it is questionable, unless maybe the other attachments are read-only? Which would make it dependent on this spec:\n\nhttps://review.openstack.org/#/c/552078/\n\nAlternatively, the API would just fail fast if the user is trying to re-image a volume-backed server with a multiattach volume as the root BDM when that volume is attached to \u003e1 server.","commit_id":"4628a6a94a7e5b82bf1d0c96a8dc6ea9a5f2f9f0"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"4cf4aba679e0ce5cc8ef6cb1dd652003fc2ac3e1","unresolved":false,"context_lines":[{"line_number":52,"context_line":"Add a \"delete_old_root_volume\" flag, if it is true, we will delete the old"},{"line_number":53,"context_line":"volume, else, retain the old volume.The flag default is true. This flag\u0027s"},{"line_number":54,"context_line":"priority is higher than the \"delete on termination\" flag."},{"line_number":55,"context_line":""},{"line_number":56,"context_line":"Alternatives"},{"line_number":57,"context_line":"------------"},{"line_number":58,"context_line":""}],"source_content_type":"text/x-rst","patch_set":5,"id":"df7087c5_a11f2b06","line":55,"in_reply_to":"df7087c5_21531b19","updated":"2018-03-15 15:40:40.000000000","message":"IMHO, just fail if \u003e1 attachments for the moment.","commit_id":"4628a6a94a7e5b82bf1d0c96a8dc6ea9a5f2f9f0"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"535db54c9c9edddfac73dedf3820ff86bf345780","unresolved":false,"context_lines":[{"line_number":69,"context_line":"Now nova rebuild the volume-backed instance as make it a fast failure in"},{"line_number":70,"context_line":"the API. If achieve this, we will change the rebuild request\u0027s response"},{"line_number":71,"context_line":"code from 400 to 202."},{"line_number":72,"context_line":"The compute API microversion is 2.61."},{"line_number":73,"context_line":"The compute rpc API version is 5.1."},{"line_number":74,"context_line":""},{"line_number":75,"context_line":"Security impact"},{"line_number":76,"context_line":"---------------"}],"source_content_type":"text/x-rst","patch_set":5,"id":"df7087c5_9eda8675","line":73,"range":{"start_line":72,"start_character":0,"end_line":73,"end_character":35},"updated":"2018-03-15 14:59:50.000000000","message":"It\u0027s unlikely that these will be the same when the code is merged. No reason to call them out here.","commit_id":"4628a6a94a7e5b82bf1d0c96a8dc6ea9a5f2f9f0"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"9a50c704eb7a0fba7d37ad5a075516c34b6bfffd","unresolved":false,"context_lines":[{"line_number":69,"context_line":"Now nova rebuild the volume-backed instance as make it a fast failure in"},{"line_number":70,"context_line":"the API. If achieve this, we will change the rebuild request\u0027s response"},{"line_number":71,"context_line":"code from 400 to 202."},{"line_number":72,"context_line":"The compute API microversion is 2.61."},{"line_number":73,"context_line":"The compute rpc API version is 5.1."},{"line_number":74,"context_line":""},{"line_number":75,"context_line":"Security impact"},{"line_number":76,"context_line":"---------------"}],"source_content_type":"text/x-rst","patch_set":5,"id":"df7087c5_3028b584","line":73,"range":{"start_line":72,"start_character":0,"end_line":73,"end_character":35},"in_reply_to":"df7087c5_7d761309","updated":"2018-03-21 20:53:22.000000000","message":"This has more information about how to actually code up a new microversion in the compute API:\n\nhttps://docs.openstack.org/nova/latest/contributor/microversions.html","commit_id":"4628a6a94a7e5b82bf1d0c96a8dc6ea9a5f2f9f0"},{"author":{"_account_id":27594,"name":"Jie Li","email":"lijie@unitedstack.com","username":"ramboman"},"change_message_id":"5992a5f918ebe491bc9e565030714941cd18da64","unresolved":false,"context_lines":[{"line_number":69,"context_line":"Now nova rebuild the volume-backed instance as make it a fast failure in"},{"line_number":70,"context_line":"the API. If achieve this, we will change the rebuild request\u0027s response"},{"line_number":71,"context_line":"code from 400 to 202."},{"line_number":72,"context_line":"The compute API microversion is 2.61."},{"line_number":73,"context_line":"The compute rpc API version is 5.1."},{"line_number":74,"context_line":""},{"line_number":75,"context_line":"Security impact"},{"line_number":76,"context_line":"---------------"}],"source_content_type":"text/x-rst","patch_set":5,"id":"df7087c5_c2fc1d40","line":73,"range":{"start_line":72,"start_character":0,"end_line":73,"end_character":35},"in_reply_to":"df7087c5_9eda8675","updated":"2018-03-21 11:52:23.000000000","message":"Sorry,I am a new openstack learner.Matt asked me to add a new compute API microversion in PS4,so I add these,Could you tell me how to do it?Thank you very much.","commit_id":"4628a6a94a7e5b82bf1d0c96a8dc6ea9a5f2f9f0"},{"author":{"_account_id":11904,"name":"Sean McGinnis","email":"sean.mcginnis@gmail.com","username":"SeanM"},"change_message_id":"1043dce8168b7663fbac5f9adb20eceec297f639","unresolved":false,"context_lines":[{"line_number":69,"context_line":"Now nova rebuild the volume-backed instance as make it a fast failure in"},{"line_number":70,"context_line":"the API. If achieve this, we will change the rebuild request\u0027s response"},{"line_number":71,"context_line":"code from 400 to 202."},{"line_number":72,"context_line":"The compute API microversion is 2.61."},{"line_number":73,"context_line":"The compute rpc API version is 5.1."},{"line_number":74,"context_line":""},{"line_number":75,"context_line":"Security impact"},{"line_number":76,"context_line":"---------------"}],"source_content_type":"text/x-rst","patch_set":5,"id":"df7087c5_7d761309","line":73,"range":{"start_line":72,"start_character":0,"end_line":73,"end_character":35},"in_reply_to":"df7087c5_c2fc1d40","updated":"2018-03-21 12:54:59.000000000","message":"I believe Dan\u0027s point is that by the time the code actually lands, there could be other changes that have since bumped the microversion and RPC API version. So do not specify those in the spec, just state that this will require raising them. The final code itself will be where the actual version is determined.","commit_id":"4628a6a94a7e5b82bf1d0c96a8dc6ea9a5f2f9f0"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"f5690dcabbfbd48eb731afa9e952acb888a5b1cd","unresolved":false,"context_lines":[{"line_number":95,"context_line":"Other deployer impact"},{"line_number":96,"context_line":"---------------------"},{"line_number":97,"context_line":""},{"line_number":98,"context_line":"None"},{"line_number":99,"context_line":""},{"line_number":100,"context_line":"Developer impact"},{"line_number":101,"context_line":"----------------"}],"source_content_type":"text/x-rst","patch_set":5,"id":"df7087c5_5ea62ead","line":98,"updated":"2018-03-15 15:12:00.000000000","message":"Replaying my comments from PS4:\n\nOne thing here is that even if the API says that it supports rebuilding volume-backed instances with a new image, if the compute host that the instance is running on is old (queens level code), then the rebuild isn\u0027t going to do anything. The API will cast to the compute and we won\u0027t change anything in the root disk, which is bug 1482040.\n\nWhat we\u0027d likely want/need to do is check the nova-compute service version for the host that the instance is running on. If the nova-compute service version is not new enough to support rebuilding volume-backed instances with a new image, then we need to fail the request in the API as we do today.\n\nThis should probably be explained in the \"proposed change\" section.","commit_id":"4628a6a94a7e5b82bf1d0c96a8dc6ea9a5f2f9f0"},{"author":{"_account_id":27594,"name":"Jie Li","email":"lijie@unitedstack.com","username":"ramboman"},"change_message_id":"5992a5f918ebe491bc9e565030714941cd18da64","unresolved":false,"context_lines":[{"line_number":95,"context_line":"Other deployer impact"},{"line_number":96,"context_line":"---------------------"},{"line_number":97,"context_line":""},{"line_number":98,"context_line":"None"},{"line_number":99,"context_line":""},{"line_number":100,"context_line":"Developer impact"},{"line_number":101,"context_line":"----------------"}],"source_content_type":"text/x-rst","patch_set":5,"id":"df7087c5_22acf933","line":98,"in_reply_to":"df7087c5_5ea62ead","updated":"2018-03-21 11:52:23.000000000","message":"ok,thank you very much！","commit_id":"4628a6a94a7e5b82bf1d0c96a8dc6ea9a5f2f9f0"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"535db54c9c9edddfac73dedf3820ff86bf345780","unresolved":false,"context_lines":[{"line_number":138,"context_line":"The following tests are added."},{"line_number":139,"context_line":""},{"line_number":140,"context_line":"* Nova unit tests"},{"line_number":141,"context_line":"* Nova functional tests"},{"line_number":142,"context_line":""},{"line_number":143,"context_line":"Documentation Impact"},{"line_number":144,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"}],"source_content_type":"text/x-rst","patch_set":5,"id":"df7087c5_becaea9d","line":141,"updated":"2018-03-15 14:59:50.000000000","message":"I would expect we\u0027d want tempest integration tests for this as well.","commit_id":"4628a6a94a7e5b82bf1d0c96a8dc6ea9a5f2f9f0"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"195165cd728392a391c4add5588d831853b31adc","unresolved":false,"context_lines":[{"line_number":138,"context_line":"The following tests are added."},{"line_number":139,"context_line":""},{"line_number":140,"context_line":"* Nova unit tests"},{"line_number":141,"context_line":"* Nova functional tests"},{"line_number":142,"context_line":""},{"line_number":143,"context_line":"Documentation Impact"},{"line_number":144,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"}],"source_content_type":"text/x-rst","patch_set":5,"id":"df7087c5_7efbf2bf","line":141,"in_reply_to":"df7087c5_becaea9d","updated":"2018-03-15 15:03:29.000000000","message":"Yes especially when it\u0027s across both nova and cinder services.","commit_id":"4628a6a94a7e5b82bf1d0c96a8dc6ea9a5f2f9f0"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"4423c8dbbfe9e47728fa55664f68ee20360fc8e8","unresolved":false,"context_lines":[{"line_number":51,"context_line":"instance should go back to it\u0027s original vm_state (ACTIVE, STOPPED or ERROR)."},{"line_number":52,"context_line":""},{"line_number":53,"context_line":"Update the root BDM to point to the new volume."},{"line_number":54,"context_line":""},{"line_number":55,"context_line":""},{"line_number":56,"context_line":"Alternatives"},{"line_number":57,"context_line":"------------"}],"source_content_type":"text/x-rst","patch_set":6,"id":"df7087c5_6ea612c4","line":54,"updated":"2018-03-23 15:27:57.000000000","message":"Per the ML discussion:\n\nhttp://lists.openstack.org/pipermail/openstack-operators/2018-March/014952.html\n\nYou need to mention something in here about what happens with the old volume. Does nova just leave it up to the user to delete it regardless of the \u0027delete_on_termination\u0027 flag?","commit_id":"56f43a4ed99656e5e743bb45c0d2e47c2d3078e8"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"4423c8dbbfe9e47728fa55664f68ee20360fc8e8","unresolved":false,"context_lines":[{"line_number":56,"context_line":"Alternatives"},{"line_number":57,"context_line":"------------"},{"line_number":58,"context_line":""},{"line_number":59,"context_line":"None"},{"line_number":60,"context_line":""},{"line_number":61,"context_line":"Data model impact"},{"line_number":62,"context_line":"-----------------"}],"source_content_type":"text/x-rst","patch_set":6,"id":"df7087c5_8e73664e","line":59,"updated":"2018-03-23 15:27:57.000000000","message":"In this section, you could/should discuss alternatives about how to handle the volume, from the ML thread, we at least talked about:\n\n1. Passing a new flag to the rebuild API telling nova what to do about the old volume (delete it or not).\n2. Rely on the delete_on_termination flag in the BDM to delete it or not - and if not, why not?\n3. Rely on a new Cinder API to re-image the existing volume.\n4. Re-image the existing volume locally in nova.\n\nFor each of those, if we aren\u0027t going to include those as part of the design, you should explain why that alternative wasn\u0027t chosen.","commit_id":"56f43a4ed99656e5e743bb45c0d2e47c2d3078e8"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"4423c8dbbfe9e47728fa55664f68ee20360fc8e8","unresolved":false,"context_lines":[{"line_number":67,"context_line":"---------------"},{"line_number":68,"context_line":""},{"line_number":69,"context_line":"Now nova rebuild the volume-backed instance as make it a fast failure in"},{"line_number":70,"context_line":"the API. If achieve this, we will change the rebuild request\u0027s response"},{"line_number":71,"context_line":"code from 400 to 202. Another this will need to raise the microversion"},{"line_number":72,"context_line":"and RPC API version."},{"line_number":73,"context_line":""}],"source_content_type":"text/x-rst","patch_set":6,"id":"df7087c5_ee70e274","line":70,"range":{"start_line":70,"start_character":9,"end_line":70,"end_character":25},"updated":"2018-03-23 15:27:57.000000000","message":"Remove this prelude.","commit_id":"56f43a4ed99656e5e743bb45c0d2e47c2d3078e8"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"4423c8dbbfe9e47728fa55664f68ee20360fc8e8","unresolved":false,"context_lines":[{"line_number":66,"context_line":"REST API impact"},{"line_number":67,"context_line":"---------------"},{"line_number":68,"context_line":""},{"line_number":69,"context_line":"Now nova rebuild the volume-backed instance as make it a fast failure in"},{"line_number":70,"context_line":"the API. If achieve this, we will change the rebuild request\u0027s response"},{"line_number":71,"context_line":"code from 400 to 202. Another this will need to raise the microversion"},{"line_number":72,"context_line":"and RPC API version."},{"line_number":73,"context_line":""}],"source_content_type":"text/x-rst","patch_set":6,"id":"df7087c5_ae4d0a3c","line":70,"range":{"start_line":69,"start_character":0,"end_line":70,"end_character":8},"updated":"2018-03-23 15:27:57.000000000","message":"Remove this sentence, it\u0027s already in the problem description.","commit_id":"56f43a4ed99656e5e743bb45c0d2e47c2d3078e8"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"4423c8dbbfe9e47728fa55664f68ee20360fc8e8","unresolved":false,"context_lines":[{"line_number":68,"context_line":""},{"line_number":69,"context_line":"Now nova rebuild the volume-backed instance as make it a fast failure in"},{"line_number":70,"context_line":"the API. If achieve this, we will change the rebuild request\u0027s response"},{"line_number":71,"context_line":"code from 400 to 202. Another this will need to raise the microversion"},{"line_number":72,"context_line":"and RPC API version."},{"line_number":73,"context_line":""},{"line_number":74,"context_line":"Security impact"},{"line_number":75,"context_line":"---------------"}],"source_content_type":"text/x-rst","patch_set":6,"id":"df7087c5_ae666aba","line":72,"range":{"start_line":71,"start_character":22,"end_line":72,"end_character":20},"updated":"2018-03-23 15:27:57.000000000","message":"Suggest re-wording this as, \"The REST API and compute RPC versoins will also be incremented to indicate the new support.\"","commit_id":"56f43a4ed99656e5e743bb45c0d2e47c2d3078e8"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"4423c8dbbfe9e47728fa55664f68ee20360fc8e8","unresolved":false,"context_lines":[{"line_number":149,"context_line":""},{"line_number":150,"context_line":"* API Reference"},{"line_number":151,"context_line":""},{"line_number":152,"context_line":"References"},{"line_number":153,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"},{"line_number":154,"context_line":""},{"line_number":155,"context_line":"* This is the discussion about rebuild the volume-backed server"}],"source_content_type":"text/x-rst","patch_set":6,"id":"df7087c5_ae142aea","line":152,"updated":"2018-03-23 15:27:57.000000000","message":"You should add a link to the ML discussion about what we should do about the volume during a rebuild (delete and create a new one? Re-image the volume within nova? Other?):\n\nhttp://lists.openstack.org/pipermail/openstack-operators/2018-March/014952.html","commit_id":"56f43a4ed99656e5e743bb45c0d2e47c2d3078e8"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"4423c8dbbfe9e47728fa55664f68ee20360fc8e8","unresolved":false,"context_lines":[{"line_number":155,"context_line":"* This is the discussion about rebuild the volume-backed server"},{"line_number":156,"context_line":"  http://lists.openstack.org/pipermail/openstack-dev/2017-October/123255.html"},{"line_number":157,"context_line":""},{"line_number":158,"context_line":"* This is the patch about rebuild"},{"line_number":159,"context_line":"  https://review.openstack.org/#/c/528740/"},{"line_number":160,"context_line":""},{"line_number":161,"context_line":"History"},{"line_number":162,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d"}],"source_content_type":"text/x-rst","patch_set":6,"id":"df7087c5_0e24365f","line":159,"range":{"start_line":158,"start_character":0,"end_line":159,"end_character":42},"updated":"2018-03-23 15:27:57.000000000","message":"You can remove this, it\u0027s linked from the blueprint in launchpad.","commit_id":"56f43a4ed99656e5e743bb45c0d2e47c2d3078e8"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"06828d37ff4e76952ae3fc9a53162836b620bb3d","unresolved":false,"context_lines":[{"line_number":71,"context_line":"  the instance. Rebuild means: re-initialize this instance in place. So"},{"line_number":72,"context_line":"  the \"delete_on_termination\" flag is no conflict about rebuild."},{"line_number":73,"context_line":""},{"line_number":74,"context_line":"* Rely on a new Cinder API to re-image the existing volume."},{"line_number":75,"context_line":"  The old root volume would be deleted and guarantee data loss for some users."},{"line_number":76,"context_line":""},{"line_number":77,"context_line":""}],"source_content_type":"text/x-rst","patch_set":7,"id":"3f79a3b5_c419917a","line":74,"range":{"start_line":74,"start_character":2,"end_line":74,"end_character":59},"updated":"2018-09-13 21:10:40.000000000","message":"We discussed this spec at the Stein PTG and this was the agreed upon solution, see the etherpad for details:\n\nhttps://etherpad.openstack.org/p/nova-ptg-stein\n\nI believe I also laid out, either in earlier review comments or a mailing list thread, what I thought we\u0027d do for this at a high level, which was essentially sort of like what we do with volumes during shelve/unshelve, something like:\n\n1. create an empty attachement for the root volume so the volume remains in-use during rebuild (we do this today already)\n2. delete the old volume attachment\n3. call the cinder API to re-image the volume\n4. update and complete the volume attachment once re-imaged\n\nThat way there is no new volume with a new volume id, we don\u0027t have to worry about types, we don\u0027t have to worry about quota, etc etc.","commit_id":"2bf80f9f69dffb87867168ca3b492750e6947d6c"},{"author":{"_account_id":27594,"name":"Jie Li","email":"lijie@unitedstack.com","username":"ramboman"},"change_message_id":"343b382df5f0fb0744ebfa397fcda05eeae71223","unresolved":false,"context_lines":[{"line_number":71,"context_line":"  the instance. Rebuild means: re-initialize this instance in place. So"},{"line_number":72,"context_line":"  the \"delete_on_termination\" flag is no conflict about rebuild."},{"line_number":73,"context_line":""},{"line_number":74,"context_line":"* Rely on a new Cinder API to re-image the existing volume."},{"line_number":75,"context_line":"  The old root volume would be deleted and guarantee data loss for some users."},{"line_number":76,"context_line":""},{"line_number":77,"context_line":""}],"source_content_type":"text/x-rst","patch_set":7,"id":"3f79a3b5_e0aa7618","line":74,"range":{"start_line":74,"start_character":2,"end_line":74,"end_character":59},"in_reply_to":"3f79a3b5_c419917a","updated":"2018-09-14 01:10:04.000000000","message":"great","commit_id":"2bf80f9f69dffb87867168ca3b492750e6947d6c"},{"author":{"_account_id":27615,"name":"Rajat Dhasmana","email":"rajatdhasmana@gmail.com","username":"whoami-rajat"},"change_message_id":"380f1bea3c2f2a437d17d989a9d0e84ed1e63fe8","unresolved":false,"context_lines":[{"line_number":84,"context_line":"---------------"},{"line_number":85,"context_line":""},{"line_number":86,"context_line":"Change the rebuild request\u0027s response code from 400 to 202."},{"line_number":87,"context_line":"The REST API and compute RPC versoins will also be incremented to"},{"line_number":88,"context_line":"indicate the new support."},{"line_number":89,"context_line":""},{"line_number":90,"context_line":"Security impact"}],"source_content_type":"text/x-rst","patch_set":7,"id":"3f79a3b5_62daf81d","line":87,"range":{"start_line":87,"start_character":29,"end_line":87,"end_character":37},"updated":"2018-09-13 15:16:40.000000000","message":"versions","commit_id":"2bf80f9f69dffb87867168ca3b492750e6947d6c"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"06828d37ff4e76952ae3fc9a53162836b620bb3d","unresolved":false,"context_lines":[{"line_number":184,"context_line":""},{"line_number":185,"context_line":"   * - Release Name"},{"line_number":186,"context_line":"     - Description"},{"line_number":187,"context_line":"   * - Rocky"},{"line_number":188,"context_line":"     - Introduced"}],"source_content_type":"text/x-rst","patch_set":7,"id":"3f79a3b5_e9a34842","line":187,"updated":"2018-09-13 21:10:40.000000000","message":"Need to move this to Stein now.","commit_id":"2bf80f9f69dffb87867168ca3b492750e6947d6c"}],"specs/stein/approved/volume-backed-server-rebuild.rst":[{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"4a49f969241e6dc676dd63ad5a985baeebd3b764","unresolved":false,"context_lines":[{"line_number":17,"context_line":"Problem description"},{"line_number":18,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"},{"line_number":19,"context_line":""},{"line_number":20,"context_line":"Currently Nova rebuild is only supports instances which are booted from"},{"line_number":21,"context_line":"images. The volume-backed instance cannot be rebuilt when a new image"},{"line_number":22,"context_line":"is supplied. Trying to rebuild a volume-backed instance will raise a"},{"line_number":23,"context_line":"HTTPBadRequest exception."}],"source_content_type":"text/x-rst","patch_set":9,"id":"3f79a3b5_b5e5d3dd","line":20,"range":{"start_line":20,"start_character":23,"end_line":20,"end_character":25},"updated":"2018-10-18 16:09:56.000000000","message":"remove this word","commit_id":"0be1231b083c5d41b04ef5e7b61a472beb833615"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"4a49f969241e6dc676dd63ad5a985baeebd3b764","unresolved":false,"context_lines":[{"line_number":25,"context_line":"Use Cases"},{"line_number":26,"context_line":"---------"},{"line_number":27,"context_line":""},{"line_number":28,"context_line":"When user need to rebuild the volume-backed server with a new image."},{"line_number":29,"context_line":""},{"line_number":30,"context_line":"Proposed change"},{"line_number":31,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"}],"source_content_type":"text/x-rst","patch_set":9,"id":"3f79a3b5_f504ab7f","line":28,"range":{"start_line":28,"start_character":10,"end_line":28,"end_character":14},"updated":"2018-10-18 16:09:56.000000000","message":"needs","commit_id":"0be1231b083c5d41b04ef5e7b61a472beb833615"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"4a49f969241e6dc676dd63ad5a985baeebd3b764","unresolved":false,"context_lines":[{"line_number":34,"context_line":"the compute manager will do similar to how boot from volume works where"},{"line_number":35,"context_line":"the BDM source_type is \u0027image\u0027 or \u0027snapshot\u0027. Add a new method for"},{"line_number":36,"context_line":"compute manager which will be called \u0027_update_root_volume\u0027, this method"},{"line_number":37,"context_line":"will first delete the old volume attachment, and then call the cinder"},{"line_number":38,"context_line":"API to re-image the volume, after the re-image api is complete, at once"},{"line_number":39,"context_line":"update and complete the volume attachment. In this process, there is a"},{"line_number":40,"context_line":"condition that we could hit:"}],"source_content_type":"text/x-rst","patch_set":9,"id":"3f79a3b5_f5bcab6c","line":37,"range":{"start_line":37,"start_character":0,"end_line":37,"end_character":43},"updated":"2018-10-18 16:09:56.000000000","message":"Well, this is an implementation detail, but we\u0027ll delete the old volume attachment only after we\u0027ve created a new empty attachment record to keep the volume status as \"reserved\" while we\u0027re re-imaging the volume. Luckily rebuild already does this for us:\n\nhttps://github.com/openstack/nova/blob/ce520ee789bf6a46f56de86769d74c095ce432cf/nova/compute/manager.py#L3205-L3216","commit_id":"0be1231b083c5d41b04ef5e7b61a472beb833615"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"4a49f969241e6dc676dd63ad5a985baeebd3b764","unresolved":false,"context_lines":[{"line_number":36,"context_line":"compute manager which will be called \u0027_update_root_volume\u0027, this method"},{"line_number":37,"context_line":"will first delete the old volume attachment, and then call the cinder"},{"line_number":38,"context_line":"API to re-image the volume, after the re-image api is complete, at once"},{"line_number":39,"context_line":"update and complete the volume attachment. In this process, there is a"},{"line_number":40,"context_line":"condition that we could hit:"},{"line_number":41,"context_line":""},{"line_number":42,"context_line":"* The nova-compute service version for the host that the instance is running"},{"line_number":43,"context_line":"  on is old (rocky level code)."}],"source_content_type":"text/x-rst","patch_set":9,"id":"3f79a3b5_95553755","line":40,"range":{"start_line":39,"start_character":43,"end_line":40,"end_character":28},"updated":"2018-10-18 16:09:56.000000000","message":"Another condition is that cinder API has not been upgraded yet so the new microversion to re-image the volume is not available. You should document that here as well. Note that we could also check this in the API if wanted to along with the compute service version below, like we do here:\n\nhttps://github.com/openstack/nova/blob/ce520ee789bf6a46f56de86769d74c095ce432cf/nova/compute/api.py#L4154","commit_id":"0be1231b083c5d41b04ef5e7b61a472beb833615"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"4a49f969241e6dc676dd63ad5a985baeebd3b764","unresolved":false,"context_lines":[{"line_number":39,"context_line":"update and complete the volume attachment. In this process, there is a"},{"line_number":40,"context_line":"condition that we could hit:"},{"line_number":41,"context_line":""},{"line_number":42,"context_line":"* The nova-compute service version for the host that the instance is running"},{"line_number":43,"context_line":"  on is old (rocky level code)."},{"line_number":44,"context_line":""},{"line_number":45,"context_line":"For this case, we would just abort the rebuild operation, raise an exception"},{"line_number":46,"context_line":"in the compute manager which should log a fault for the instance, and the"}],"source_content_type":"text/x-rst","patch_set":9,"id":"3f79a3b5_b58153c5","line":43,"range":{"start_line":42,"start_character":0,"end_line":43,"end_character":31},"updated":"2018-10-18 16:09:56.000000000","message":"Well, the API would need to check this and return a 409 I think. So the API flow would be:\n\n1. is there a new image\n2. is the instance volume-backed\n3. has the new microversion been requested\n4. is the instance.host service version new enough to support volume-backed rebuild with a new image\n4a. if yes, proceed\n4b. if not, fail in the API with a 409 error\n\nI think a 409 is more appropriate over a 400 here because retrying later might pass once the compute is upgraded. It\u0027s similar to this error:\n\nhttps://github.com/openstack/nova/blob/ce520ee789bf6a46f56de86769d74c095ce432cf/nova/exception.py#L273","commit_id":"0be1231b083c5d41b04ef5e7b61a472beb833615"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"a0b07264abdeb9b39a3bf15d5c6f7a780912c9cf","unresolved":false,"context_lines":[{"line_number":39,"context_line":"update and complete the volume attachment. In this process, there is a"},{"line_number":40,"context_line":"condition that we could hit:"},{"line_number":41,"context_line":""},{"line_number":42,"context_line":"* The nova-compute service version for the host that the instance is running"},{"line_number":43,"context_line":"  on is old (rocky level code)."},{"line_number":44,"context_line":""},{"line_number":45,"context_line":"For this case, we would just abort the rebuild operation, raise an exception"},{"line_number":46,"context_line":"in the compute manager which should log a fault for the instance, and the"}],"source_content_type":"text/x-rst","patch_set":9,"id":"3f79a3b5_01850d59","line":43,"range":{"start_line":42,"start_character":0,"end_line":43,"end_character":31},"in_reply_to":"3f79a3b5_499fdcb2","updated":"2018-10-23 22:16:32.000000000","message":"Because the only limitation today with rebuilding a volume-backed server is when the underlying image changes in the root volume - the API allows volume-backed server rebuild today otherwise. So we don\u0027t need any of the validation logic if the image isn\u0027t changing. In other words, this code:\n\nhttps://github.com/openstack/nova/blob/297de7fb9fbabe74b5305ef0aa82e196d5f48d5e/nova/compute/api.py#L3200","commit_id":"0be1231b083c5d41b04ef5e7b61a472beb833615"},{"author":{"_account_id":27594,"name":"Jie Li","email":"lijie@unitedstack.com","username":"ramboman"},"change_message_id":"c6eb4eb7c54e170f95e1a4caabc12adc09e5948f","unresolved":false,"context_lines":[{"line_number":39,"context_line":"update and complete the volume attachment. In this process, there is a"},{"line_number":40,"context_line":"condition that we could hit:"},{"line_number":41,"context_line":""},{"line_number":42,"context_line":"* The nova-compute service version for the host that the instance is running"},{"line_number":43,"context_line":"  on is old (rocky level code)."},{"line_number":44,"context_line":""},{"line_number":45,"context_line":"For this case, we would just abort the rebuild operation, raise an exception"},{"line_number":46,"context_line":"in the compute manager which should log a fault for the instance, and the"}],"source_content_type":"text/x-rst","patch_set":9,"id":"3f79a3b5_499fdcb2","line":43,"range":{"start_line":42,"start_character":0,"end_line":43,"end_character":31},"in_reply_to":"3f79a3b5_a9fc700b","updated":"2018-10-22 11:47:41.000000000","message":"I think we should\u0027t limit the image there.","commit_id":"0be1231b083c5d41b04ef5e7b61a472beb833615"},{"author":{"_account_id":27594,"name":"Jie Li","email":"lijie@unitedstack.com","username":"ramboman"},"change_message_id":"c5e41c8f12490f83b63c4b94b4bca2e02d574523","unresolved":false,"context_lines":[{"line_number":39,"context_line":"update and complete the volume attachment. In this process, there is a"},{"line_number":40,"context_line":"condition that we could hit:"},{"line_number":41,"context_line":""},{"line_number":42,"context_line":"* The nova-compute service version for the host that the instance is running"},{"line_number":43,"context_line":"  on is old (rocky level code)."},{"line_number":44,"context_line":""},{"line_number":45,"context_line":"For this case, we would just abort the rebuild operation, raise an exception"},{"line_number":46,"context_line":"in the compute manager which should log a fault for the instance, and the"}],"source_content_type":"text/x-rst","patch_set":9,"id":"3f79a3b5_a9fc700b","line":43,"range":{"start_line":42,"start_character":0,"end_line":43,"end_character":31},"in_reply_to":"3f79a3b5_b58153c5","updated":"2018-10-22 09:34:14.000000000","message":"why there must be a new image?","commit_id":"0be1231b083c5d41b04ef5e7b61a472beb833615"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"4a49f969241e6dc676dd63ad5a985baeebd3b764","unresolved":false,"context_lines":[{"line_number":57,"context_line":"  snapshots, Nova won\u0027t be deleting the volume snapshots just to delete"},{"line_number":58,"context_line":"  the volume during a rebuild."},{"line_number":59,"context_line":""},{"line_number":60,"context_line":"* Regardless of the \u0027delete_on_termination\u0027 flag in the BDM.The"},{"line_number":61,"context_line":"  delete_on_termination means: don\u0027t delete the volume when we kill"},{"line_number":62,"context_line":"  the instance. Rebuild means: re-initialize this instance in place. So"},{"line_number":63,"context_line":"  the \"delete_on_termination\" flag is no conflict about rebuild, The old"}],"source_content_type":"text/x-rst","patch_set":9,"id":"3f79a3b5_d55c0f5a","line":60,"range":{"start_line":60,"start_character":59,"end_line":60,"end_character":61},"updated":"2018-10-18 16:09:56.000000000","message":"space","commit_id":"0be1231b083c5d41b04ef5e7b61a472beb833615"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"4a49f969241e6dc676dd63ad5a985baeebd3b764","unresolved":false,"context_lines":[{"line_number":60,"context_line":"* Regardless of the \u0027delete_on_termination\u0027 flag in the BDM.The"},{"line_number":61,"context_line":"  delete_on_termination means: don\u0027t delete the volume when we kill"},{"line_number":62,"context_line":"  the instance. Rebuild means: re-initialize this instance in place. So"},{"line_number":63,"context_line":"  the \"delete_on_termination\" flag is no conflict about rebuild, The old"},{"line_number":64,"context_line":"  root volume just leave it up to the user to delete it."},{"line_number":65,"context_line":""},{"line_number":66,"context_line":"Data model impact"}],"source_content_type":"text/x-rst","patch_set":9,"id":"3f79a3b5_d545ef73","line":63,"range":{"start_line":63,"start_character":63,"end_line":63,"end_character":66},"updated":"2018-10-18 16:09:56.000000000","message":", the","commit_id":"0be1231b083c5d41b04ef5e7b61a472beb833615"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"4a49f969241e6dc676dd63ad5a985baeebd3b764","unresolved":false,"context_lines":[{"line_number":62,"context_line":"  the instance. Rebuild means: re-initialize this instance in place. So"},{"line_number":63,"context_line":"  the \"delete_on_termination\" flag is no conflict about rebuild, The old"},{"line_number":64,"context_line":"  root volume just leave it up to the user to delete it."},{"line_number":65,"context_line":""},{"line_number":66,"context_line":"Data model impact"},{"line_number":67,"context_line":"-----------------"},{"line_number":68,"context_line":""}],"source_content_type":"text/x-rst","patch_set":9,"id":"3f79a3b5_75565b2e","line":65,"updated":"2018-10-18 16:09:56.000000000","message":"You might want to mention the reasons why we didn\u0027t go with the alternative, which include quota issues in cinder, failures to create the new volume, the delete_on_termination semantics, etc. It\u0027s essentially just more orchestration than we really want/need to do for this.","commit_id":"0be1231b083c5d41b04ef5e7b61a472beb833615"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"4a49f969241e6dc676dd63ad5a985baeebd3b764","unresolved":false,"context_lines":[{"line_number":72,"context_line":"---------------"},{"line_number":73,"context_line":""},{"line_number":74,"context_line":"Change the rebuild request\u0027s response code from 400 to 202."},{"line_number":75,"context_line":"The REST API and compute RPC versions will also be incremented to"},{"line_number":76,"context_line":"indicate the new support."},{"line_number":77,"context_line":""},{"line_number":78,"context_line":"Security impact"}],"source_content_type":"text/x-rst","patch_set":9,"id":"3f79a3b5_953457fc","line":75,"range":{"start_line":75,"start_character":4,"end_line":75,"end_character":12},"updated":"2018-10-18 16:09:56.000000000","message":"A microversion will be added to the rebuild API so users will have to opt into this behavior.","commit_id":"0be1231b083c5d41b04ef5e7b61a472beb833615"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"4a49f969241e6dc676dd63ad5a985baeebd3b764","unresolved":false,"context_lines":[{"line_number":85,"context_line":""},{"line_number":86,"context_line":"None"},{"line_number":87,"context_line":""},{"line_number":88,"context_line":"Other end user impact"},{"line_number":89,"context_line":"---------------------"},{"line_number":90,"context_line":""},{"line_number":91,"context_line":"User can provide any format image to rebuild the volume-backed server."}],"source_content_type":"text/x-rst","patch_set":9,"id":"3f79a3b5_185dde15","line":88,"updated":"2018-10-18 16:09:56.000000000","message":"Just need to mention that python-novaclient will be updated to support the new microversion.","commit_id":"0be1231b083c5d41b04ef5e7b61a472beb833615"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"4a49f969241e6dc676dd63ad5a985baeebd3b764","unresolved":false,"context_lines":[{"line_number":93,"context_line":"Performance Impact"},{"line_number":94,"context_line":"------------------"},{"line_number":95,"context_line":""},{"line_number":96,"context_line":"None"},{"line_number":97,"context_line":""},{"line_number":98,"context_line":"Other deployer impact"},{"line_number":99,"context_line":"---------------------"}],"source_content_type":"text/x-rst","patch_set":9,"id":"3f79a3b5_f874a29d","line":96,"updated":"2018-10-18 16:09:56.000000000","message":"I would mention that rebuilding a volume-backed server with a new image will take longer because of the orchestration involved and the work that needs to happen in Cinder, but that should outweigh the inability to perform that operation at all.","commit_id":"0be1231b083c5d41b04ef5e7b61a472beb833615"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"4a49f969241e6dc676dd63ad5a985baeebd3b764","unresolved":false,"context_lines":[{"line_number":123,"context_line":"Work Items"},{"line_number":124,"context_line":"----------"},{"line_number":125,"context_line":""},{"line_number":126,"context_line":"* Create an empty attachment for the root volume so the volume remains"},{"line_number":127,"context_line":"  in-use during rebuild (we do this today already)"},{"line_number":128,"context_line":"* Delete the old volume attachment"},{"line_number":129,"context_line":"* Call the cinder API to re-image the volume"},{"line_number":130,"context_line":"* Update and complete the volume attachment once re-imaged"},{"line_number":131,"context_line":"* Change API documents"},{"line_number":132,"context_line":""},{"line_number":133,"context_line":"Dependencies"}],"source_content_type":"text/x-rst","patch_set":9,"id":"3f79a3b5_78a5f200","line":130,"range":{"start_line":126,"start_character":0,"end_line":130,"end_character":58},"updated":"2018-10-18 16:09:56.000000000","message":"These are good, and are the nova-compute service changes that need to be made, but you\u0027re missing any mention of the API logic that needs to change, along with the new microversion.","commit_id":"0be1231b083c5d41b04ef5e7b61a472beb833615"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"4a49f969241e6dc676dd63ad5a985baeebd3b764","unresolved":false,"context_lines":[{"line_number":133,"context_line":"Dependencies"},{"line_number":134,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"},{"line_number":135,"context_line":""},{"line_number":136,"context_line":"None"},{"line_number":137,"context_line":""},{"line_number":138,"context_line":""},{"line_number":139,"context_line":"Testing"}],"source_content_type":"text/x-rst","patch_set":9,"id":"3f79a3b5_f8826251","line":136,"updated":"2018-10-18 16:09:56.000000000","message":"Clearly the cinder blueprint for re-imaging a volume is a dependency:\n\nhttps://blueprints.launchpad.net/cinder/+spec/add-volume-re-image-api","commit_id":"0be1231b083c5d41b04ef5e7b61a472beb833615"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"4a49f969241e6dc676dd63ad5a985baeebd3b764","unresolved":false,"context_lines":[{"line_number":177,"context_line":""},{"line_number":178,"context_line":"   * - Release Name"},{"line_number":179,"context_line":"     - Description"},{"line_number":180,"context_line":"   * - Rocky"},{"line_number":181,"context_line":"     - Introduced"},{"line_number":182,"context_line":"   * - Stein"},{"line_number":183,"context_line":"     - Re-proposed"}],"source_content_type":"text/x-rst","patch_set":9,"id":"3f79a3b5_5891169b","line":183,"range":{"start_line":180,"start_character":0,"end_line":183,"end_character":18},"updated":"2018-10-18 16:09:56.000000000","message":"This should just be Stein since the spec wasn\u0027t approved in Rocky.","commit_id":"0be1231b083c5d41b04ef5e7b61a472beb833615"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"1cdf194108dbae0eb640b1a36038aa06889bb8c5","unresolved":false,"context_lines":[{"line_number":30,"context_line":"Proposed change"},{"line_number":31,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"},{"line_number":32,"context_line":""},{"line_number":33,"context_line":"Change existing API for rebuild the volume-backed server firstly."},{"line_number":34,"context_line":"Then the API flow would be:"},{"line_number":35,"context_line":""},{"line_number":36,"context_line":"1. The server is the instance volume-backed server."}],"source_content_type":"text/x-rst","patch_set":10,"id":"3f79a3b5_7806f923","line":33,"range":{"start_line":33,"start_character":0,"end_line":33,"end_character":65},"updated":"2018-11-28 17:56:46.000000000","message":"What does this mean?","commit_id":"87f299fbe4d0a5342d938a3bb5e63337e497fdd4"},{"author":{"_account_id":15888,"name":"Zhenyu Zheng","email":"zheng.zhenyu@outlook.com","username":"Kevin_Zheng"},"change_message_id":"511257e2dbb5ce9d7a5a5d3defb36d35feb71931","unresolved":false,"context_lines":[{"line_number":33,"context_line":"Change existing API for rebuild the volume-backed server firstly."},{"line_number":34,"context_line":"Then the API flow would be:"},{"line_number":35,"context_line":""},{"line_number":36,"context_line":"1. The server is the instance volume-backed server."},{"line_number":37,"context_line":"2. Is the new microversion been requested."},{"line_number":38,"context_line":"3. Is the instance.host service version new enough to support"},{"line_number":39,"context_line":"   volume-backed rebuild with a new image."}],"source_content_type":"text/x-rst","patch_set":10,"id":"3f79a3b5_773c6390","line":36,"range":{"start_line":36,"start_character":3,"end_line":36,"end_character":51},"updated":"2018-10-29 09:12:41.000000000","message":"Whether the server is an volume-backed instance or not.","commit_id":"87f299fbe4d0a5342d938a3bb5e63337e497fdd4"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"1cdf194108dbae0eb640b1a36038aa06889bb8c5","unresolved":false,"context_lines":[{"line_number":38,"context_line":"3. Is the instance.host service version new enough to support"},{"line_number":39,"context_line":"   volume-backed rebuild with a new image."},{"line_number":40,"context_line":""},{"line_number":41,"context_line":"If these are yes, proceed.If not, fail in the API with a 409 error, and the"},{"line_number":42,"context_line":"instance should go back to it\u0027s original vm_state (ACTIVE, STOPPED or ERROR)."},{"line_number":43,"context_line":""},{"line_number":44,"context_line":"Then the compute manager will do similar to how boot from volume works where"}],"source_content_type":"text/x-rst","patch_set":10,"id":"3f79a3b5_d3fa8e0f","line":41,"range":{"start_line":41,"start_character":26,"end_line":41,"end_character":28},"updated":"2018-11-28 17:56:46.000000000","message":"Need an extra space here.","commit_id":"87f299fbe4d0a5342d938a3bb5e63337e497fdd4"},{"author":{"_account_id":15888,"name":"Zhenyu Zheng","email":"zheng.zhenyu@outlook.com","username":"Kevin_Zheng"},"change_message_id":"511257e2dbb5ce9d7a5a5d3defb36d35feb71931","unresolved":false,"context_lines":[{"line_number":38,"context_line":"3. Is the instance.host service version new enough to support"},{"line_number":39,"context_line":"   volume-backed rebuild with a new image."},{"line_number":40,"context_line":""},{"line_number":41,"context_line":"If these are yes, proceed.If not, fail in the API with a 409 error, and the"},{"line_number":42,"context_line":"instance should go back to it\u0027s original vm_state (ACTIVE, STOPPED or ERROR)."},{"line_number":43,"context_line":""},{"line_number":44,"context_line":"Then the compute manager will do similar to how boot from volume works where"}],"source_content_type":"text/x-rst","patch_set":10,"id":"3f79a3b5_d74c5741","line":41,"range":{"start_line":41,"start_character":13,"end_line":41,"end_character":16},"updated":"2018-10-29 09:12:41.000000000","message":"True","commit_id":"87f299fbe4d0a5342d938a3bb5e63337e497fdd4"},{"author":{"_account_id":15888,"name":"Zhenyu Zheng","email":"zheng.zhenyu@outlook.com","username":"Kevin_Zheng"},"change_message_id":"511257e2dbb5ce9d7a5a5d3defb36d35feb71931","unresolved":false,"context_lines":[{"line_number":38,"context_line":"3. Is the instance.host service version new enough to support"},{"line_number":39,"context_line":"   volume-backed rebuild with a new image."},{"line_number":40,"context_line":""},{"line_number":41,"context_line":"If these are yes, proceed.If not, fail in the API with a 409 error, and the"},{"line_number":42,"context_line":"instance should go back to it\u0027s original vm_state (ACTIVE, STOPPED or ERROR)."},{"line_number":43,"context_line":""},{"line_number":44,"context_line":"Then the compute manager will do similar to how boot from volume works where"}],"source_content_type":"text/x-rst","patch_set":10,"id":"3f79a3b5_975c9ff0","line":41,"range":{"start_line":41,"start_character":25,"end_line":41,"end_character":26},"updated":"2018-10-29 09:12:41.000000000","message":"space","commit_id":"87f299fbe4d0a5342d938a3bb5e63337e497fdd4"},{"author":{"_account_id":27594,"name":"Jie Li","email":"lijie@unitedstack.com","username":"ramboman"},"change_message_id":"303e26d30694e9dc645594b7665ae48add16059c","unresolved":false,"context_lines":[{"line_number":38,"context_line":"3. Is the instance.host service version new enough to support"},{"line_number":39,"context_line":"   volume-backed rebuild with a new image."},{"line_number":40,"context_line":""},{"line_number":41,"context_line":"If these are yes, proceed.If not, fail in the API with a 409 error, and the"},{"line_number":42,"context_line":"instance should go back to it\u0027s original vm_state (ACTIVE, STOPPED or ERROR)."},{"line_number":43,"context_line":""},{"line_number":44,"context_line":"Then the compute manager will do similar to how boot from volume works where"}],"source_content_type":"text/x-rst","patch_set":10,"id":"3f79a3b5_51ed56ff","line":41,"range":{"start_line":41,"start_character":13,"end_line":41,"end_character":16},"in_reply_to":"3f79a3b5_d74c5741","updated":"2018-11-02 09:27:09.000000000","message":"Done.","commit_id":"87f299fbe4d0a5342d938a3bb5e63337e497fdd4"},{"author":{"_account_id":20722,"name":"Yikun Jiang","email":"yikunkero@gmail.com","username":"yikunkero"},"change_message_id":"4f12c2daafdeb6aa8749864a5aebbae97432a525","unresolved":false,"context_lines":[{"line_number":39,"context_line":"   volume-backed rebuild with a new image."},{"line_number":40,"context_line":""},{"line_number":41,"context_line":"If these are yes, proceed.If not, fail in the API with a 409 error, and the"},{"line_number":42,"context_line":"instance should go back to it\u0027s original vm_state (ACTIVE, STOPPED or ERROR)."},{"line_number":43,"context_line":""},{"line_number":44,"context_line":"Then the compute manager will do similar to how boot from volume works where"},{"line_number":45,"context_line":"the BDM source_type is \u0027image\u0027 or \u0027snapshot\u0027. We will judge the server"}],"source_content_type":"text/x-rst","patch_set":10,"id":"3f79a3b5_fa582f26","line":42,"range":{"start_line":42,"start_character":16,"end_line":42,"end_character":77},"updated":"2018-10-31 06:17:20.000000000","message":"I think we haven\u0027t changed the vm_sate yet before api checking passed...","commit_id":"87f299fbe4d0a5342d938a3bb5e63337e497fdd4"},{"author":{"_account_id":27594,"name":"Jie Li","email":"lijie@unitedstack.com","username":"ramboman"},"change_message_id":"303e26d30694e9dc645594b7665ae48add16059c","unresolved":false,"context_lines":[{"line_number":39,"context_line":"   volume-backed rebuild with a new image."},{"line_number":40,"context_line":""},{"line_number":41,"context_line":"If these are yes, proceed.If not, fail in the API with a 409 error, and the"},{"line_number":42,"context_line":"instance should go back to it\u0027s original vm_state (ACTIVE, STOPPED or ERROR)."},{"line_number":43,"context_line":""},{"line_number":44,"context_line":"Then the compute manager will do similar to how boot from volume works where"},{"line_number":45,"context_line":"the BDM source_type is \u0027image\u0027 or \u0027snapshot\u0027. We will judge the server"}],"source_content_type":"text/x-rst","patch_set":10,"id":"3f79a3b5_d12ac62c","line":42,"range":{"start_line":42,"start_character":16,"end_line":42,"end_character":77},"in_reply_to":"3f79a3b5_fa582f26","updated":"2018-11-02 09:27:09.000000000","message":"Yes, you are right. Sorry about it.","commit_id":"87f299fbe4d0a5342d938a3bb5e63337e497fdd4"},{"author":{"_account_id":20722,"name":"Yikun Jiang","email":"yikunkero@gmail.com","username":"yikunkero"},"change_message_id":"4f12c2daafdeb6aa8749864a5aebbae97432a525","unresolved":false,"context_lines":[{"line_number":46,"context_line":"if is a volume-backed server. Add a new method for compute manager which"},{"line_number":47,"context_line":"will be called \u0027_update_root_volume\u0027, this method will first check that"},{"line_number":48,"context_line":"the given image whether it is a \"volume-backed server image\". If the size"},{"line_number":49,"context_line":"is equal 0, the given image is \"volume-backed server image\", otherwise is"},{"line_number":50,"context_line":"the \"image-backed server image\", and then call the cinder API to re-image"},{"line_number":51,"context_line":"the volume, after the re-image api is complete, at once update and complete"},{"line_number":52,"context_line":"the volume attachment."}],"source_content_type":"text/x-rst","patch_set":10,"id":"3f79a3b5_75a2f0fd","line":49,"range":{"start_line":49,"start_character":0,"end_line":49,"end_character":10},"updated":"2018-10-31 06:17:20.000000000","message":"volume backed image\u0027s location url is startswith \"cinder://\", so using size in here is not the way we wanted.\n\n[1] https://docs.openstack.org/cinder/latest/admin/blockstorage-volume-backed-image.html","commit_id":"87f299fbe4d0a5342d938a3bb5e63337e497fdd4"},{"author":{"_account_id":27594,"name":"Jie Li","email":"lijie@unitedstack.com","username":"ramboman"},"change_message_id":"303e26d30694e9dc645594b7665ae48add16059c","unresolved":false,"context_lines":[{"line_number":46,"context_line":"if is a volume-backed server. Add a new method for compute manager which"},{"line_number":47,"context_line":"will be called \u0027_update_root_volume\u0027, this method will first check that"},{"line_number":48,"context_line":"the given image whether it is a \"volume-backed server image\". If the size"},{"line_number":49,"context_line":"is equal 0, the given image is \"volume-backed server image\", otherwise is"},{"line_number":50,"context_line":"the \"image-backed server image\", and then call the cinder API to re-image"},{"line_number":51,"context_line":"the volume, after the re-image api is complete, at once update and complete"},{"line_number":52,"context_line":"the volume attachment."}],"source_content_type":"text/x-rst","patch_set":10,"id":"3f79a3b5_f1702244","line":49,"range":{"start_line":49,"start_character":0,"end_line":49,"end_character":10},"in_reply_to":"3f79a3b5_75a2f0fd","updated":"2018-11-02 09:27:09.000000000","message":"Good idea, thank you very much.","commit_id":"87f299fbe4d0a5342d938a3bb5e63337e497fdd4"},{"author":{"_account_id":15888,"name":"Zhenyu Zheng","email":"zheng.zhenyu@outlook.com","username":"Kevin_Zheng"},"change_message_id":"511257e2dbb5ce9d7a5a5d3defb36d35feb71931","unresolved":false,"context_lines":[{"line_number":46,"context_line":"if is a volume-backed server. Add a new method for compute manager which"},{"line_number":47,"context_line":"will be called \u0027_update_root_volume\u0027, this method will first check that"},{"line_number":48,"context_line":"the given image whether it is a \"volume-backed server image\". If the size"},{"line_number":49,"context_line":"is equal 0, the given image is \"volume-backed server image\", otherwise is"},{"line_number":50,"context_line":"the \"image-backed server image\", and then call the cinder API to re-image"},{"line_number":51,"context_line":"the volume, after the re-image api is complete, at once update and complete"},{"line_number":52,"context_line":"the volume attachment."},{"line_number":53,"context_line":""}],"source_content_type":"text/x-rst","patch_set":10,"id":"3f79a3b5_b7d2fb31","line":50,"range":{"start_line":49,"start_character":31,"end_line":50,"end_character":32},"updated":"2018-10-29 09:12:41.000000000","message":"Are we only talk about the \"instance snapshot\" here? Could it be a normal image?","commit_id":"87f299fbe4d0a5342d938a3bb5e63337e497fdd4"},{"author":{"_account_id":27594,"name":"Jie Li","email":"lijie@unitedstack.com","username":"ramboman"},"change_message_id":"303e26d30694e9dc645594b7665ae48add16059c","unresolved":false,"context_lines":[{"line_number":46,"context_line":"if is a volume-backed server. Add a new method for compute manager which"},{"line_number":47,"context_line":"will be called \u0027_update_root_volume\u0027, this method will first check that"},{"line_number":48,"context_line":"the given image whether it is a \"volume-backed server image\". If the size"},{"line_number":49,"context_line":"is equal 0, the given image is \"volume-backed server image\", otherwise is"},{"line_number":50,"context_line":"the \"image-backed server image\", and then call the cinder API to re-image"},{"line_number":51,"context_line":"the volume, after the re-image api is complete, at once update and complete"},{"line_number":52,"context_line":"the volume attachment."},{"line_number":53,"context_line":""}],"source_content_type":"text/x-rst","patch_set":10,"id":"3f79a3b5_51c0f62c","line":50,"range":{"start_line":49,"start_character":31,"end_line":50,"end_character":32},"in_reply_to":"3f79a3b5_b7d2fb31","updated":"2018-11-02 09:27:09.000000000","message":"Yeah, there also could be a normal image.","commit_id":"87f299fbe4d0a5342d938a3bb5e63337e497fdd4"},{"author":{"_account_id":15888,"name":"Zhenyu Zheng","email":"zheng.zhenyu@outlook.com","username":"Kevin_Zheng"},"change_message_id":"511257e2dbb5ce9d7a5a5d3defb36d35feb71931","unresolved":false,"context_lines":[{"line_number":47,"context_line":"will be called \u0027_update_root_volume\u0027, this method will first check that"},{"line_number":48,"context_line":"the given image whether it is a \"volume-backed server image\". If the size"},{"line_number":49,"context_line":"is equal 0, the given image is \"volume-backed server image\", otherwise is"},{"line_number":50,"context_line":"the \"image-backed server image\", and then call the cinder API to re-image"},{"line_number":51,"context_line":"the volume, after the re-image api is complete, at once update and complete"},{"line_number":52,"context_line":"the volume attachment."},{"line_number":53,"context_line":""},{"line_number":54,"context_line":"Alternatives"},{"line_number":55,"context_line":"------------"}],"source_content_type":"text/x-rst","patch_set":10,"id":"3f79a3b5_37deeb3b","line":52,"range":{"start_line":50,"start_character":33,"end_line":52,"end_character":22},"updated":"2018-10-29 09:12:41.000000000","message":"only the \"image-backed server image\" will got this process?","commit_id":"87f299fbe4d0a5342d938a3bb5e63337e497fdd4"},{"author":{"_account_id":27594,"name":"Jie Li","email":"lijie@unitedstack.com","username":"ramboman"},"change_message_id":"303e26d30694e9dc645594b7665ae48add16059c","unresolved":false,"context_lines":[{"line_number":47,"context_line":"will be called \u0027_update_root_volume\u0027, this method will first check that"},{"line_number":48,"context_line":"the given image whether it is a \"volume-backed server image\". If the size"},{"line_number":49,"context_line":"is equal 0, the given image is \"volume-backed server image\", otherwise is"},{"line_number":50,"context_line":"the \"image-backed server image\", and then call the cinder API to re-image"},{"line_number":51,"context_line":"the volume, after the re-image api is complete, at once update and complete"},{"line_number":52,"context_line":"the volume attachment."},{"line_number":53,"context_line":""},{"line_number":54,"context_line":"Alternatives"},{"line_number":55,"context_line":"------------"}],"source_content_type":"text/x-rst","patch_set":10,"id":"3f79a3b5_b1ff0a68","line":52,"range":{"start_line":50,"start_character":33,"end_line":52,"end_character":22},"in_reply_to":"3f79a3b5_37deeb3b","updated":"2018-11-02 09:27:09.000000000","message":"No, we don\u0027t limit the image as the cinder re-image api","commit_id":"87f299fbe4d0a5342d938a3bb5e63337e497fdd4"},{"author":{"_account_id":15888,"name":"Zhenyu Zheng","email":"zheng.zhenyu@outlook.com","username":"Kevin_Zheng"},"change_message_id":"511257e2dbb5ce9d7a5a5d3defb36d35feb71931","unresolved":false,"context_lines":[{"line_number":80,"context_line":"REST API impact"},{"line_number":81,"context_line":"---------------"},{"line_number":82,"context_line":""},{"line_number":83,"context_line":"Change the rebuild request\u0027s response code from 400 to 202."},{"line_number":84,"context_line":"The microversion and compute RPC version will also be incremented to"},{"line_number":85,"context_line":"indicate the new support."},{"line_number":86,"context_line":""}],"source_content_type":"text/x-rst","patch_set":10,"id":"3f79a3b5_57a367b0","line":83,"range":{"start_line":83,"start_character":0,"end_line":83,"end_character":59},"updated":"2018-10-29 09:12:41.000000000","message":"Why do this?","commit_id":"87f299fbe4d0a5342d938a3bb5e63337e497fdd4"},{"author":{"_account_id":27594,"name":"Jie Li","email":"lijie@unitedstack.com","username":"ramboman"},"change_message_id":"303e26d30694e9dc645594b7665ae48add16059c","unresolved":false,"context_lines":[{"line_number":80,"context_line":"REST API impact"},{"line_number":81,"context_line":"---------------"},{"line_number":82,"context_line":""},{"line_number":83,"context_line":"Change the rebuild request\u0027s response code from 400 to 202."},{"line_number":84,"context_line":"The microversion and compute RPC version will also be incremented to"},{"line_number":85,"context_line":"indicate the new support."},{"line_number":86,"context_line":""}],"source_content_type":"text/x-rst","patch_set":10,"id":"3f79a3b5_f14102a9","line":83,"range":{"start_line":83,"start_character":0,"end_line":83,"end_character":59},"in_reply_to":"3f79a3b5_57a367b0","updated":"2018-11-02 09:27:09.000000000","message":"Because the user attempts to rebuild a volume-backed server *today* with a new root image, the compute API fails with a 400 error.Please see:\nhttps://github.com/openstack/nova/blob/master/nova/compute/api.py#L3254","commit_id":"87f299fbe4d0a5342d938a3bb5e63337e497fdd4"},{"author":{"_account_id":15888,"name":"Zhenyu Zheng","email":"zheng.zhenyu@outlook.com","username":"Kevin_Zheng"},"change_message_id":"511257e2dbb5ce9d7a5a5d3defb36d35feb71931","unresolved":false,"context_lines":[{"line_number":119,"context_line":"Upgrade impact"},{"line_number":120,"context_line":"--------------"},{"line_number":121,"context_line":""},{"line_number":122,"context_line":"None"},{"line_number":123,"context_line":""},{"line_number":124,"context_line":""},{"line_number":125,"context_line":"Implementation"}],"source_content_type":"text/x-rst","patch_set":10,"id":"3f79a3b5_77a6a3c1","line":122,"range":{"start_line":122,"start_character":0,"end_line":122,"end_character":4},"updated":"2018-10-29 09:12:41.000000000","message":"A new RPC version will be added in compute manager so there will be upgrade impact","commit_id":"87f299fbe4d0a5342d938a3bb5e63337e497fdd4"},{"author":{"_account_id":27594,"name":"Jie Li","email":"lijie@unitedstack.com","username":"ramboman"},"change_message_id":"303e26d30694e9dc645594b7665ae48add16059c","unresolved":false,"context_lines":[{"line_number":119,"context_line":"Upgrade impact"},{"line_number":120,"context_line":"--------------"},{"line_number":121,"context_line":""},{"line_number":122,"context_line":"None"},{"line_number":123,"context_line":""},{"line_number":124,"context_line":""},{"line_number":125,"context_line":"Implementation"}],"source_content_type":"text/x-rst","patch_set":10,"id":"3f79a3b5_d15e4677","line":122,"range":{"start_line":122,"start_character":0,"end_line":122,"end_character":4},"in_reply_to":"3f79a3b5_77a6a3c1","updated":"2018-11-02 09:27:09.000000000","message":"Done.","commit_id":"87f299fbe4d0a5342d938a3bb5e63337e497fdd4"},{"author":{"_account_id":12408,"name":"Maxim Nestratov","email":"mnestratov@virtuozzo.com","username":"mnestratov"},"change_message_id":"bbbe580df7a6bad784ca8c64eae50cad35ac42d8","unresolved":false,"context_lines":[{"line_number":10,"context_line":"https://blueprints.launchpad.net/nova/+spec/volume-backed-server-rebuild"},{"line_number":11,"context_line":""},{"line_number":12,"context_line":"Currently, the compute API will fail if a user tries to rebuild"},{"line_number":13,"context_line":"a volume-backed server with a new image. This spec proposes to add"},{"line_number":14,"context_line":"support for rebuilding a volume-backed server with a new image."},{"line_number":15,"context_line":""},{"line_number":16,"context_line":""},{"line_number":17,"context_line":"Problem description"}],"source_content_type":"text/x-rst","patch_set":12,"id":"3f79a3b5_a6426f66","line":14,"range":{"start_line":13,"start_character":41,"end_line":14,"end_character":63},"updated":"2018-11-02 10:46:13.000000000","message":"I wonder if we should address a case here or in a new spec when a user doesn\u0027t want to actually rebuild server\u0027s root disk and wants just to reuse it as is?\n\nI mean currently rebuild request *requires* an image but it\u0027s redundant for many cases with volume backed VMs. For instance host has died and user want just to recreate a VM using existing volumes. From this point of view this spec looks like only a particial solution of fixing rebuild API. Any thoughts on this?","commit_id":"434d34a7adedfd96b61d3b2dd2396a906f7ee004"},{"author":{"_account_id":12408,"name":"Maxim Nestratov","email":"mnestratov@virtuozzo.com","username":"mnestratov"},"change_message_id":"3ddab86d9b949edb7e347117af4718fe7d762670","unresolved":false,"context_lines":[{"line_number":10,"context_line":"https://blueprints.launchpad.net/nova/+spec/volume-backed-server-rebuild"},{"line_number":11,"context_line":""},{"line_number":12,"context_line":"Currently, the compute API will fail if a user tries to rebuild"},{"line_number":13,"context_line":"a volume-backed server with a new image. This spec proposes to add"},{"line_number":14,"context_line":"support for rebuilding a volume-backed server with a new image."},{"line_number":15,"context_line":""},{"line_number":16,"context_line":""},{"line_number":17,"context_line":"Problem description"}],"source_content_type":"text/x-rst","patch_set":12,"id":"3f79a3b5_22508009","line":14,"range":{"start_line":13,"start_character":41,"end_line":14,"end_character":63},"in_reply_to":"3f79a3b5_313a1097","updated":"2018-11-02 16:25:34.000000000","message":"Thanks for answering Matt. Of course I\u0027ll remove my -1 as it indeed looks as another spec matter. Sorry for that.\n As for Frankenstein VMs. It is a real use case for pet VMs. Try to look at it from this point. In case of nova created root disk the only way to rebuild a VM is to create a new root disk from scratch if a host where VM was resided died. I\u0027m not talking here about losing ephemeral disks when one rebuilds such VMs. In case of volume backed VMs all you need to bring it back is accessible. And would argue what I would call a Frankenstein VM. Asking user to do all the routine to detach all the attached volumes, removing neutron ports assigning key pairs specifiyng security and attaching them to new VMs for *all* VMs just because we have a mandatory parameter of an API call which shouldn\u0027t be specified for certain cases is not a good idea.","commit_id":"434d34a7adedfd96b61d3b2dd2396a906f7ee004"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"2335e3348e33fffa35cc6cda5cb0a566d023eba9","unresolved":false,"context_lines":[{"line_number":10,"context_line":"https://blueprints.launchpad.net/nova/+spec/volume-backed-server-rebuild"},{"line_number":11,"context_line":""},{"line_number":12,"context_line":"Currently, the compute API will fail if a user tries to rebuild"},{"line_number":13,"context_line":"a volume-backed server with a new image. This spec proposes to add"},{"line_number":14,"context_line":"support for rebuilding a volume-backed server with a new image."},{"line_number":15,"context_line":""},{"line_number":16,"context_line":""},{"line_number":17,"context_line":"Problem description"}],"source_content_type":"text/x-rst","patch_set":12,"id":"3f79a3b5_313a1097","line":14,"range":{"start_line":13,"start_character":41,"end_line":14,"end_character":63},"in_reply_to":"3f79a3b5_a6426f66","updated":"2018-11-02 14:57:17.000000000","message":"I don\u0027t think this is worth -1ing over since it\u0027s not clear what you\u0027re looking for - rebuild but without actually rebuilding the root disk? That\u0027s kind of the point of rebuild. You want to preserve the volumes, IPs and ID of the server but need to rebuild the root disk. You can specify the original image if you want, and that is supported with volume-backed rebuild today, but otherwise I\u0027m not understanding what you\u0027re looking for here. If the host died and the guest is gone, then the user can force detach the root volume and use it to create a new VM, right? Granted the ports and such might be gone, and the ID would change, but that\u0027s kind of what happens if the compute host is gone - it\u0027s a disaster recovery situation. Anyway, that\u0027s not really appropriate for this spec nor the -1 IMO, it\u0027s a completely new API concept to create a server from existing parts in the system, essentially a Frankenstein VM :).","commit_id":"434d34a7adedfd96b61d3b2dd2396a906f7ee004"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"2f717033663a2bf9ee3c817313c9b1946143d66b","unresolved":false,"context_lines":[{"line_number":33,"context_line":"Change existing API for rebuild the volume-backed server firstly."},{"line_number":34,"context_line":"Then the API flow would be:"},{"line_number":35,"context_line":""},{"line_number":36,"context_line":"1. Is the new API microversion been requested."},{"line_number":37,"context_line":"2. Is the instance.host service version new enough to support"},{"line_number":38,"context_line":"   volume-backed rebuild with a new image."},{"line_number":39,"context_line":""}],"source_content_type":"text/x-rst","patch_set":12,"id":"3f79a3b5_a6537d15","line":36,"range":{"start_line":36,"start_character":3,"end_line":36,"end_character":5},"updated":"2018-11-14 10:25:02.000000000","message":"nit: \"Has\"","commit_id":"434d34a7adedfd96b61d3b2dd2396a906f7ee004"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"2f717033663a2bf9ee3c817313c9b1946143d66b","unresolved":false,"context_lines":[{"line_number":33,"context_line":"Change existing API for rebuild the volume-backed server firstly."},{"line_number":34,"context_line":"Then the API flow would be:"},{"line_number":35,"context_line":""},{"line_number":36,"context_line":"1. Is the new API microversion been requested."},{"line_number":37,"context_line":"2. Is the instance.host service version new enough to support"},{"line_number":38,"context_line":"   volume-backed rebuild with a new image."},{"line_number":39,"context_line":""}],"source_content_type":"text/x-rst","patch_set":12,"id":"3f79a3b5_0642713d","line":36,"range":{"start_line":36,"start_character":45,"end_line":36,"end_character":46},"updated":"2018-11-14 10:25:02.000000000","message":"nit: s/./?/","commit_id":"434d34a7adedfd96b61d3b2dd2396a906f7ee004"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"2f717033663a2bf9ee3c817313c9b1946143d66b","unresolved":false,"context_lines":[{"line_number":35,"context_line":""},{"line_number":36,"context_line":"1. Is the new API microversion been requested."},{"line_number":37,"context_line":"2. Is the instance.host service version new enough to support"},{"line_number":38,"context_line":"   volume-backed rebuild with a new image."},{"line_number":39,"context_line":""},{"line_number":40,"context_line":"If these are true, proceed. If not, fail in the API with a 409 error."},{"line_number":41,"context_line":""}],"source_content_type":"text/x-rst","patch_set":12,"id":"3f79a3b5_e672d5af","line":38,"range":{"start_line":38,"start_character":41,"end_line":38,"end_character":42},"updated":"2018-11-14 10:25:02.000000000","message":"same nit","commit_id":"434d34a7adedfd96b61d3b2dd2396a906f7ee004"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"2f717033663a2bf9ee3c817313c9b1946143d66b","unresolved":false,"context_lines":[{"line_number":39,"context_line":""},{"line_number":40,"context_line":"If these are true, proceed. If not, fail in the API with a 409 error."},{"line_number":41,"context_line":""},{"line_number":42,"context_line":"Then the compute manager will do similar to how boot from volume works where"},{"line_number":43,"context_line":"the BDM source_type is \u0027image\u0027 or \u0027snapshot\u0027. We will judge the server"},{"line_number":44,"context_line":"if is a volume-backed server. Add a new method for compute manager which"},{"line_number":45,"context_line":"will be called \u0027_update_root_volume\u0027, this method will first check that"},{"line_number":46,"context_line":"the given image whether it is a \"volume-backed server image\". If the"}],"source_content_type":"text/x-rst","patch_set":12,"id":"3f79a3b5_26dbed7a","line":43,"range":{"start_line":42,"start_character":0,"end_line":43,"end_character":45},"updated":"2018-11-14 10:25:02.000000000","message":"Umm, not really, and saying that is just confusing for this spec I think.\n\nThe cinder reimage API spec actually has a fairly detailed explanation of the proposed change, so maybe that should just be copied here:\n\nhttps://review.openstack.org/#/c/605317/16/specs/stein/add-volume-re-image-api.rst@52","commit_id":"434d34a7adedfd96b61d3b2dd2396a906f7ee004"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"2f717033663a2bf9ee3c817313c9b1946143d66b","unresolved":false,"context_lines":[{"line_number":44,"context_line":"if is a volume-backed server. Add a new method for compute manager which"},{"line_number":45,"context_line":"will be called \u0027_update_root_volume\u0027, this method will first check that"},{"line_number":46,"context_line":"the given image whether it is a \"volume-backed server image\". If the"},{"line_number":47,"context_line":"image_upload_use_cinder_backend option is enabled, the given image is"},{"line_number":48,"context_line":"\"volume-backed server image\", otherwise is the \"image-backed server image\","},{"line_number":49,"context_line":"and then call the cinder API to re-image the volume, after the re-image api"},{"line_number":50,"context_line":"is complete, at once update and complete the volume attachment."}],"source_content_type":"text/x-rst","patch_set":12,"id":"3f79a3b5_86752189","line":47,"range":{"start_line":47,"start_character":0,"end_line":47,"end_character":31},"updated":"2018-11-14 10:25:02.000000000","message":"What is this option? This doesn\u0027t exist in nova. I guess it\u0027s in cinder:\n\nhttp://git.openstack.org/cgit/openstack/cinder/tree/cinder/volume/driver.py#n227\n\nI\u0027m not sure why this matters, and it\u0027s just confusing for the nova spec. I would remove mention of this.\n\nAs long as the root volume has volume_image_metadata we know it\u0027s an image-backed volume, correct? But does that matter for this rebuild flow? Are there cases were we can have a volume-backed server where the root volume itself doesn\u0027t have a backing image? You can create a volume from a volume snapshot but that volume snapshot eventually points back to something with an image doesn\u0027t it?","commit_id":"434d34a7adedfd96b61d3b2dd2396a906f7ee004"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"2f717033663a2bf9ee3c817313c9b1946143d66b","unresolved":false,"context_lines":[{"line_number":90,"context_line":"Notifications impact"},{"line_number":91,"context_line":"--------------------"},{"line_number":92,"context_line":""},{"line_number":93,"context_line":"None"},{"line_number":94,"context_line":""},{"line_number":95,"context_line":"Other end user impact"},{"line_number":96,"context_line":"---------------------"}],"source_content_type":"text/x-rst","patch_set":12,"id":"3f79a3b5_2610cdf4","line":93,"updated":"2018-11-14 10:25:02.000000000","message":"You probably don\u0027t need to update this, but looking at the rebuild code in the compute manager it does deal with sending notifications with the old and new image reference, but I\u0027m not sure that even sends *any* image ref today for volume-backed servers since instance.image_ref is \u0027\u0027 for volume-backed servers. The legacy rebuild.start notification might properly send the new image ref, but I\u0027m not sure. Anyway, it\u0027s likely a latent bug if that\u0027s not working properly for volume-backed servers and doesn\u0027t need to be something we investigate/fix as a result of this spec.","commit_id":"434d34a7adedfd96b61d3b2dd2396a906f7ee004"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"2f717033663a2bf9ee3c817313c9b1946143d66b","unresolved":false,"context_lines":[{"line_number":95,"context_line":"Other end user impact"},{"line_number":96,"context_line":"---------------------"},{"line_number":97,"context_line":""},{"line_number":98,"context_line":"The python-novaclient will be updated to support the new microversion."},{"line_number":99,"context_line":"User can provide any format image to rebuild the volume-backed server."},{"line_number":100,"context_line":""},{"line_number":101,"context_line":"Performance Impact"}],"source_content_type":"text/x-rst","patch_set":12,"id":"3f79a3b5_86d44120","line":98,"updated":"2018-11-14 10:25:02.000000000","message":"Add python-openstackclient to this - we\u0027re trying to keep feature parity with OSC so we can eventually switch users from nova CLI to OSC CLI.","commit_id":"434d34a7adedfd96b61d3b2dd2396a906f7ee004"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"2f717033663a2bf9ee3c817313c9b1946143d66b","unresolved":false,"context_lines":[{"line_number":101,"context_line":"Performance Impact"},{"line_number":102,"context_line":"------------------"},{"line_number":103,"context_line":""},{"line_number":104,"context_line":"The operation will take longer time because of the orchestration"},{"line_number":105,"context_line":"involved and the work that needs to happen in Cinder."},{"line_number":106,"context_line":""},{"line_number":107,"context_line":"Other deployer impact"}],"source_content_type":"text/x-rst","patch_set":12,"id":"3f79a3b5_a6d93d56","line":104,"range":{"start_line":104,"start_character":31,"end_line":104,"end_character":35},"updated":"2018-11-14 10:25:02.000000000","message":"nit: you can remove \u0027time\u0027.","commit_id":"434d34a7adedfd96b61d3b2dd2396a906f7ee004"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"2f717033663a2bf9ee3c817313c9b1946143d66b","unresolved":false,"context_lines":[{"line_number":137,"context_line":"  remains in-use during rebuild (we do this today already)."},{"line_number":138,"context_line":"* Delete the old volume attachment."},{"line_number":139,"context_line":"* Call the cinder API to re-image the volume."},{"line_number":140,"context_line":"* Update and complete the volume attachment once re-imaged."},{"line_number":141,"context_line":"* Adopt the new compute version."},{"line_number":142,"context_line":"* Adopt the new microversion in python-novaclient."},{"line_number":143,"context_line":"* Change the nova API documents."}],"source_content_type":"text/x-rst","patch_set":12,"id":"3f79a3b5_e68bb513","line":140,"updated":"2018-11-14 10:25:02.000000000","message":"Should probably add something in the \"proposed change\" section about what happens if the re-image API in cinder fails, either because nova gets a \u003e\u003d400 response from the cinder API or the volume status changes to \u0027error\u0027. It looks like the existing error handling will mark the migration status as \u0027failed\u0027 and set the instance status as \u0027error\u0027, which is probably correct in this case - if we failed to re-image the volume and the volume is in \u0027error\u0027 status then we don\u0027t know the status of the root disk and should fail. If the cinder API itself returns a \u003e\u003d400 error, nothing changed about the root volume and in that case the migration status can be \u0027failed\u0027 but the instance status should go back to what it was (see how _error_out_instance_on_exception is used).","commit_id":"434d34a7adedfd96b61d3b2dd2396a906f7ee004"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"2f717033663a2bf9ee3c817313c9b1946143d66b","unresolved":false,"context_lines":[{"line_number":145,"context_line":"Dependencies"},{"line_number":146,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"},{"line_number":147,"context_line":""},{"line_number":148,"context_line":"Dependence the cinder blueprint for re-imaging a volume, see"},{"line_number":149,"context_line":"more detail information in References."},{"line_number":150,"context_line":""},{"line_number":151,"context_line":""}],"source_content_type":"text/x-rst","patch_set":12,"id":"3f79a3b5_6697a539","line":148,"range":{"start_line":148,"start_character":0,"end_line":148,"end_character":10},"updated":"2018-11-14 10:25:02.000000000","message":"\"Depends on\"","commit_id":"434d34a7adedfd96b61d3b2dd2396a906f7ee004"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"2f717033663a2bf9ee3c817313c9b1946143d66b","unresolved":false,"context_lines":[{"line_number":165,"context_line":"a note about the required minimum microversion for rebuilding a"},{"line_number":166,"context_line":"volume-backed server with a new image."},{"line_number":167,"context_line":""},{"line_number":168,"context_line":"The following document is updated."},{"line_number":169,"context_line":""},{"line_number":170,"context_line":"* API Reference"},{"line_number":171,"context_line":""}],"source_content_type":"text/x-rst","patch_set":12,"id":"3f79a3b5_46c3893b","line":168,"range":{"start_line":168,"start_character":23,"end_line":168,"end_character":25},"updated":"2018-11-14 10:25:02.000000000","message":"\"will be\"","commit_id":"434d34a7adedfd96b61d3b2dd2396a906f7ee004"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"2f717033663a2bf9ee3c817313c9b1946143d66b","unresolved":false,"context_lines":[{"line_number":165,"context_line":"a note about the required minimum microversion for rebuilding a"},{"line_number":166,"context_line":"volume-backed server with a new image."},{"line_number":167,"context_line":""},{"line_number":168,"context_line":"The following document is updated."},{"line_number":169,"context_line":""},{"line_number":170,"context_line":"* API Reference"},{"line_number":171,"context_line":""}],"source_content_type":"text/x-rst","patch_set":12,"id":"3f79a3b5_86a9a179","line":168,"range":{"start_line":168,"start_character":33,"end_line":168,"end_character":34},"updated":"2018-11-14 10:25:02.000000000","message":":","commit_id":"434d34a7adedfd96b61d3b2dd2396a906f7ee004"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"2f717033663a2bf9ee3c817313c9b1946143d66b","unresolved":false,"context_lines":[{"line_number":194,"context_line":"   * - Release Name"},{"line_number":195,"context_line":"     - Description"},{"line_number":196,"context_line":"   * - Stein"},{"line_number":197,"context_line":"     - Re-proposed"}],"source_content_type":"text/x-rst","patch_set":12,"id":"3f79a3b5_26ba0dba","line":197,"range":{"start_line":197,"start_character":7,"end_line":197,"end_character":18},"updated":"2018-11-14 10:25:02.000000000","message":"Just \"Proposed\".","commit_id":"434d34a7adedfd96b61d3b2dd2396a906f7ee004"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"341d8125465649e5add42743b9e447106e0e86fc","unresolved":false,"context_lines":[{"line_number":33,"context_line":"Change existing API for rebuild the volume-backed server firstly."},{"line_number":34,"context_line":"Then the API flow would be:"},{"line_number":35,"context_line":""},{"line_number":36,"context_line":"1. Is the new API microversion been requested ?"},{"line_number":37,"context_line":"2. Has the instance.host service version new enough to support"},{"line_number":38,"context_line":"   volume-backed rebuild with a new image ?"},{"line_number":39,"context_line":""}],"source_content_type":"text/x-rst","patch_set":14,"id":"3f79a3b5_111ad07e","line":36,"range":{"start_line":36,"start_character":3,"end_line":36,"end_character":5},"updated":"2018-11-28 15:22:48.000000000","message":"Has","commit_id":"071d7a97b942d6862f963b7c94804d7c36c661bf"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"341d8125465649e5add42743b9e447106e0e86fc","unresolved":false,"context_lines":[{"line_number":33,"context_line":"Change existing API for rebuild the volume-backed server firstly."},{"line_number":34,"context_line":"Then the API flow would be:"},{"line_number":35,"context_line":""},{"line_number":36,"context_line":"1. Is the new API microversion been requested ?"},{"line_number":37,"context_line":"2. Has the instance.host service version new enough to support"},{"line_number":38,"context_line":"   volume-backed rebuild with a new image ?"},{"line_number":39,"context_line":""}],"source_content_type":"text/x-rst","patch_set":14,"id":"3f79a3b5_b14f5c8b","line":36,"range":{"start_line":36,"start_character":45,"end_line":36,"end_character":46},"updated":"2018-11-28 15:22:48.000000000","message":"nit: remove the space","commit_id":"071d7a97b942d6862f963b7c94804d7c36c661bf"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"341d8125465649e5add42743b9e447106e0e86fc","unresolved":false,"context_lines":[{"line_number":34,"context_line":"Then the API flow would be:"},{"line_number":35,"context_line":""},{"line_number":36,"context_line":"1. Is the new API microversion been requested ?"},{"line_number":37,"context_line":"2. Has the instance.host service version new enough to support"},{"line_number":38,"context_line":"   volume-backed rebuild with a new image ?"},{"line_number":39,"context_line":""},{"line_number":40,"context_line":"If these are true, proceed. If not, fail in the API with a 409 error."}],"source_content_type":"text/x-rst","patch_set":14,"id":"3f79a3b5_71146450","line":37,"range":{"start_line":37,"start_character":3,"end_line":37,"end_character":6},"updated":"2018-11-28 15:22:48.000000000","message":"Is","commit_id":"071d7a97b942d6862f963b7c94804d7c36c661bf"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"341d8125465649e5add42743b9e447106e0e86fc","unresolved":false,"context_lines":[{"line_number":35,"context_line":""},{"line_number":36,"context_line":"1. Is the new API microversion been requested ?"},{"line_number":37,"context_line":"2. Has the instance.host service version new enough to support"},{"line_number":38,"context_line":"   volume-backed rebuild with a new image ?"},{"line_number":39,"context_line":""},{"line_number":40,"context_line":"If these are true, proceed. If not, fail in the API with a 409 error."},{"line_number":41,"context_line":""}],"source_content_type":"text/x-rst","patch_set":14,"id":"3f79a3b5_310a6c28","line":38,"range":{"start_line":38,"start_character":41,"end_line":38,"end_character":42},"updated":"2018-11-28 15:22:48.000000000","message":"remove the space","commit_id":"071d7a97b942d6862f963b7c94804d7c36c661bf"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"341d8125465649e5add42743b9e447106e0e86fc","unresolved":false,"context_lines":[{"line_number":41,"context_line":""},{"line_number":42,"context_line":"Then the nova-commpute will perform the following steps:"},{"line_number":43,"context_line":""},{"line_number":44,"context_line":"  #. Create an empty (no connector) volume attachment for the volume and"},{"line_number":45,"context_line":"     server. This ensures the volume remains ``reserved`` through the next"},{"line_number":46,"context_line":"     step."},{"line_number":47,"context_line":"  #. Delete the existing volume attachment (the old one)."}],"source_content_type":"text/x-rst","patch_set":14,"id":"3f79a3b5_7c70bba7","line":44,"range":{"start_line":44,"start_character":0,"end_line":44,"end_character":2},"updated":"2018-11-28 15:22:48.000000000","message":"Drop the indent here, it messes up the formatting:\n\nhttp://logs.openstack.org/07/532407/14/check/openstack-tox-docs/9e0f1c0/html/specs/stein/approved/volume-backed-server-rebuild.html#proposed-change","commit_id":"071d7a97b942d6862f963b7c94804d7c36c661bf"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"341d8125465649e5add42743b9e447106e0e86fc","unresolved":false,"context_lines":[{"line_number":59,"context_line":"* If the cinder API itself returns a \u003e\u003d400 error, nothing changed about the"},{"line_number":60,"context_line":"  root volume and in that case the migration status can be \u0027failed\u0027 but the"},{"line_number":61,"context_line":"  instance status should go back to what it was (we can see how"},{"line_number":62,"context_line":"  _error_out_instance_on_exception is used)."},{"line_number":63,"context_line":""},{"line_number":64,"context_line":""},{"line_number":65,"context_line":"Alternatives"}],"source_content_type":"text/x-rst","patch_set":14,"id":"3f79a3b5_fcd60b54","line":62,"range":{"start_line":62,"start_character":2,"end_line":62,"end_character":34},"updated":"2018-11-28 15:22:48.000000000","message":"We\u0027ll likely have to modify this since today if it gets a CinderClientException or something like that, it will fall into the Exception block and set the instance to ERROR state:\n\nhttps://github.com/openstack/nova/blob/62245235bc15da6abcdfd3df1c24bd856d69fbb4/nova/compute/manager.py#L7894\n\nAnyway, that\u0027s a small implementation detail we can sort out in the code and have a test scenario for it.","commit_id":"071d7a97b942d6862f963b7c94804d7c36c661bf"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"8064421a9da063e075417a4f3c222308196b237e","unresolved":false,"context_lines":[{"line_number":65,"context_line":"Alternatives"},{"line_number":66,"context_line":"------------"},{"line_number":67,"context_line":""},{"line_number":68,"context_line":"There are two alternatives about how to handle the old root volume."},{"line_number":69,"context_line":""},{"line_number":70,"context_line":"* Passing a new flag to the rebuild API telling nova what to do about the"},{"line_number":71,"context_line":"  old volume (delete it or not)."}],"source_content_type":"text/x-rst","patch_set":14,"id":"3f79a3b5_bc2413c5","line":68,"updated":"2018-11-28 16:00:53.000000000","message":"The alternatives here omit the actual alternative, which was nova creating a new volume and swapping to it from the old one.","commit_id":"071d7a97b942d6862f963b7c94804d7c36c661bf"},{"author":{"_account_id":8768,"name":"Chris Friesen","email":"chris.friesen@windriver.com","username":"cbf123"},"change_message_id":"abf4412478627518cdc3206ec52ac72c448f0650","unresolved":false,"context_lines":[{"line_number":41,"context_line":"#. Is the instance.host service version new enough to support"},{"line_number":42,"context_line":"   volume-backed rebuild with a new image?"},{"line_number":43,"context_line":""},{"line_number":44,"context_line":"If these are true, proceed. If not, fail in the API with a 409 error."},{"line_number":45,"context_line":""},{"line_number":46,"context_line":"Then the nova-commpute will perform the following steps:"},{"line_number":47,"context_line":""}],"source_content_type":"text/x-rst","patch_set":15,"id":"3f79a3b5_ec441a1c","line":44,"range":{"start_line":44,"start_character":59,"end_line":44,"end_character":68},"updated":"2018-11-28 17:25:30.000000000","message":"Is this the same error we get now?  I assume we\u0027d want to preserve current behaviour if the new microversion hasn\u0027t been requested.","commit_id":"63224db9f57bbfeb4f55c35aa9c9fda80da558c9"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"25c56204091e5c265434101d747c86d69ac480ef","unresolved":false,"context_lines":[{"line_number":41,"context_line":"#. Is the instance.host service version new enough to support"},{"line_number":42,"context_line":"   volume-backed rebuild with a new image?"},{"line_number":43,"context_line":""},{"line_number":44,"context_line":"If these are true, proceed. If not, fail in the API with a 409 error."},{"line_number":45,"context_line":""},{"line_number":46,"context_line":"Then the nova-commpute will perform the following steps:"},{"line_number":47,"context_line":""}],"source_content_type":"text/x-rst","patch_set":15,"id":"3f79a3b5_ffc4ba62","line":44,"range":{"start_line":44,"start_character":59,"end_line":44,"end_character":68},"in_reply_to":"3f79a3b5_dff21ee4","updated":"2018-11-28 18:08:55.000000000","message":"So then this is really 400 if old microversion, or 409/202 if new microversion, depending on the above, right?","commit_id":"63224db9f57bbfeb4f55c35aa9c9fda80da558c9"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"06c7ba2a295dc587594dff86389d3de33aa0c1c3","unresolved":false,"context_lines":[{"line_number":41,"context_line":"#. Is the instance.host service version new enough to support"},{"line_number":42,"context_line":"   volume-backed rebuild with a new image?"},{"line_number":43,"context_line":""},{"line_number":44,"context_line":"If these are true, proceed. If not, fail in the API with a 409 error."},{"line_number":45,"context_line":""},{"line_number":46,"context_line":"Then the nova-commpute will perform the following steps:"},{"line_number":47,"context_line":""}],"source_content_type":"text/x-rst","patch_set":15,"id":"3f79a3b5_dff21ee4","line":44,"range":{"start_line":44,"start_character":59,"end_line":44,"end_character":68},"in_reply_to":"3f79a3b5_ec441a1c","updated":"2018-11-28 18:05:32.000000000","message":"No, today you get a 400. The 409 means, \"you can\u0027t do this (yet)\". Similar to other things in the API like attaching devices with tags and multi-attach volumes.","commit_id":"63224db9f57bbfeb4f55c35aa9c9fda80da558c9"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"1f661043e51acdb30004129b3f1133bd870eeea9","unresolved":false,"context_lines":[{"line_number":41,"context_line":"#. Is the instance.host service version new enough to support"},{"line_number":42,"context_line":"   volume-backed rebuild with a new image?"},{"line_number":43,"context_line":""},{"line_number":44,"context_line":"If these are true, proceed. If not, fail in the API with a 409 error."},{"line_number":45,"context_line":""},{"line_number":46,"context_line":"Then the nova-commpute will perform the following steps:"},{"line_number":47,"context_line":""}],"source_content_type":"text/x-rst","patch_set":15,"id":"3f79a3b5_bf688256","line":44,"range":{"start_line":44,"start_character":59,"end_line":44,"end_character":68},"in_reply_to":"3f79a3b5_ffc4ba62","updated":"2018-11-28 18:11:48.000000000","message":"Correct.","commit_id":"63224db9f57bbfeb4f55c35aa9c9fda80da558c9"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"1cdf194108dbae0eb640b1a36038aa06889bb8c5","unresolved":false,"context_lines":[{"line_number":43,"context_line":""},{"line_number":44,"context_line":"If these are true, proceed. If not, fail in the API with a 409 error."},{"line_number":45,"context_line":""},{"line_number":46,"context_line":"Then the nova-commpute will perform the following steps:"},{"line_number":47,"context_line":""},{"line_number":48,"context_line":"#. Create an empty (no connector) volume attachment for the volume and"},{"line_number":49,"context_line":"   server. This ensures the volume remains ``reserved`` through the next"}],"source_content_type":"text/x-rst","patch_set":15,"id":"3f79a3b5_5f704ea7","line":46,"range":{"start_line":46,"start_character":14,"end_line":46,"end_character":22},"updated":"2018-11-28 17:56:46.000000000","message":"compute","commit_id":"63224db9f57bbfeb4f55c35aa9c9fda80da558c9"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"42035ee7a6ad2141fb68caa870e65fe3ec5f25b0","unresolved":false,"context_lines":[{"line_number":43,"context_line":""},{"line_number":44,"context_line":"If these are true, proceed. If not, fail in the API with a 409 error."},{"line_number":45,"context_line":""},{"line_number":46,"context_line":"Then the nova-commpute will perform the following steps:"},{"line_number":47,"context_line":""},{"line_number":48,"context_line":"#. Create an empty (no connector) volume attachment for the volume and"},{"line_number":49,"context_line":"   server. This ensures the volume remains ``reserved`` through the next"}],"source_content_type":"text/x-rst","patch_set":15,"id":"3f79a3b5_7d98b2c9","line":46,"range":{"start_line":46,"start_character":14,"end_line":46,"end_character":22},"in_reply_to":"3f79a3b5_5f704ea7","updated":"2018-11-28 19:40:55.000000000","message":"Done","commit_id":"63224db9f57bbfeb4f55c35aa9c9fda80da558c9"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"1cdf194108dbae0eb640b1a36038aa06889bb8c5","unresolved":false,"context_lines":[{"line_number":49,"context_line":"   server. This ensures the volume remains ``reserved`` through the next"},{"line_number":50,"context_line":"   step."},{"line_number":51,"context_line":"#. Delete the existing volume attachment (the old one)."},{"line_number":52,"context_line":"#. Call the new ``os-reimage`` API."},{"line_number":53,"context_line":"#. Poll the volume status for completion (either success or failure)."},{"line_number":54,"context_line":"#. Upon successful completion of the re-image operation, update the empty"},{"line_number":55,"context_line":"   volume attchment in Cinder, and then do the attachment on the Nova host"}],"source_content_type":"text/x-rst","patch_set":15,"id":"3f79a3b5_3f69d2bd","line":52,"range":{"start_line":52,"start_character":31,"end_line":52,"end_character":34},"updated":"2018-11-28 17:56:46.000000000","message":"cinder API","commit_id":"63224db9f57bbfeb4f55c35aa9c9fda80da558c9"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"42035ee7a6ad2141fb68caa870e65fe3ec5f25b0","unresolved":false,"context_lines":[{"line_number":49,"context_line":"   server. This ensures the volume remains ``reserved`` through the next"},{"line_number":50,"context_line":"   step."},{"line_number":51,"context_line":"#. Delete the existing volume attachment (the old one)."},{"line_number":52,"context_line":"#. Call the new ``os-reimage`` API."},{"line_number":53,"context_line":"#. Poll the volume status for completion (either success or failure)."},{"line_number":54,"context_line":"#. Upon successful completion of the re-image operation, update the empty"},{"line_number":55,"context_line":"   volume attchment in Cinder, and then do the attachment on the Nova host"}],"source_content_type":"text/x-rst","patch_set":15,"id":"3f79a3b5_9d590e2b","line":52,"range":{"start_line":52,"start_character":31,"end_line":52,"end_character":34},"in_reply_to":"3f79a3b5_3f69d2bd","updated":"2018-11-28 19:40:55.000000000","message":"Done","commit_id":"63224db9f57bbfeb4f55c35aa9c9fda80da558c9"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"1cdf194108dbae0eb640b1a36038aa06889bb8c5","unresolved":false,"context_lines":[{"line_number":59,"context_line":"In this process, there are some conditions that we could hit:"},{"line_number":60,"context_line":""},{"line_number":61,"context_line":"* If we failed to re-image the volume and the volume is in \u0027error\u0027 status"},{"line_number":62,"context_line":"  then we should set the instance status as \"error\"."},{"line_number":63,"context_line":"* If the cinder API itself returns a \u003e\u003d400 error, nothing changed about the"},{"line_number":64,"context_line":"  root volume and in that case the migration status can be \u0027failed\u0027 but the"},{"line_number":65,"context_line":"  instance status should go back to what it was (we can see how"}],"source_content_type":"text/x-rst","patch_set":15,"id":"3f79a3b5_5f95ae92","line":62,"updated":"2018-11-28 17:56:46.000000000","message":"What is the exit path for an instance in this situation. Will we allow re-trying the rebuild and handle that properly?","commit_id":"63224db9f57bbfeb4f55c35aa9c9fda80da558c9"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"25c56204091e5c265434101d747c86d69ac480ef","unresolved":false,"context_lines":[{"line_number":59,"context_line":"In this process, there are some conditions that we could hit:"},{"line_number":60,"context_line":""},{"line_number":61,"context_line":"* If we failed to re-image the volume and the volume is in \u0027error\u0027 status"},{"line_number":62,"context_line":"  then we should set the instance status as \"error\"."},{"line_number":63,"context_line":"* If the cinder API itself returns a \u003e\u003d400 error, nothing changed about the"},{"line_number":64,"context_line":"  root volume and in that case the migration status can be \u0027failed\u0027 but the"},{"line_number":65,"context_line":"  instance status should go back to what it was (we can see how"}],"source_content_type":"text/x-rst","patch_set":15,"id":"3f79a3b5_1f7ad625","line":62,"in_reply_to":"3f79a3b5_1f1e560e","updated":"2018-11-28 18:08:55.000000000","message":"Yeah, not worried about the cinder side, but once it gets fixed, will we retain enough linkage and be able to un-screw our own data model and attachment state to do the right thing?","commit_id":"63224db9f57bbfeb4f55c35aa9c9fda80da558c9"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"1f661043e51acdb30004129b3f1133bd870eeea9","unresolved":false,"context_lines":[{"line_number":59,"context_line":"In this process, there are some conditions that we could hit:"},{"line_number":60,"context_line":""},{"line_number":61,"context_line":"* If we failed to re-image the volume and the volume is in \u0027error\u0027 status"},{"line_number":62,"context_line":"  then we should set the instance status as \"error\"."},{"line_number":63,"context_line":"* If the cinder API itself returns a \u003e\u003d400 error, nothing changed about the"},{"line_number":64,"context_line":"  root volume and in that case the migration status can be \u0027failed\u0027 but the"},{"line_number":65,"context_line":"  instance status should go back to what it was (we can see how"}],"source_content_type":"text/x-rst","patch_set":15,"id":"3f79a3b5_9fa26697","line":62,"in_reply_to":"3f79a3b5_1f7ad625","updated":"2018-11-28 18:11:48.000000000","message":"I could probably answer more specifically if you had something specific in mind here that we should be sure about. But the instance.image_ref is going to be \u0027\u0027 for volume-backed anyway. The image meta in the volume should only change when the reimage cinder API is successful, so we should be good there. The only thing I can think that we need to rollback on failure is the volume attachment (as noted above).","commit_id":"63224db9f57bbfeb4f55c35aa9c9fda80da558c9"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"06c7ba2a295dc587594dff86389d3de33aa0c1c3","unresolved":false,"context_lines":[{"line_number":59,"context_line":"In this process, there are some conditions that we could hit:"},{"line_number":60,"context_line":""},{"line_number":61,"context_line":"* If we failed to re-image the volume and the volume is in \u0027error\u0027 status"},{"line_number":62,"context_line":"  then we should set the instance status as \"error\"."},{"line_number":63,"context_line":"* If the cinder API itself returns a \u003e\u003d400 error, nothing changed about the"},{"line_number":64,"context_line":"  root volume and in that case the migration status can be \u0027failed\u0027 but the"},{"line_number":65,"context_line":"  instance status should go back to what it was (we can see how"}],"source_content_type":"text/x-rst","patch_set":15,"id":"3f79a3b5_1f1e560e","line":62,"in_reply_to":"3f79a3b5_5f95ae92","updated":"2018-11-28 18:05:32.000000000","message":"You can rebuild an instance in ERROR state, so if something got borked on the cinder side, I assume it would require some kind of intervention from the admin in cinder (I\u0027m not sure what they\u0027d do, depends on the failure). But yeah since you can rebuild from ERROR, I think the user could retry once the cinder side is fixed.\n\nThe questions is probably more about what happens with the volume attachments, right? Because by the time we hit the cinder API, we\u0027ve deleted the old attachment and created a new empty one. I think if the cinder API fails, we would want to update the volume attachment with the host connector so the volume goes from \u0027reserved\u0027 to \u0027in-use\u0027 again (essentially rollback the detach).","commit_id":"63224db9f57bbfeb4f55c35aa9c9fda80da558c9"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"42035ee7a6ad2141fb68caa870e65fe3ec5f25b0","unresolved":false,"context_lines":[{"line_number":59,"context_line":"In this process, there are some conditions that we could hit:"},{"line_number":60,"context_line":""},{"line_number":61,"context_line":"* If we failed to re-image the volume and the volume is in \u0027error\u0027 status"},{"line_number":62,"context_line":"  then we should set the instance status as \"error\"."},{"line_number":63,"context_line":"* If the cinder API itself returns a \u003e\u003d400 error, nothing changed about the"},{"line_number":64,"context_line":"  root volume and in that case the migration status can be \u0027failed\u0027 but the"},{"line_number":65,"context_line":"  instance status should go back to what it was (we can see how"}],"source_content_type":"text/x-rst","patch_set":15,"id":"3f79a3b5_1d9bbec6","line":62,"in_reply_to":"3f79a3b5_62257115","updated":"2018-11-28 19:40:55.000000000","message":"Done","commit_id":"63224db9f57bbfeb4f55c35aa9c9fda80da558c9"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"df654b52ae3afc3be1ae343cc31e61d5a62e1c1c","unresolved":false,"context_lines":[{"line_number":59,"context_line":"In this process, there are some conditions that we could hit:"},{"line_number":60,"context_line":""},{"line_number":61,"context_line":"* If we failed to re-image the volume and the volume is in \u0027error\u0027 status"},{"line_number":62,"context_line":"  then we should set the instance status as \"error\"."},{"line_number":63,"context_line":"* If the cinder API itself returns a \u003e\u003d400 error, nothing changed about the"},{"line_number":64,"context_line":"  root volume and in that case the migration status can be \u0027failed\u0027 but the"},{"line_number":65,"context_line":"  instance status should go back to what it was (we can see how"}],"source_content_type":"text/x-rst","patch_set":15,"id":"3f79a3b5_62257115","line":62,"in_reply_to":"3f79a3b5_9fa26697","updated":"2018-11-28 19:09:59.000000000","message":"Having thought about the rollback scenario a bit more, I don\u0027t think nova should try and update the empty attachment with the host connector before raising and setting the instance to error status. If the volume failed the reimage and is in error status, we probably shouldn\u0027t try to update the volume attachment because (1) cinder might reject that based on the volume status (it\u0027s not immediately clear to me from the cinder code) or (2) it could actually change the volume status from error to \u0027attaching\u0027 which would be bad, since if the volume is in error status it should remain that way. So I think we just poll cinder for the volume status and if it\u0027s error we set the instance to error and fail the rebuild. The volume would still be \u0027reserved\u0027 by the server so if you fix cinder and rebuild the server in error status, we\u0027ll just delete the empty attachment and create a new one, as noted above, so it should be OK.","commit_id":"63224db9f57bbfeb4f55c35aa9c9fda80da558c9"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"06c7ba2a295dc587594dff86389d3de33aa0c1c3","unresolved":false,"context_lines":[{"line_number":64,"context_line":"  root volume and in that case the migration status can be \u0027failed\u0027 but the"},{"line_number":65,"context_line":"  instance status should go back to what it was (we can see how"},{"line_number":66,"context_line":"  _error_out_instance_on_exception is used)."},{"line_number":67,"context_line":""},{"line_number":68,"context_line":""},{"line_number":69,"context_line":"Alternatives"},{"line_number":70,"context_line":"------------"}],"source_content_type":"text/x-rst","patch_set":15,"id":"3f79a3b5_bf5e42df","line":67,"updated":"2018-11-28 18:05:32.000000000","message":"One thing I thought about after +2ing this is what do we do about running the request through the scheduler in case the image changes? I *think* that would happen based on how the API code works and the image changes. I\u0027m not entirely sure how necessary it is though...since the request spec might not contain the image reference for the new image that goes into the root volume, so the filters likely really won\u0027t matter much - I\u0027m not sure. It requires investigation.","commit_id":"63224db9f57bbfeb4f55c35aa9c9fda80da558c9"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"42035ee7a6ad2141fb68caa870e65fe3ec5f25b0","unresolved":false,"context_lines":[{"line_number":64,"context_line":"  root volume and in that case the migration status can be \u0027failed\u0027 but the"},{"line_number":65,"context_line":"  instance status should go back to what it was (we can see how"},{"line_number":66,"context_line":"  _error_out_instance_on_exception is used)."},{"line_number":67,"context_line":""},{"line_number":68,"context_line":""},{"line_number":69,"context_line":"Alternatives"},{"line_number":70,"context_line":"------------"}],"source_content_type":"text/x-rst","patch_set":15,"id":"3f79a3b5_3d9ebab5","line":67,"in_reply_to":"3f79a3b5_3fab1270","updated":"2018-11-28 19:40:55.000000000","message":"Done","commit_id":"63224db9f57bbfeb4f55c35aa9c9fda80da558c9"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"25c56204091e5c265434101d747c86d69ac480ef","unresolved":false,"context_lines":[{"line_number":64,"context_line":"  root volume and in that case the migration status can be \u0027failed\u0027 but the"},{"line_number":65,"context_line":"  instance status should go back to what it was (we can see how"},{"line_number":66,"context_line":"  _error_out_instance_on_exception is used)."},{"line_number":67,"context_line":""},{"line_number":68,"context_line":""},{"line_number":69,"context_line":"Alternatives"},{"line_number":70,"context_line":"------------"}],"source_content_type":"text/x-rst","patch_set":15,"id":"3f79a3b5_df777e3b","line":67,"in_reply_to":"3f79a3b5_bf5e42df","updated":"2018-11-28 18:08:55.000000000","message":"Seems like the same policy enforcement question as for image-backed ones right? Just because it\u0027s volume-backed doesn\u0027t mean you can\u0027t rebuild to an instance with some conflictory (yeah) image metadata requirements.","commit_id":"63224db9f57bbfeb4f55c35aa9c9fda80da558c9"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"1f661043e51acdb30004129b3f1133bd870eeea9","unresolved":false,"context_lines":[{"line_number":64,"context_line":"  root volume and in that case the migration status can be \u0027failed\u0027 but the"},{"line_number":65,"context_line":"  instance status should go back to what it was (we can see how"},{"line_number":66,"context_line":"  _error_out_instance_on_exception is used)."},{"line_number":67,"context_line":""},{"line_number":68,"context_line":""},{"line_number":69,"context_line":"Alternatives"},{"line_number":70,"context_line":"------------"}],"source_content_type":"text/x-rst","patch_set":15,"id":"3f79a3b5_3fab1270","line":67,"in_reply_to":"3f79a3b5_df777e3b","updated":"2018-11-28 18:11:48.000000000","message":"If you\u0027re saying, \"yes if the image changes during rebuild we should run it through the scheduler\" then yes I agree that\u0027s the sane thing to do, if for no other reason it would be consistent with image-backed server build when a new image is provided.","commit_id":"63224db9f57bbfeb4f55c35aa9c9fda80da558c9"}]}
