)]}'
{"specs/rocky/approved/default-allocation-ratios.rst":[{"author":{"_account_id":7166,"name":"Sylvain Bauza","email":"sbauza@redhat.com","username":"sbauza"},"change_message_id":"eea36bb87db4a3a6a3895a4481e3bae363056da8","unresolved":false,"context_lines":[{"line_number":56,"context_line":"compute node object. However, there is `code`_ in the"},{"line_number":57,"context_line":"``ComputeNode._from_db_obj`` that, upon **reading** the record back from the"},{"line_number":58,"context_line":"database on first save, changes the values from ``0.0`` to ``16.0``, ``1.5`` or"},{"line_number":59,"context_line":"``1.0``."},{"line_number":60,"context_line":""},{"line_number":61,"context_line":".. _code: https://github.com/openstack/nova/blob/stable/queens/nova/objects/compute_node.py#L177-L207"},{"line_number":62,"context_line":""}],"source_content_type":"text/x-rst","patch_set":2,"id":"df7087c5_b53789ff","line":59,"updated":"2018-03-14 17:38:02.000000000","message":"That proxy code was originally written for upgrade purposes, in order to know whether an operator modified nova.conf or not.\nGiven the allocations were per-compute in Newton, it required some nova.conf modifications for operators wanting to define the ratios, hence that signal for knowing if they did so.","commit_id":"faff1da1305afa100f07bbd1a0d4a399d1baef99"},{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"2c18c99062d81ee83945fc061381c1a22eca0b37","unresolved":false,"context_lines":[{"line_number":64,"context_line":"these new values for some period of time while the record in the"},{"line_number":65,"context_line":"``compute_nodes`` table continues to have the wrong ``0.0`` values. When the"},{"line_number":66,"context_line":"resource tracker runs its ``update_available_resource()`` next perioidic task,"},{"line_number":67,"context_line":"the new ``16.0``/``1.5``/``1.0`` values are then save to the compute nodes"},{"line_number":68,"context_line":"table. So, for some amount of time -- typically around 5-15 minutes -- the"},{"line_number":69,"context_line":"resource usages reported by the compute node are incorrect (due to the"},{"line_number":70,"context_line":"allocation ratio of 0.0 being multiplied by the total amount in inventory,"}],"source_content_type":"text/x-rst","patch_set":2,"id":"df7087c5_06bafbbf","line":67,"range":{"start_line":67,"start_character":49,"end_line":67,"end_character":53},"updated":"2018-03-13 09:26:26.000000000","message":"nit: saved","commit_id":"faff1da1305afa100f07bbd1a0d4a399d1baef99"},{"author":{"_account_id":7166,"name":"Sylvain Bauza","email":"sbauza@redhat.com","username":"sbauza"},"change_message_id":"eea36bb87db4a3a6a3895a4481e3bae363056da8","unresolved":false,"context_lines":[{"line_number":68,"context_line":"table. So, for some amount of time -- typically around 5-15 minutes -- the"},{"line_number":69,"context_line":"resource usages reported by the compute node are incorrect (due to the"},{"line_number":70,"context_line":"allocation ratio of 0.0 being multiplied by the total amount in inventory,"},{"line_number":71,"context_line":"leading to 0 resources shown on the system)."},{"line_number":72,"context_line":""},{"line_number":73,"context_line":"Admins cannot manually set allocation ratios"},{"line_number":74,"context_line":"--------------------------------------------"}],"source_content_type":"text/x-rst","patch_set":2,"id":"df7087c5_753d71db","line":71,"updated":"2018-03-14 17:38:02.000000000","message":"snap...","commit_id":"faff1da1305afa100f07bbd1a0d4a399d1baef99"},{"author":{"_account_id":7166,"name":"Sylvain Bauza","email":"sbauza@redhat.com","username":"sbauza"},"change_message_id":"eea36bb87db4a3a6a3895a4481e3bae363056da8","unresolved":false,"context_lines":[{"line_number":77,"context_line":"set, there is currently no way for an admin to set the allocation ratio on an"},{"line_number":78,"context_line":"individual compute node without the resource tracker eventually overwriting"},{"line_number":79,"context_line":"that value the next time it runs the ``update_available_resources`` periodic"},{"line_number":80,"context_line":"task on the ``nova-compute`` service."},{"line_number":81,"context_line":""},{"line_number":82,"context_line":"Furthermore, due to the way that default values for allocation ratios are"},{"line_number":83,"context_line":"calculated in the ``ComputeNode._from_db_obj()`` method, there is no way to"}],"source_content_type":"text/x-rst","patch_set":2,"id":"df7087c5_55114d5c","line":80,"updated":"2018-03-14 17:38:02.000000000","message":"well, we don\u0027t expect those ratios to change over the lifecycle of a compute node, right?\nTo be clear, I\u0027m not a super fan of the idea to leave operators dynamically modifying ratios and expecting things to change immediatly. If that\u0027s something Nova does, cool, but that\u0027s not something we should clearly support IMHO.\n\nIf folks want dynamic workload attributions, just play with aggregates.","commit_id":"faff1da1305afa100f07bbd1a0d4a399d1baef99"},{"author":{"_account_id":7,"name":"Jay Pipes","email":"jaypipes@gmail.com","username":"jaypipes"},"change_message_id":"62a110218637849d93f5fabbc65381d1e14561db","unresolved":false,"context_lines":[{"line_number":77,"context_line":"set, there is currently no way for an admin to set the allocation ratio on an"},{"line_number":78,"context_line":"individual compute node without the resource tracker eventually overwriting"},{"line_number":79,"context_line":"that value the next time it runs the ``update_available_resources`` periodic"},{"line_number":80,"context_line":"task on the ``nova-compute`` service."},{"line_number":81,"context_line":""},{"line_number":82,"context_line":"Furthermore, due to the way that default values for allocation ratios are"},{"line_number":83,"context_line":"calculated in the ``ComputeNode._from_db_obj()`` method, there is no way to"}],"source_content_type":"text/x-rst","patch_set":2,"id":"9f6a8fd7_246c969a","line":80,"in_reply_to":"df7087c5_55114d5c","updated":"2018-04-24 15:19:39.000000000","message":"Yes, allocation ratios can and do change over the lifetime of a compute node.\n\nI\u0027m not sure what you mean by \"if folks want dynamic workload attributions, just play with aggregates\"?\n\nThe idea, long-term, is that allocation ratios would no longer be a thing that is associated with an aggregate (i.e. aggregate metadata) due to the problem of how to determine the appropriate allocation ratio if a resource provider is in multiple aggregates that each have a different allocation ratio.","commit_id":"faff1da1305afa100f07bbd1a0d4a399d1baef99"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"5d0e25a0d1963c68293be4614103e80f1eff610d","unresolved":false,"context_lines":[{"line_number":79,"context_line":"that value the next time it runs the ``update_available_resources`` periodic"},{"line_number":80,"context_line":"task on the ``nova-compute`` service."},{"line_number":81,"context_line":""},{"line_number":82,"context_line":"Furthermore, due to the way that default values for allocation ratios are"},{"line_number":83,"context_line":"calculated in the ``ComputeNode._from_db_obj()`` method, there is no way to"},{"line_number":84,"context_line":"differentiate between a situation where the deployer really does want to always"},{"line_number":85,"context_line":"override the ``cpu_allocation_ratio`` on a compute host to some value or a"},{"line_number":86,"context_line":"situation where a deployer just wishes to indicate the value for an allocation"},{"line_number":87,"context_line":"ratio the **first time** a compute service starts up, but allow an admin to"},{"line_number":88,"context_line":"override this allocation ratio afterwards."},{"line_number":89,"context_line":""},{"line_number":90,"context_line":"Use Cases"},{"line_number":91,"context_line":"---------"}],"source_content_type":"text/x-rst","patch_set":2,"id":"df7087c5_a22c3202","line":88,"range":{"start_line":82,"start_character":0,"end_line":88,"end_character":42},"updated":"2018-03-14 14:26:08.000000000","message":"I\u0027m not sure I get this. If cpu_allocation_ratio is set, we should override the value any time we update the compute node in our database, no? If only default_ is set, then we just do it at create() time.\n\nI don\u0027t see why the semantics are any different for our computenode records vs. placement.","commit_id":"faff1da1305afa100f07bbd1a0d4a399d1baef99"},{"author":{"_account_id":7,"name":"Jay Pipes","email":"jaypipes@gmail.com","username":"jaypipes"},"change_message_id":"62a110218637849d93f5fabbc65381d1e14561db","unresolved":false,"context_lines":[{"line_number":79,"context_line":"that value the next time it runs the ``update_available_resources`` periodic"},{"line_number":80,"context_line":"task on the ``nova-compute`` service."},{"line_number":81,"context_line":""},{"line_number":82,"context_line":"Furthermore, due to the way that default values for allocation ratios are"},{"line_number":83,"context_line":"calculated in the ``ComputeNode._from_db_obj()`` method, there is no way to"},{"line_number":84,"context_line":"differentiate between a situation where the deployer really does want to always"},{"line_number":85,"context_line":"override the ``cpu_allocation_ratio`` on a compute host to some value or a"},{"line_number":86,"context_line":"situation where a deployer just wishes to indicate the value for an allocation"},{"line_number":87,"context_line":"ratio the **first time** a compute service starts up, but allow an admin to"},{"line_number":88,"context_line":"override this allocation ratio afterwards."},{"line_number":89,"context_line":""},{"line_number":90,"context_line":"Use Cases"},{"line_number":91,"context_line":"---------"}],"source_content_type":"text/x-rst","patch_set":2,"id":"9f6a8fd7_0452b23b","line":88,"range":{"start_line":82,"start_character":0,"end_line":88,"end_character":42},"in_reply_to":"df7087c5_303aa7cb","updated":"2018-04-24 15:19:39.000000000","message":"I don\u0027t disagree. I\u0027m just saying CONF values cannot/should not be used in the ComputeNode._from_db_obj() method since that can run on both the compute node as well as the controller, resulting in different CONF values.","commit_id":"faff1da1305afa100f07bbd1a0d4a399d1baef99"},{"author":{"_account_id":7,"name":"Jay Pipes","email":"jaypipes@gmail.com","username":"jaypipes"},"change_message_id":"62a110218637849d93f5fabbc65381d1e14561db","unresolved":false,"context_lines":[{"line_number":79,"context_line":"that value the next time it runs the ``update_available_resources`` periodic"},{"line_number":80,"context_line":"task on the ``nova-compute`` service."},{"line_number":81,"context_line":""},{"line_number":82,"context_line":"Furthermore, due to the way that default values for allocation ratios are"},{"line_number":83,"context_line":"calculated in the ``ComputeNode._from_db_obj()`` method, there is no way to"},{"line_number":84,"context_line":"differentiate between a situation where the deployer really does want to always"},{"line_number":85,"context_line":"override the ``cpu_allocation_ratio`` on a compute host to some value or a"},{"line_number":86,"context_line":"situation where a deployer just wishes to indicate the value for an allocation"},{"line_number":87,"context_line":"ratio the **first time** a compute service starts up, but allow an admin to"},{"line_number":88,"context_line":"override this allocation ratio afterwards."},{"line_number":89,"context_line":""},{"line_number":90,"context_line":"Use Cases"},{"line_number":91,"context_line":"---------"}],"source_content_type":"text/x-rst","patch_set":2,"id":"9f6a8fd7_c4a03a45","line":88,"range":{"start_line":82,"start_character":0,"end_line":88,"end_character":42},"in_reply_to":"df7087c5_a22c3202","updated":"2018-04-24 15:19:39.000000000","message":"The key to the question above is \"the way the default values ... are calculated **in ComputeNode._from_db_obj()**\".\n\nhttps://github.com/openstack/nova/blob/master/nova/objects/compute_node.py#L177-L207\n\n if value \u003d\u003d 0.0:\n     # Operator has not yet provided a new value for that ratio\n     # on the compute node\n     value \u003d None\n if value is None:\n     # ResourceTracker is not updating the value (old node)\n     # or the compute node is updated but the default value has\n     # not been changed\n\nWith all the mucking around with 0.0-valued allocation ratios, I have honestly no idea whether any of the above code is valid or whether it\u0027s all just irrelevant any more. And, furthermore, because the above code can execute on either a controller or a compute node, using CONF options (including the proposed CONF.default_xxx_allocation_ratio options in this spec) would make the _from_db_obj() non-deterministic depending on where the code ran.\n\nAll this to say, basically, \"please, let us remove ALL of this type of code from the ComputeNode._from_db_obj() method\"","commit_id":"faff1da1305afa100f07bbd1a0d4a399d1baef99"},{"author":{"_account_id":7166,"name":"Sylvain Bauza","email":"sbauza@redhat.com","username":"sbauza"},"change_message_id":"eea36bb87db4a3a6a3895a4481e3bae363056da8","unresolved":false,"context_lines":[{"line_number":79,"context_line":"that value the next time it runs the ``update_available_resources`` periodic"},{"line_number":80,"context_line":"task on the ``nova-compute`` service."},{"line_number":81,"context_line":""},{"line_number":82,"context_line":"Furthermore, due to the way that default values for allocation ratios are"},{"line_number":83,"context_line":"calculated in the ``ComputeNode._from_db_obj()`` method, there is no way to"},{"line_number":84,"context_line":"differentiate between a situation where the deployer really does want to always"},{"line_number":85,"context_line":"override the ``cpu_allocation_ratio`` on a compute host to some value or a"},{"line_number":86,"context_line":"situation where a deployer just wishes to indicate the value for an allocation"},{"line_number":87,"context_line":"ratio the **first time** a compute service starts up, but allow an admin to"},{"line_number":88,"context_line":"override this allocation ratio afterwards."},{"line_number":89,"context_line":""},{"line_number":90,"context_line":"Use Cases"},{"line_number":91,"context_line":"---------"}],"source_content_type":"text/x-rst","patch_set":2,"id":"df7087c5_303aa7cb","line":88,"range":{"start_line":82,"start_character":0,"end_line":88,"end_character":42},"in_reply_to":"df7087c5_a22c3202","updated":"2018-03-14 17:38:02.000000000","message":"Yup, I agree with Dan. From a logical perspective, the conf value defines the behaviour.","commit_id":"faff1da1305afa100f07bbd1a0d4a399d1baef99"},{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"2c18c99062d81ee83945fc061381c1a22eca0b37","unresolved":false,"context_lines":[{"line_number":100,"context_line":"First, change the resource tracker to **not always overwrite** the compute"},{"line_number":101,"context_line":"node\u0027s allocation ratios to the value of the ``cpu_allocation_ratio``,"},{"line_number":102,"context_line":"``ram_allocation_ratio`` and ``disk_allocation_ratio`` CONF options **unless"},{"line_number":103,"context_line":"the value of these options is NOT ``0.0``**. In other words, if any of these"},{"line_number":104,"context_line":"CONF options is set to something *other than* ``0.0``, then the CONF option"},{"line_number":105,"context_line":"should be considered the complete override value for that resource class\u0027"},{"line_number":106,"context_line":"allocation ratio. Even if an admin manually adjusts the allocation ratio of the"},{"line_number":107,"context_line":"resource class in the placement API, the next time the"},{"line_number":108,"context_line":"``update_available_resource()`` periodic task runs, it will be overwritten to"},{"line_number":109,"context_line":"the value of the CONF option."}],"source_content_type":"text/x-rst","patch_set":2,"id":"df7087c5_461f93b6","line":106,"range":{"start_line":103,"start_character":45,"end_line":106,"end_character":17},"updated":"2018-03-13 09:26:26.000000000","message":"I did not understand the first sentence but I do understand this. So thanks for adding this second definition.","commit_id":"faff1da1305afa100f07bbd1a0d4a399d1baef99"},{"author":{"_account_id":14070,"name":"Eric Fried","email":"openstack@fried.cc","username":"efried"},"change_message_id":"e89911c95647c80adab2a3a06e3e39deb23ba65c","unresolved":false,"context_lines":[{"line_number":100,"context_line":"First, change the resource tracker to **not always overwrite** the compute"},{"line_number":101,"context_line":"node\u0027s allocation ratios to the value of the ``cpu_allocation_ratio``,"},{"line_number":102,"context_line":"``ram_allocation_ratio`` and ``disk_allocation_ratio`` CONF options **unless"},{"line_number":103,"context_line":"the value of these options is NOT ``0.0``**. In other words, if any of these"},{"line_number":104,"context_line":"CONF options is set to something *other than* ``0.0``, then the CONF option"},{"line_number":105,"context_line":"should be considered the complete override value for that resource class\u0027"},{"line_number":106,"context_line":"allocation ratio. Even if an admin manually adjusts the allocation ratio of the"},{"line_number":107,"context_line":"resource class in the placement API, the next time the"},{"line_number":108,"context_line":"``update_available_resource()`` periodic task runs, it will be overwritten to"},{"line_number":109,"context_line":"the value of the CONF option."}],"source_content_type":"text/x-rst","patch_set":2,"id":"df7087c5_bbaaca6e","line":106,"range":{"start_line":103,"start_character":45,"end_line":106,"end_character":17},"in_reply_to":"df7087c5_461f93b6","updated":"2018-03-17 22:42:12.000000000","message":"Agree; the three negatives in the first sentence make for pretty confusing reading.  If I can restate:\n\nThe resource tracker will overwrite the resource\u0027s allocation ratio to the conf value if and only the conf value is nonzero.\n\nTrue?","commit_id":"faff1da1305afa100f07bbd1a0d4a399d1baef99"},{"author":{"_account_id":7,"name":"Jay Pipes","email":"jaypipes@gmail.com","username":"jaypipes"},"change_message_id":"62a110218637849d93f5fabbc65381d1e14561db","unresolved":false,"context_lines":[{"line_number":100,"context_line":"First, change the resource tracker to **not always overwrite** the compute"},{"line_number":101,"context_line":"node\u0027s allocation ratios to the value of the ``cpu_allocation_ratio``,"},{"line_number":102,"context_line":"``ram_allocation_ratio`` and ``disk_allocation_ratio`` CONF options **unless"},{"line_number":103,"context_line":"the value of these options is NOT ``0.0``**. In other words, if any of these"},{"line_number":104,"context_line":"CONF options is set to something *other than* ``0.0``, then the CONF option"},{"line_number":105,"context_line":"should be considered the complete override value for that resource class\u0027"},{"line_number":106,"context_line":"allocation ratio. Even if an admin manually adjusts the allocation ratio of the"},{"line_number":107,"context_line":"resource class in the placement API, the next time the"},{"line_number":108,"context_line":"``update_available_resource()`` periodic task runs, it will be overwritten to"},{"line_number":109,"context_line":"the value of the CONF option."}],"source_content_type":"text/x-rst","patch_set":2,"id":"9f6a8fd7_842242b8","line":106,"range":{"start_line":103,"start_character":45,"end_line":106,"end_character":17},"in_reply_to":"df7087c5_bbaaca6e","updated":"2018-04-24 15:19:39.000000000","message":"Done","commit_id":"faff1da1305afa100f07bbd1a0d4a399d1baef99"},{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"2c18c99062d81ee83945fc061381c1a22eca0b37","unresolved":false,"context_lines":[{"line_number":103,"context_line":"the value of these options is NOT ``0.0``**. In other words, if any of these"},{"line_number":104,"context_line":"CONF options is set to something *other than* ``0.0``, then the CONF option"},{"line_number":105,"context_line":"should be considered the complete override value for that resource class\u0027"},{"line_number":106,"context_line":"allocation ratio. Even if an admin manually adjusts the allocation ratio of the"},{"line_number":107,"context_line":"resource class in the placement API, the next time the"},{"line_number":108,"context_line":"``update_available_resource()`` periodic task runs, it will be overwritten to"},{"line_number":109,"context_line":"the value of the CONF option."},{"line_number":110,"context_line":""},{"line_number":111,"context_line":"Add three new CONF options to the nova.conf file:"},{"line_number":112,"context_line":""}],"source_content_type":"text/x-rst","patch_set":2,"id":"df7087c5_e6d347d4","line":109,"range":{"start_line":106,"start_character":18,"end_line":109,"end_character":29},"updated":"2018-03-13 09:26:26.000000000","message":"Do I understand correctly that the deployer needs to use 0.0 to signal to the resource tracker that the admin can override  that allocation ratio in placement? Or we don\u0027t want to define this behavior in this spec.","commit_id":"faff1da1305afa100f07bbd1a0d4a399d1baef99"},{"author":{"_account_id":7,"name":"Jay Pipes","email":"jaypipes@gmail.com","username":"jaypipes"},"change_message_id":"62a110218637849d93f5fabbc65381d1e14561db","unresolved":false,"context_lines":[{"line_number":103,"context_line":"the value of these options is NOT ``0.0``**. In other words, if any of these"},{"line_number":104,"context_line":"CONF options is set to something *other than* ``0.0``, then the CONF option"},{"line_number":105,"context_line":"should be considered the complete override value for that resource class\u0027"},{"line_number":106,"context_line":"allocation ratio. Even if an admin manually adjusts the allocation ratio of the"},{"line_number":107,"context_line":"resource class in the placement API, the next time the"},{"line_number":108,"context_line":"``update_available_resource()`` periodic task runs, it will be overwritten to"},{"line_number":109,"context_line":"the value of the CONF option."},{"line_number":110,"context_line":""},{"line_number":111,"context_line":"Add three new CONF options to the nova.conf file:"},{"line_number":112,"context_line":""}],"source_content_type":"text/x-rst","patch_set":2,"id":"9f6a8fd7_8739e4d7","line":109,"range":{"start_line":106,"start_character":18,"end_line":109,"end_character":29},"in_reply_to":"df7087c5_e6d347d4","updated":"2018-04-24 15:19:39.000000000","message":"Yes, that is correct. The reason for that is the fact that the default for cpu_allocation_ratio is 16.0, not None.","commit_id":"faff1da1305afa100f07bbd1a0d4a399d1baef99"},{"author":{"_account_id":25625,"name":"Tetsuro Nakamura","email":"tetsuro.nakamura.bc@hco.ntt.co.jp","username":"tetsuro0907"},"change_message_id":"aa5c1bdf3cff8bad8a745810556e47c5fa47ab75","unresolved":false,"context_lines":[{"line_number":114,"context_line":"* ``default_ram_allocation_ratio``"},{"line_number":115,"context_line":"* ``default_disk_allocation_ratio``"},{"line_number":116,"context_line":""},{"line_number":117,"context_line":"The default value of each CONF option shall be ``None``."},{"line_number":118,"context_line":""},{"line_number":119,"context_line":"These new ``default_xxx_allocation_ratio`` CONF options shall **ONLY** be used"},{"line_number":120,"context_line":"if the resource tracker detects no existing record in the ``compute_nodes``"}],"source_content_type":"text/x-rst","patch_set":2,"id":"df7087c5_18fb4147","line":117,"range":{"start_line":117,"start_character":0,"end_line":117,"end_character":56},"updated":"2018-03-13 04:44:01.000000000","message":"Let me consider the case deploying a new compute node with neither \"default_XXX_allocation_ratio\" nor  \"XXX_allocation_ratio\" specified. That compute node\u0027s ratios are all 0.0 unless someone sets the value via something. So doesn\u0027t this result in forcing admin (or deployer) to always set them manually? If so, I\u0027d like these values to default to 16.0, 1.5, and 1.0 respectively.","commit_id":"faff1da1305afa100f07bbd1a0d4a399d1baef99"},{"author":{"_account_id":7,"name":"Jay Pipes","email":"jaypipes@gmail.com","username":"jaypipes"},"change_message_id":"62a110218637849d93f5fabbc65381d1e14561db","unresolved":false,"context_lines":[{"line_number":114,"context_line":"* ``default_ram_allocation_ratio``"},{"line_number":115,"context_line":"* ``default_disk_allocation_ratio``"},{"line_number":116,"context_line":""},{"line_number":117,"context_line":"The default value of each CONF option shall be ``None``."},{"line_number":118,"context_line":""},{"line_number":119,"context_line":"These new ``default_xxx_allocation_ratio`` CONF options shall **ONLY** be used"},{"line_number":120,"context_line":"if the resource tracker detects no existing record in the ``compute_nodes``"}],"source_content_type":"text/x-rst","patch_set":2,"id":"9f6a8fd7_c7f4bcf3","line":117,"range":{"start_line":117,"start_character":0,"end_line":117,"end_character":56},"in_reply_to":"df7087c5_18fb4147","updated":"2018-04-24 15:19:39.000000000","message":"\u003e Let me consider the case deploying a new compute node with neither\n \u003e \"default_XXX_allocation_ratio\" nor  \"XXX_allocation_ratio\"\n \u003e specified. That compute node\u0027s ratios are all 0.0 unless someone\n \u003e sets the value via something. So doesn\u0027t this result in forcing\n \u003e admin (or deployer) to always set them manually? If so, I\u0027d like\n \u003e these values to default to 16.0, 1.5, and 1.0 respectively.\n\nWell, that is why the code in ComputeNode._from_db_obj() was added:\n\nhttps://github.com/openstack/nova/blob/master/nova/objects/compute_node.py#L177-L207\n\nThe problem with that code is that it embeds logic about defaulting configuration settings into an object constructor. Since that code can run on either a controller node or a compute node, it cannot reliably use CONF option values (since those CONF option values could be different between the compute node and the controller node).","commit_id":"faff1da1305afa100f07bbd1a0d4a399d1baef99"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"5d0e25a0d1963c68293be4614103e80f1eff610d","unresolved":false,"context_lines":[{"line_number":114,"context_line":"* ``default_ram_allocation_ratio``"},{"line_number":115,"context_line":"* ``default_disk_allocation_ratio``"},{"line_number":116,"context_line":""},{"line_number":117,"context_line":"The default value of each CONF option shall be ``None``."},{"line_number":118,"context_line":""},{"line_number":119,"context_line":"These new ``default_xxx_allocation_ratio`` CONF options shall **ONLY** be used"},{"line_number":120,"context_line":"if the resource tracker detects no existing record in the ``compute_nodes``"}],"source_content_type":"text/x-rst","patch_set":2,"id":"df7087c5_a290b244","line":117,"range":{"start_line":117,"start_character":0,"end_line":117,"end_character":56},"in_reply_to":"df7087c5_18fb4147","updated":"2018-03-14 14:26:08.000000000","message":"Agreed, I think that the defaults for these need to now be the defaults from the old parameters. That way we create things with the same behavior as we did before. If we want to change those (insane) values then that\u0027s cool, but they should always be set and should contain what we want our defaults to be.","commit_id":"faff1da1305afa100f07bbd1a0d4a399d1baef99"},{"author":{"_account_id":24791,"name":"Maciej Jozefczyk","email":"jeicam.pl@gmail.com","username":"maciej.jozefczyk"},"change_message_id":"3865233ba647eddbc3cf1ed090c2e6d5189cd2de","unresolved":false,"context_lines":[{"line_number":114,"context_line":"* ``default_ram_allocation_ratio``"},{"line_number":115,"context_line":"* ``default_disk_allocation_ratio``"},{"line_number":116,"context_line":""},{"line_number":117,"context_line":"The default value of each CONF option shall be ``None``."},{"line_number":118,"context_line":""},{"line_number":119,"context_line":"These new ``default_xxx_allocation_ratio`` CONF options shall **ONLY** be used"},{"line_number":120,"context_line":"if the resource tracker detects no existing record in the ``compute_nodes``"}],"source_content_type":"text/x-rst","patch_set":2,"id":"df7087c5_0e0af677","line":117,"range":{"start_line":117,"start_character":0,"end_line":117,"end_character":56},"in_reply_to":"df7087c5_a290b244","updated":"2018-03-23 15:36:17.000000000","message":"+1 for settings default values respectively. \n\nWhat about minimum value? Do we want to support -1.0 allocation ratio :)?","commit_id":"faff1da1305afa100f07bbd1a0d4a399d1baef99"},{"author":{"_account_id":7,"name":"Jay Pipes","email":"jaypipes@gmail.com","username":"jaypipes"},"change_message_id":"62a110218637849d93f5fabbc65381d1e14561db","unresolved":false,"context_lines":[{"line_number":114,"context_line":"* ``default_ram_allocation_ratio``"},{"line_number":115,"context_line":"* ``default_disk_allocation_ratio``"},{"line_number":116,"context_line":""},{"line_number":117,"context_line":"The default value of each CONF option shall be ``None``."},{"line_number":118,"context_line":""},{"line_number":119,"context_line":"These new ``default_xxx_allocation_ratio`` CONF options shall **ONLY** be used"},{"line_number":120,"context_line":"if the resource tracker detects no existing record in the ``compute_nodes``"}],"source_content_type":"text/x-rst","patch_set":2,"id":"9f6a8fd7_87f6c4d6","line":117,"range":{"start_line":117,"start_character":0,"end_line":117,"end_character":56},"in_reply_to":"df7087c5_a290b244","updated":"2018-04-24 15:19:39.000000000","message":"done.","commit_id":"faff1da1305afa100f07bbd1a0d4a399d1baef99"},{"author":{"_account_id":24791,"name":"Maciej Jozefczyk","email":"jeicam.pl@gmail.com","username":"maciej.jozefczyk"},"change_message_id":"3865233ba647eddbc3cf1ed090c2e6d5189cd2de","unresolved":false,"context_lines":[{"line_number":116,"context_line":""},{"line_number":117,"context_line":"The default value of each CONF option shall be ``None``."},{"line_number":118,"context_line":""},{"line_number":119,"context_line":"These new ``default_xxx_allocation_ratio`` CONF options shall **ONLY** be used"},{"line_number":120,"context_line":"if the resource tracker detects no existing record in the ``compute_nodes``"},{"line_number":121,"context_line":"nova cell DB for that hypervisor."},{"line_number":122,"context_line":""}],"source_content_type":"text/x-rst","patch_set":2,"id":"df7087c5_6eccd234","line":119,"range":{"start_line":119,"start_character":12,"end_line":119,"end_character":40},"updated":"2018-03-23 15:36:17.000000000","message":"Maybe lets call it initial_xxx_allocation_ratio ?","commit_id":"faff1da1305afa100f07bbd1a0d4a399d1baef99"},{"author":{"_account_id":7,"name":"Jay Pipes","email":"jaypipes@gmail.com","username":"jaypipes"},"change_message_id":"62a110218637849d93f5fabbc65381d1e14561db","unresolved":false,"context_lines":[{"line_number":116,"context_line":""},{"line_number":117,"context_line":"The default value of each CONF option shall be ``None``."},{"line_number":118,"context_line":""},{"line_number":119,"context_line":"These new ``default_xxx_allocation_ratio`` CONF options shall **ONLY** be used"},{"line_number":120,"context_line":"if the resource tracker detects no existing record in the ``compute_nodes``"},{"line_number":121,"context_line":"nova cell DB for that hypervisor."},{"line_number":122,"context_line":""}],"source_content_type":"text/x-rst","patch_set":2,"id":"9f6a8fd7_0734f491","line":119,"range":{"start_line":119,"start_character":12,"end_line":119,"end_character":40},"in_reply_to":"df7087c5_6eccd234","updated":"2018-04-24 15:19:39.000000000","message":"I could go for either.","commit_id":"faff1da1305afa100f07bbd1a0d4a399d1baef99"},{"author":{"_account_id":11564,"name":"Chris Dent","email":"cdent@anticdent.org","username":"chdent"},"change_message_id":"c97bff2793281718cd4f037ec4ecf65fd79b1787","unresolved":false,"context_lines":[{"line_number":118,"context_line":""},{"line_number":119,"context_line":"These new ``default_xxx_allocation_ratio`` CONF options shall **ONLY** be used"},{"line_number":120,"context_line":"if the resource tracker detects no existing record in the ``compute_nodes``"},{"line_number":121,"context_line":"nova cell DB for that hypervisor."},{"line_number":122,"context_line":""},{"line_number":123,"context_line":"Remove the code in the ``nova.objects.ComputeNode._from_db_obj`` that adjusts"},{"line_number":124,"context_line":"allocation ratios.`"}],"source_content_type":"text/x-rst","patch_set":2,"id":"df7087c5_40d9b27c","line":121,"updated":"2018-03-13 12:17:17.000000000","message":"Do we want a paragraph for what happens when cpu_allocation_ratio and default_cpu_allocation_ratio are both set?\n\nI\u0027d say \"yes\" because I\u0027m not sure I know the answer. I think the desired config is set default* to some value and set * to 0.0 and you\u0027ll get default and future changes can be managed by the API. But what happens is both are set to not None, not 0?","commit_id":"faff1da1305afa100f07bbd1a0d4a399d1baef99"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"5d0e25a0d1963c68293be4614103e80f1eff610d","unresolved":false,"context_lines":[{"line_number":118,"context_line":""},{"line_number":119,"context_line":"These new ``default_xxx_allocation_ratio`` CONF options shall **ONLY** be used"},{"line_number":120,"context_line":"if the resource tracker detects no existing record in the ``compute_nodes``"},{"line_number":121,"context_line":"nova cell DB for that hypervisor."},{"line_number":122,"context_line":""},{"line_number":123,"context_line":"Remove the code in the ``nova.objects.ComputeNode._from_db_obj`` that adjusts"},{"line_number":124,"context_line":"allocation ratios.`"}],"source_content_type":"text/x-rst","patch_set":2,"id":"df7087c5_82b48ed2","line":121,"in_reply_to":"df7087c5_40d9b27c","updated":"2018-03-14 14:26:08.000000000","message":"I think if the non-default ones are set, they always win, even for the first creation of the provider. It wouldn\u0027t make sense to create it with default_foo and then immediately overwrite it with foo on the next periodic.","commit_id":"faff1da1305afa100f07bbd1a0d4a399d1baef99"},{"author":{"_account_id":14070,"name":"Eric Fried","email":"openstack@fried.cc","username":"efried"},"change_message_id":"e89911c95647c80adab2a3a06e3e39deb23ba65c","unresolved":false,"context_lines":[{"line_number":121,"context_line":"nova cell DB for that hypervisor."},{"line_number":122,"context_line":""},{"line_number":123,"context_line":"Remove the code in the ``nova.objects.ComputeNode._from_db_obj`` that adjusts"},{"line_number":124,"context_line":"allocation ratios.`"},{"line_number":125,"context_line":""},{"line_number":126,"context_line":"Alternatives"},{"line_number":127,"context_line":"------------"}],"source_content_type":"text/x-rst","patch_set":2,"id":"df7087c5_5bb5aecc","line":124,"range":{"start_line":124,"start_character":18,"end_line":124,"end_character":19},"updated":"2018-03-17 22:42:12.000000000","message":"strike","commit_id":"faff1da1305afa100f07bbd1a0d4a399d1baef99"},{"author":{"_account_id":7,"name":"Jay Pipes","email":"jaypipes@gmail.com","username":"jaypipes"},"change_message_id":"62a110218637849d93f5fabbc65381d1e14561db","unresolved":false,"context_lines":[{"line_number":121,"context_line":"nova cell DB for that hypervisor."},{"line_number":122,"context_line":""},{"line_number":123,"context_line":"Remove the code in the ``nova.objects.ComputeNode._from_db_obj`` that adjusts"},{"line_number":124,"context_line":"allocation ratios.`"},{"line_number":125,"context_line":""},{"line_number":126,"context_line":"Alternatives"},{"line_number":127,"context_line":"------------"}],"source_content_type":"text/x-rst","patch_set":2,"id":"9f6a8fd7_47150ce4","line":124,"range":{"start_line":124,"start_character":18,"end_line":124,"end_character":19},"in_reply_to":"df7087c5_5bb5aecc","updated":"2018-04-24 15:19:39.000000000","message":"Done","commit_id":"faff1da1305afa100f07bbd1a0d4a399d1baef99"},{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"2c18c99062d81ee83945fc061381c1a22eca0b37","unresolved":false,"context_lines":[{"line_number":122,"context_line":""},{"line_number":123,"context_line":"Remove the code in the ``nova.objects.ComputeNode._from_db_obj`` that adjusts"},{"line_number":124,"context_line":"allocation ratios.`"},{"line_number":125,"context_line":""},{"line_number":126,"context_line":"Alternatives"},{"line_number":127,"context_line":"------------"},{"line_number":128,"context_line":""}],"source_content_type":"text/x-rst","patch_set":2,"id":"df7087c5_e1ba516c","line":125,"updated":"2018-03-13 09:26:26.000000000","message":"I think we can have allocation ratio configs set in the controller config as well[1]. Are those only used in the now defunct scheduler filters?\n\n[1] https://github.com/openstack/nova/blob/9a497671342f0f15538b68bb7ee8f0c7ba3e66fe/nova/conf/compute.py#L416-L418","commit_id":"faff1da1305afa100f07bbd1a0d4a399d1baef99"},{"author":{"_account_id":7166,"name":"Sylvain Bauza","email":"sbauza@redhat.com","username":"sbauza"},"change_message_id":"eea36bb87db4a3a6a3895a4481e3bae363056da8","unresolved":false,"context_lines":[{"line_number":122,"context_line":""},{"line_number":123,"context_line":"Remove the code in the ``nova.objects.ComputeNode._from_db_obj`` that adjusts"},{"line_number":124,"context_line":"allocation ratios.`"},{"line_number":125,"context_line":""},{"line_number":126,"context_line":"Alternatives"},{"line_number":127,"context_line":"------------"},{"line_number":128,"context_line":""}],"source_content_type":"text/x-rst","patch_set":2,"id":"df7087c5_9077f3a0","line":125,"in_reply_to":"df7087c5_62e4dae0","updated":"2018-03-14 17:38:02.000000000","message":"Keep also in mind we have old compute nodes that don\u0027t have the new config options, so we necessarly need to remove that reconciling logic in the object only in the next cycle.","commit_id":"faff1da1305afa100f07bbd1a0d4a399d1baef99"},{"author":{"_account_id":7,"name":"Jay Pipes","email":"jaypipes@gmail.com","username":"jaypipes"},"change_message_id":"62a110218637849d93f5fabbc65381d1e14561db","unresolved":false,"context_lines":[{"line_number":122,"context_line":""},{"line_number":123,"context_line":"Remove the code in the ``nova.objects.ComputeNode._from_db_obj`` that adjusts"},{"line_number":124,"context_line":"allocation ratios.`"},{"line_number":125,"context_line":""},{"line_number":126,"context_line":"Alternatives"},{"line_number":127,"context_line":"------------"},{"line_number":128,"context_line":""}],"source_content_type":"text/x-rst","patch_set":2,"id":"9f6a8fd7_87e4840e","line":125,"in_reply_to":"df7087c5_9077f3a0","updated":"2018-04-24 15:19:39.000000000","message":"Sylvain, how can we possibly have compute nodes that don\u0027t have allocation ratios set?","commit_id":"faff1da1305afa100f07bbd1a0d4a399d1baef99"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"5d0e25a0d1963c68293be4614103e80f1eff610d","unresolved":false,"context_lines":[{"line_number":122,"context_line":""},{"line_number":123,"context_line":"Remove the code in the ``nova.objects.ComputeNode._from_db_obj`` that adjusts"},{"line_number":124,"context_line":"allocation ratios.`"},{"line_number":125,"context_line":""},{"line_number":126,"context_line":"Alternatives"},{"line_number":127,"context_line":"------------"},{"line_number":128,"context_line":""}],"source_content_type":"text/x-rst","patch_set":2,"id":"df7087c5_62e4dae0","line":125,"in_reply_to":"df7087c5_e1ba516c","updated":"2018-03-14 14:26:08.000000000","message":"Unfortunately they\u0027re not defunct, they\u0027re still needed/used if you use the cachingscheduler. However, I think it\u0027s fine to leave those values and their usage in the filters as they are until we completely remove them.","commit_id":"faff1da1305afa100f07bbd1a0d4a399d1baef99"},{"author":{"_account_id":14070,"name":"Eric Fried","email":"openstack@fried.cc","username":"efried"},"change_message_id":"e89911c95647c80adab2a3a06e3e39deb23ba65c","unresolved":false,"context_lines":[{"line_number":126,"context_line":"Alternatives"},{"line_number":127,"context_line":"------------"},{"line_number":128,"context_line":""},{"line_number":129,"context_line":"None"},{"line_number":130,"context_line":""},{"line_number":131,"context_line":"Data model impact"},{"line_number":132,"context_line":"-----------------"}],"source_content_type":"text/x-rst","patch_set":2,"id":"df7087c5_3be55add","line":129,"range":{"start_line":129,"start_character":0,"end_line":129,"end_character":4},"updated":"2018-03-17 22:42:12.000000000","message":"It seems like the obvious alternative is changing the defaults of the existing conf options.\n\nBut I think I remember talking to Matt about this, and he pointed out that we can\u0027t do that, because it has the potential to change stuff out from under existing deployments.  In this case, since it\u0027s already busted, I\u0027m not sure I see that being a problem.  But whether it is or not, it would be nice if that option were explained away here.  (I got the impression that this was a standing rule that should be obvious - but it wasn\u0027t obvious to me.)","commit_id":"faff1da1305afa100f07bbd1a0d4a399d1baef99"},{"author":{"_account_id":14070,"name":"Eric Fried","email":"openstack@fried.cc","username":"efried"},"change_message_id":"e89911c95647c80adab2a3a06e3e39deb23ba65c","unresolved":false,"context_lines":[{"line_number":127,"context_line":"------------"},{"line_number":128,"context_line":""},{"line_number":129,"context_line":"None"},{"line_number":130,"context_line":""},{"line_number":131,"context_line":"Data model impact"},{"line_number":132,"context_line":"-----------------"},{"line_number":133,"context_line":""}],"source_content_type":"text/x-rst","patch_set":2,"id":"df7087c5_fbce025a","line":130,"updated":"2018-03-17 22:42:12.000000000","message":"Another alternative that comes to mind: instead of adding the default_* conf options, what about a boolean conf option allow_allocation_ratio_override?  (Do we need that option to be settable separately for each of the three resource classes?)  If it\u0027s True, the RT doesn\u0027t overwrite from conf.","commit_id":"faff1da1305afa100f07bbd1a0d4a399d1baef99"},{"author":{"_account_id":24791,"name":"Maciej Jozefczyk","email":"jeicam.pl@gmail.com","username":"maciej.jozefczyk"},"change_message_id":"3865233ba647eddbc3cf1ed090c2e6d5189cd2de","unresolved":false,"context_lines":[{"line_number":189,"context_line":""},{"line_number":190,"context_line":"* Modify resource tracker to only set allocation ratios on the compute node"},{"line_number":191,"context_line":"  object when the CONF options are non- ``0.0``"},{"line_number":192,"context_line":"* Add new ``default_xxx_allocation_ratio`` CONF options and modify resource"},{"line_number":193,"context_line":"  tracker\u0027s initial compute node creation to use these values if non- ``None``"},{"line_number":194,"context_line":"* Remove code in the ``ComputeNode._from_db_obj()`` that changes allocation"},{"line_number":195,"context_line":"  ratio values"}],"source_content_type":"text/x-rst","patch_set":2,"id":"df7087c5_6e3372ac","line":192,"updated":"2018-03-23 15:36:17.000000000","message":"Or maybe name it ``initial_xxx_allocation_ratio``? Just to be clean thats about initialization.","commit_id":"faff1da1305afa100f07bbd1a0d4a399d1baef99"},{"author":{"_account_id":25625,"name":"Tetsuro Nakamura","email":"tetsuro.nakamura.bc@hco.ntt.co.jp","username":"tetsuro0907"},"change_message_id":"aa5c1bdf3cff8bad8a745810556e47c5fa47ab75","unresolved":false,"context_lines":[{"line_number":191,"context_line":"  object when the CONF options are non- ``0.0``"},{"line_number":192,"context_line":"* Add new ``default_xxx_allocation_ratio`` CONF options and modify resource"},{"line_number":193,"context_line":"  tracker\u0027s initial compute node creation to use these values if non- ``None``"},{"line_number":194,"context_line":"* Remove code in the ``ComputeNode._from_db_obj()`` that changes allocation"},{"line_number":195,"context_line":"  ratio values"},{"line_number":196,"context_line":""},{"line_number":197,"context_line":"Dependencies"},{"line_number":198,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"}],"source_content_type":"text/x-rst","patch_set":2,"id":"df7087c5_5829b9e3","line":195,"range":{"start_line":194,"start_character":0,"end_line":195,"end_character":14},"updated":"2018-03-13 04:44:01.000000000","message":"++!","commit_id":"faff1da1305afa100f07bbd1a0d4a399d1baef99"},{"author":{"_account_id":24791,"name":"Maciej Jozefczyk","email":"jeicam.pl@gmail.com","username":"maciej.jozefczyk"},"change_message_id":"3865233ba647eddbc3cf1ed090c2e6d5189cd2de","unresolved":false,"context_lines":[{"line_number":191,"context_line":"  object when the CONF options are non- ``0.0``"},{"line_number":192,"context_line":"* Add new ``default_xxx_allocation_ratio`` CONF options and modify resource"},{"line_number":193,"context_line":"  tracker\u0027s initial compute node creation to use these values if non- ``None``"},{"line_number":194,"context_line":"* Remove code in the ``ComputeNode._from_db_obj()`` that changes allocation"},{"line_number":195,"context_line":"  ratio values"},{"line_number":196,"context_line":""},{"line_number":197,"context_line":"Dependencies"},{"line_number":198,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"}],"source_content_type":"text/x-rst","patch_set":2,"id":"df7087c5_ee47821c","line":195,"range":{"start_line":194,"start_character":0,"end_line":195,"end_character":14},"in_reply_to":"df7087c5_5829b9e3","updated":"2018-03-23 15:36:17.000000000","message":"+1 for that :)","commit_id":"faff1da1305afa100f07bbd1a0d4a399d1baef99"},{"author":{"_account_id":15334,"name":"Stephen Finucane","display_name":"stephenfin","email":"stephenfin@redhat.com","username":"sfinucan"},"change_message_id":"1cc2e11f34b4baddfec3980552826523114b1242","unresolved":false,"context_lines":[{"line_number":10,"context_line":""},{"line_number":11,"context_line":"https://blueprints.launchpad.net/nova/+spec/default-allocation-ratios"},{"line_number":12,"context_line":""},{"line_number":13,"context_line":"We propose to add 3 new nova.conf configuration options that will used to"},{"line_number":14,"context_line":"determine how to set the *initial* allocation ratio of ``VCPU``, ``MEMORY_MB``"},{"line_number":15,"context_line":"and ``DISK_GB`` resource classes when a compute worker first starts up and"},{"line_number":16,"context_line":"creates its compute node record in the nova cell DB and corresponding inventory"}],"source_content_type":"text/x-rst","patch_set":3,"id":"5f7c97a3_96454118","line":13,"range":{"start_line":13,"start_character":18,"end_line":13,"end_character":19},"updated":"2018-06-05 15:31:01.000000000","message":"nit: three","commit_id":"2921d2be57438a8eb1d7a077ca71d2deafe27d31"},{"author":{"_account_id":14070,"name":"Eric Fried","email":"openstack@fried.cc","username":"efried"},"change_message_id":"0787330bee6c2970665c2482bf608d52d458d444","unresolved":false,"context_lines":[{"line_number":10,"context_line":""},{"line_number":11,"context_line":"https://blueprints.launchpad.net/nova/+spec/default-allocation-ratios"},{"line_number":12,"context_line":""},{"line_number":13,"context_line":"We propose to add 3 new nova.conf configuration options that will used to"},{"line_number":14,"context_line":"determine how to set the *initial* allocation ratio of ``VCPU``, ``MEMORY_MB``"},{"line_number":15,"context_line":"and ``DISK_GB`` resource classes when a compute worker first starts up and"},{"line_number":16,"context_line":"creates its compute node record in the nova cell DB and corresponding inventory"}],"source_content_type":"text/x-rst","patch_set":3,"id":"9f6a8fd7_55437242","line":13,"range":{"start_line":13,"start_character":61,"end_line":13,"end_character":70},"updated":"2018-04-24 16:29:48.000000000","message":"will be used","commit_id":"2921d2be57438a8eb1d7a077ca71d2deafe27d31"},{"author":{"_account_id":7166,"name":"Sylvain Bauza","email":"sbauza@redhat.com","username":"sbauza"},"change_message_id":"a9ab2811d4d675d6a08a885cc84d6ef1822ca641","unresolved":false,"context_lines":[{"line_number":47,"context_line":".. _setting: https://github.com/openstack/nova/blob/stable/queens/nova/compute/resource_tracker.py#L611-L614"},{"line_number":48,"context_line":""},{"line_number":49,"context_line":"The default values of the ``cpu_allocation_ratio``, ``ram_allocation_ratio``"},{"line_number":50,"context_line":"and ``disk_allocation_ratio`` CONF options is `currently set`_ to ``0.0``."},{"line_number":51,"context_line":""},{"line_number":52,"context_line":".. _currently set: https://github.com/openstack/nova/blob/stable/queens/nova/conf/compute.py#L400"},{"line_number":53,"context_line":""}],"source_content_type":"text/x-rst","patch_set":3,"id":"5f7c97a3_dd4cbf40","line":50,"updated":"2018-06-11 13:04:42.000000000","message":"just for sharing context, we used 0.0 as an upgrade signal to know whether compute\u0027s nova.conf was set for the related allocation ratio by the operator.\n\nIf the operator was setting nova.conf, then the CONF value wasn\u0027t 0.0. On the other hand, if the allocation wasn\u0027t set by the operator, it was returning 0.0 (even if the compute was already using the default value of 16.0).","commit_id":"2921d2be57438a8eb1d7a077ca71d2deafe27d31"},{"author":{"_account_id":14070,"name":"Eric Fried","email":"openstack@fried.cc","username":"efried"},"change_message_id":"0787330bee6c2970665c2482bf608d52d458d444","unresolved":false,"context_lines":[{"line_number":64,"context_line":"these new values for some period of time while the record in the"},{"line_number":65,"context_line":"``compute_nodes`` table continues to have the wrong ``0.0`` values. When the"},{"line_number":66,"context_line":"resource tracker runs its ``update_available_resource()`` next perioidic task,"},{"line_number":67,"context_line":"the new ``16.0``/``1.5``/``1.0`` values are then save to the compute nodes"},{"line_number":68,"context_line":"table. So, for some amount of time -- typically around 5-15 minutes -- the"},{"line_number":69,"context_line":"resource usages reported by the compute node are incorrect (due to the"},{"line_number":70,"context_line":"allocation ratio of 0.0 being multiplied by the total amount in inventory,"}],"source_content_type":"text/x-rst","patch_set":3,"id":"9f6a8fd7_55b13246","line":67,"range":{"start_line":67,"start_character":49,"end_line":67,"end_character":53},"updated":"2018-04-24 16:29:48.000000000","message":"saved","commit_id":"2921d2be57438a8eb1d7a077ca71d2deafe27d31"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"fa47eb884e4ebced7044bbd990a2f2eefc337015","unresolved":false,"context_lines":[{"line_number":65,"context_line":"``compute_nodes`` table continues to have the wrong ``0.0`` values. When the"},{"line_number":66,"context_line":"resource tracker runs its ``update_available_resource()`` next perioidic task,"},{"line_number":67,"context_line":"the new ``16.0``/``1.5``/``1.0`` values are then save to the compute nodes"},{"line_number":68,"context_line":"table. So, for some amount of time -- typically around 5-15 minutes -- the"},{"line_number":69,"context_line":"resource usages reported by the compute node are incorrect (due to the"},{"line_number":70,"context_line":"allocation ratio of 0.0 being multiplied by the total amount in inventory,"},{"line_number":71,"context_line":"leading to 0 resources shown on the system)."}],"source_content_type":"text/x-rst","patch_set":3,"id":"5f7c97a3_4edae549","line":68,"range":{"start_line":68,"start_character":38,"end_line":68,"end_character":67},"updated":"2018-07-10 13:14:33.000000000","message":"Huh? Why would it take 5-15 minutes for the values from the compute node object to be saved into the DB? Especially when the update_available_resource periodic runs every minute. Is this a case that deployments are setting that periodic to something like 5-15 minutes instead of 1?","commit_id":"2921d2be57438a8eb1d7a077ca71d2deafe27d31"},{"author":{"_account_id":7166,"name":"Sylvain Bauza","email":"sbauza@redhat.com","username":"sbauza"},"change_message_id":"a9ab2811d4d675d6a08a885cc84d6ef1822ca641","unresolved":false,"context_lines":[{"line_number":68,"context_line":"table. So, for some amount of time -- typically around 5-15 minutes -- the"},{"line_number":69,"context_line":"resource usages reported by the compute node are incorrect (due to the"},{"line_number":70,"context_line":"allocation ratio of 0.0 being multiplied by the total amount in inventory,"},{"line_number":71,"context_line":"leading to 0 resources shown on the system)."},{"line_number":72,"context_line":""},{"line_number":73,"context_line":"Admins cannot manually set allocation ratios using the placement API"},{"line_number":74,"context_line":"--------------------------------------------------------------------"}],"source_content_type":"text/x-rst","patch_set":3,"id":"5f7c97a3_7d2d6b44","line":71,"updated":"2018-06-11 13:04:42.000000000","message":"That wasn\u0027t a problem for the scheduler given the ComputeNode nova object was providing the right value (when I created the object facade for the ratios), meaning that compute.cpu_allocation_ratio was 16.0 (even if the DB was populated with 0.0).\n\nThat actually became a problem *AFTER*, when Placement used those compute node values for the inventory, without using the object facade for transforming those values (because of a design choice to not use python objects but straight SQL, which I don\u0027t disagree tbc, just explaining).","commit_id":"2921d2be57438a8eb1d7a077ca71d2deafe27d31"},{"author":{"_account_id":7166,"name":"Sylvain Bauza","email":"sbauza@redhat.com","username":"sbauza"},"change_message_id":"a9ab2811d4d675d6a08a885cc84d6ef1822ca641","unresolved":false,"context_lines":[{"line_number":83,"context_line":"Use Cases"},{"line_number":84,"context_line":"---------"},{"line_number":85,"context_line":""},{"line_number":86,"context_line":"An administrator would like to set allocation ratios for individual resources"},{"line_number":87,"context_line":"on a compute node without that value being overwritten by the compute node\u0027s"},{"line_number":88,"context_line":"resource tracker."},{"line_number":89,"context_line":""},{"line_number":90,"context_line":"Proposed change"},{"line_number":91,"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":3,"id":"5f7c97a3_3dd85350","line":88,"range":{"start_line":86,"start_character":0,"end_line":88,"end_character":17},"updated":"2018-06-11 13:04:42.000000000","message":"that looks to me the REAL usecase.","commit_id":"2921d2be57438a8eb1d7a077ca71d2deafe27d31"},{"author":{"_account_id":14070,"name":"Eric Fried","email":"openstack@fried.cc","username":"efried"},"change_message_id":"0787330bee6c2970665c2482bf608d52d458d444","unresolved":false,"context_lines":[{"line_number":93,"context_line":"First, change the resource tracker to **only** overwrite the compute node\u0027s"},{"line_number":94,"context_line":"allocation ratios to the value of the ``cpu_allocation_ratio``,"},{"line_number":95,"context_line":"``ram_allocation_ratio`` and ``disk_allocation_ratio`` CONF options **if the"},{"line_number":96,"context_line":"value of these options is NOT ``0.0``**."},{"line_number":97,"context_line":""},{"line_number":98,"context_line":"In other words, if any of these CONF options is set to something *other than*"},{"line_number":99,"context_line":"``0.0``, then the CONF option should be considered the complete override value"}],"source_content_type":"text/x-rst","patch_set":3,"id":"9f6a8fd7_f5896674","line":96,"updated":"2018-04-24 16:29:48.000000000","message":"in the compute_nodes table in the cell db, yes? (as opposed to the placement db)","commit_id":"2921d2be57438a8eb1d7a077ca71d2deafe27d31"},{"author":{"_account_id":7166,"name":"Sylvain Bauza","email":"sbauza@redhat.com","username":"sbauza"},"change_message_id":"a9ab2811d4d675d6a08a885cc84d6ef1822ca641","unresolved":false,"context_lines":[{"line_number":93,"context_line":"First, change the resource tracker to **only** overwrite the compute node\u0027s"},{"line_number":94,"context_line":"allocation ratios to the value of the ``cpu_allocation_ratio``,"},{"line_number":95,"context_line":"``ram_allocation_ratio`` and ``disk_allocation_ratio`` CONF options **if the"},{"line_number":96,"context_line":"value of these options is NOT ``0.0``**."},{"line_number":97,"context_line":""},{"line_number":98,"context_line":"In other words, if any of these CONF options is set to something *other than*"},{"line_number":99,"context_line":"``0.0``, then the CONF option should be considered the complete override value"}],"source_content_type":"text/x-rst","patch_set":3,"id":"5f7c97a3_9dc08752","line":96,"in_reply_to":"9f6a8fd7_f5896674","updated":"2018-06-11 13:04:42.000000000","message":"No, I think Jay refers to the option value itself.","commit_id":"2921d2be57438a8eb1d7a077ca71d2deafe27d31"},{"author":{"_account_id":14070,"name":"Eric Fried","email":"openstack@fried.cc","username":"efried"},"change_message_id":"0787330bee6c2970665c2482bf608d52d458d444","unresolved":false,"context_lines":[{"line_number":116,"context_line":"if the resource tracker detects no existing record in the ``compute_nodes``"},{"line_number":117,"context_line":"nova cell DB for that hypervisor."},{"line_number":118,"context_line":""},{"line_number":119,"context_line":"Remove the code in the ``nova.objects.ComputeNode._from_db_obj`` that adjusts"},{"line_number":120,"context_line":"allocation ratios."},{"line_number":121,"context_line":""},{"line_number":122,"context_line":"Alternatives"}],"source_content_type":"text/x-rst","patch_set":3,"id":"9f6a8fd7_f5ee4620","line":119,"range":{"start_line":119,"start_character":19,"end_line":119,"end_character":22},"updated":"2018-04-24 16:29:48.000000000","message":"strike (or add `method` after _from_db_obj)","commit_id":"2921d2be57438a8eb1d7a077ca71d2deafe27d31"},{"author":{"_account_id":7166,"name":"Sylvain Bauza","email":"sbauza@redhat.com","username":"sbauza"},"change_message_id":"a9ab2811d4d675d6a08a885cc84d6ef1822ca641","unresolved":false,"context_lines":[{"line_number":116,"context_line":"if the resource tracker detects no existing record in the ``compute_nodes``"},{"line_number":117,"context_line":"nova cell DB for that hypervisor."},{"line_number":118,"context_line":""},{"line_number":119,"context_line":"Remove the code in the ``nova.objects.ComputeNode._from_db_obj`` that adjusts"},{"line_number":120,"context_line":"allocation ratios."},{"line_number":121,"context_line":""},{"line_number":122,"context_line":"Alternatives"},{"line_number":123,"context_line":"------------"}],"source_content_type":"text/x-rst","patch_set":3,"id":"5f7c97a3_1d91d752","line":120,"range":{"start_line":119,"start_character":0,"end_line":120,"end_character":18},"updated":"2018-06-11 13:04:42.000000000","message":"yes, please. \nI wrote this object facade for just an upgrade concern like 5 cycles before, but we didn\u0027t stopped to use it.","commit_id":"2921d2be57438a8eb1d7a077ca71d2deafe27d31"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"fa47eb884e4ebced7044bbd990a2f2eefc337015","unresolved":false,"context_lines":[{"line_number":118,"context_line":""},{"line_number":119,"context_line":"Remove the code in the ``nova.objects.ComputeNode._from_db_obj`` that adjusts"},{"line_number":120,"context_line":"allocation ratios."},{"line_number":121,"context_line":""},{"line_number":122,"context_line":"Alternatives"},{"line_number":123,"context_line":"------------"},{"line_number":124,"context_line":""}],"source_content_type":"text/x-rst","patch_set":3,"id":"5f7c97a3_6e880121","line":121,"updated":"2018-07-10 13:14:33.000000000","message":"So if I\u0027m following correctly, and I never want to touch nova.conf for this but manage it all externally, this will allow me to do it because initial_*_allocation_ratio will set the initial ratio value when the compute node record is created, and if I don\u0027t touch the existing *_allocation_ratio config options, the RT won\u0027t update the allocation ratios for that provider in placement. And then I can manage everything using the Placement REST API for allocation ratios on the root compute node provider (or use config as before - which is what CERN would probably do as they config manage everything).","commit_id":"2921d2be57438a8eb1d7a077ca71d2deafe27d31"},{"author":{"_account_id":14070,"name":"Eric Fried","email":"openstack@fried.cc","username":"efried"},"change_message_id":"0787330bee6c2970665c2482bf608d52d458d444","unresolved":false,"context_lines":[{"line_number":122,"context_line":"Alternatives"},{"line_number":123,"context_line":"------------"},{"line_number":124,"context_line":""},{"line_number":125,"context_line":"None"},{"line_number":126,"context_line":""},{"line_number":127,"context_line":"Data model impact"},{"line_number":128,"context_line":"-----------------"}],"source_content_type":"text/x-rst","patch_set":3,"id":"9f6a8fd7_35e03e26","line":125,"range":{"start_line":125,"start_character":0,"end_line":125,"end_character":4},"updated":"2018-04-24 16:29:48.000000000","message":"False","commit_id":"2921d2be57438a8eb1d7a077ca71d2deafe27d31"},{"author":{"_account_id":15334,"name":"Stephen Finucane","display_name":"stephenfin","email":"stephenfin@redhat.com","username":"sfinucan"},"change_message_id":"1cc2e11f34b4baddfec3980552826523114b1242","unresolved":false,"context_lines":[{"line_number":184,"context_line":"----------"},{"line_number":185,"context_line":""},{"line_number":186,"context_line":"* Modify resource tracker to only set allocation ratios on the compute node"},{"line_number":187,"context_line":"  object when the CONF options are non- ``0.0``"},{"line_number":188,"context_line":"* Add new ``initial_xxx_allocation_ratio`` CONF options and modify resource"},{"line_number":189,"context_line":"  tracker\u0027s initial compute node creation to use these values if non- ``None``"},{"line_number":190,"context_line":"* Remove code in the ``ComputeNode._from_db_obj()`` that changes allocation"}],"source_content_type":"text/x-rst","patch_set":3,"id":"5f7c97a3_b6b39d0a","line":187,"range":{"start_line":187,"start_character":39,"end_line":187,"end_character":40},"updated":"2018-06-05 15:31:01.000000000","message":"nit: backslash before this if you want to escape the space","commit_id":"2921d2be57438a8eb1d7a077ca71d2deafe27d31"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"fa47eb884e4ebced7044bbd990a2f2eefc337015","unresolved":false,"context_lines":[{"line_number":186,"context_line":"* Modify resource tracker to only set allocation ratios on the compute node"},{"line_number":187,"context_line":"  object when the CONF options are non- ``0.0``"},{"line_number":188,"context_line":"* Add new ``initial_xxx_allocation_ratio`` CONF options and modify resource"},{"line_number":189,"context_line":"  tracker\u0027s initial compute node creation to use these values if non- ``None``"},{"line_number":190,"context_line":"* Remove code in the ``ComputeNode._from_db_obj()`` that changes allocation"},{"line_number":191,"context_line":"  ratio values"},{"line_number":192,"context_line":""}],"source_content_type":"text/x-rst","patch_set":3,"id":"5f7c97a3_8e90fd43","line":189,"range":{"start_line":189,"start_character":62,"end_line":189,"end_character":78},"updated":"2018-07-10 13:14:33.000000000","message":"Hmm, would/could we allow to set the new options to None? That doesn\u0027t make a ton of sense does it? We\u0027d have defaults, but wouldn\u0027t we have minimums of something like 1.0? Even then, is there such a thing as a nullable\u003dFalse concept with oslo config options? If not, and they are set the None, then what do we do? Hard-code the defaults as before like in the ComputeNode object?","commit_id":"2921d2be57438a8eb1d7a077ca71d2deafe27d31"}],"specs/stein/approved/initial-allocation-ratios.rst":[{"author":{"_account_id":20722,"name":"Yikun Jiang","email":"yikunkero@gmail.com","username":"yikunkero"},"change_message_id":"4af8979bb47894e0e120cd773451cbe09e6d4c42","unresolved":false,"context_lines":[{"line_number":50,"context_line":"``ram_allocation_ratio`` and ``disk_allocation_ratio`` nova.conf configuration"},{"line_number":51,"context_line":"options."},{"line_number":52,"context_line":""},{"line_number":53,"context_line":".. _checks: https://github.com/openstack/nova/blob/stable/queens/nova/compute/resource_tracker.py#L566"},{"line_number":54,"context_line":".. _creates: https://github.com/openstack/nova/blob/stable/queens/nova/compute/resource_tracker.py#L577-L590"},{"line_number":55,"context_line":".. _setting: https://github.com/openstack/nova/blob/stable/queens/nova/compute/resource_tracker.py#L611-L614"},{"line_number":56,"context_line":""}],"source_content_type":"text/x-rst","patch_set":4,"id":"3f79a3b5_2e32b15f","line":53,"range":{"start_line":53,"start_character":51,"end_line":53,"end_character":64},"updated":"2018-09-13 11:48:09.000000000","message":"We can change these to 852de1e (permanlink), now the L-number has been already changed.","commit_id":"9c4920fc9e3bc6618202f76820839c2e415d3195"},{"author":{"_account_id":20722,"name":"Yikun Jiang","email":"yikunkero@gmail.com","username":"yikunkero"},"change_message_id":"b7cf62337eef5be14411e76f7e9233951d0305f8","unresolved":false,"context_lines":[{"line_number":50,"context_line":"``ram_allocation_ratio`` and ``disk_allocation_ratio`` nova.conf configuration"},{"line_number":51,"context_line":"options."},{"line_number":52,"context_line":""},{"line_number":53,"context_line":".. _checks: https://github.com/openstack/nova/blob/stable/queens/nova/compute/resource_tracker.py#L566"},{"line_number":54,"context_line":".. _creates: https://github.com/openstack/nova/blob/stable/queens/nova/compute/resource_tracker.py#L577-L590"},{"line_number":55,"context_line":".. _setting: https://github.com/openstack/nova/blob/stable/queens/nova/compute/resource_tracker.py#L611-L614"},{"line_number":56,"context_line":""}],"source_content_type":"text/x-rst","patch_set":4,"id":"3f79a3b5_6e76690f","line":53,"range":{"start_line":53,"start_character":51,"end_line":53,"end_character":64},"in_reply_to":"3f79a3b5_2e32b15f","updated":"2018-09-13 11:50:45.000000000","message":"Done","commit_id":"9c4920fc9e3bc6618202f76820839c2e415d3195"},{"author":{"_account_id":20722,"name":"Yikun Jiang","email":"yikunkero@gmail.com","username":"yikunkero"},"change_message_id":"4af8979bb47894e0e120cd773451cbe09e6d4c42","unresolved":false,"context_lines":[{"line_number":108,"context_line":"Change the resource tracker to **only** overwrite the compute node\u0027s"},{"line_number":109,"context_line":"allocation ratios to the value of the ``cpu_allocation_ratio``,"},{"line_number":110,"context_line":"``ram_allocation_ratio`` and ``disk_allocation_ratio`` CONF options **if the"},{"line_number":111,"context_line":"value of these options is NOT ``None``**."},{"line_number":112,"context_line":""},{"line_number":113,"context_line":"In other words, if any of these CONF options is set to something *other than*"},{"line_number":114,"context_line":"``None``, then the CONF option should be considered the complete override value"}],"source_content_type":"text/x-rst","patch_set":4,"id":"3f79a3b5_4eddad3f","line":111,"updated":"2018-09-13 11:48:09.000000000","message":"So, if the user set ratio \u003d 0.0, means the ratio is true 0.0, we can remove the hack logic in [1], right?\n\n[1] https://review.openstack.org/#/c/598365/2/nova/compute/resource_tracker.py@643","commit_id":"9c4920fc9e3bc6618202f76820839c2e415d3195"},{"author":{"_account_id":7,"name":"Jay Pipes","email":"jaypipes@gmail.com","username":"jaypipes"},"change_message_id":"68a8e25020c4bc70050a5bcf326453f9122b162a","unresolved":false,"context_lines":[{"line_number":108,"context_line":"Change the resource tracker to **only** overwrite the compute node\u0027s"},{"line_number":109,"context_line":"allocation ratios to the value of the ``cpu_allocation_ratio``,"},{"line_number":110,"context_line":"``ram_allocation_ratio`` and ``disk_allocation_ratio`` CONF options **if the"},{"line_number":111,"context_line":"value of these options is NOT ``None``**."},{"line_number":112,"context_line":""},{"line_number":113,"context_line":"In other words, if any of these CONF options is set to something *other than*"},{"line_number":114,"context_line":"``None``, then the CONF option should be considered the complete override value"}],"source_content_type":"text/x-rst","patch_set":4,"id":"3f79a3b5_71c4080f","line":111,"in_reply_to":"3f79a3b5_4eddad3f","updated":"2018-09-13 13:11:23.000000000","message":"I would actually go so far as to say setting the values to 0.0 after this patch series lands should result in a failure to start the nova-compute service. Setting an allocation ratio to 0.0 doesn\u0027t make any sense after removing all the code in the ComputeNode object that used the 0.0 value as a sentinel to indicate the deployment was upgrading from before Liberty to Liberty code.","commit_id":"9c4920fc9e3bc6618202f76820839c2e415d3195"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"985e95fe871e882e31d98574d94d5b826301e151","unresolved":false,"context_lines":[{"line_number":10,"context_line":""},{"line_number":11,"context_line":"https://blueprints.launchpad.net/nova/+spec/default-allocation-ratios"},{"line_number":12,"context_line":""},{"line_number":13,"context_line":"We propose to add 3 new nova.conf configuration options that will used to"},{"line_number":14,"context_line":"determine how to set the *initial* allocation ratio of ``VCPU``, ``MEMORY_MB``"},{"line_number":15,"context_line":"and ``DISK_GB`` resource classes when a compute worker first starts up and"},{"line_number":16,"context_line":"creates its compute node record in the nova cell DB and corresponding inventory"}],"source_content_type":"text/x-rst","patch_set":5,"id":"3f79a3b5_0031b259","line":13,"updated":"2018-10-09 21:06:52.000000000","message":"This is all stuff that belongs in the proposed change section, not the description of the blueprint (or the problem description/use case). What is in the commit message is probably sufficient for this section.","commit_id":"dff0cc41337e693b0029ec5123fc91697ce408cf"},{"author":{"_account_id":20722,"name":"Yikun Jiang","email":"yikunkero@gmail.com","username":"yikunkero"},"change_message_id":"7f41cc02d7af7f0e87515198322854ff99a5d1dd","unresolved":false,"context_lines":[{"line_number":10,"context_line":""},{"line_number":11,"context_line":"https://blueprints.launchpad.net/nova/+spec/default-allocation-ratios"},{"line_number":12,"context_line":""},{"line_number":13,"context_line":"We propose to add 3 new nova.conf configuration options that will used to"},{"line_number":14,"context_line":"determine how to set the *initial* allocation ratio of ``VCPU``, ``MEMORY_MB``"},{"line_number":15,"context_line":"and ``DISK_GB`` resource classes when a compute worker first starts up and"},{"line_number":16,"context_line":"creates its compute node record in the nova cell DB and corresponding inventory"}],"source_content_type":"text/x-rst","patch_set":5,"id":"3f79a3b5_c0040f1c","line":13,"in_reply_to":"3f79a3b5_0031b259","updated":"2018-10-10 09:53:59.000000000","message":"Done","commit_id":"dff0cc41337e693b0029ec5123fc91697ce408cf"},{"author":{"_account_id":7166,"name":"Sylvain Bauza","email":"sbauza@redhat.com","username":"sbauza"},"change_message_id":"2880ec35e28a6cf270c51aba414aad2eb22ac7cc","unresolved":false,"context_lines":[{"line_number":19,"context_line":"a record in the placement service for the compute node the resource tracker is"},{"line_number":20,"context_line":"managing."},{"line_number":21,"context_line":""},{"line_number":22,"context_line":"We will also change the default values of existing"},{"line_number":23,"context_line":"``CONF.xxx_allocation_ratio`` options relating to allocation ratios to ``None``"},{"line_number":24,"context_line":"from the existing default values of ``0.0`` and modify the behaviour of the"},{"line_number":25,"context_line":"resource tracker to only override allocation ratios *after* the compute node is"},{"line_number":26,"context_line":"already up *if and only if* the ``CONF.xxx_allocation_ratio`` option values are"},{"line_number":27,"context_line":"*not* ``None``."}],"source_content_type":"text/x-rst","patch_set":5,"id":"3f79a3b5_68edf98c","line":24,"range":{"start_line":22,"start_character":0,"end_line":24,"end_character":43},"updated":"2018-09-13 16:33:59.000000000","message":"that could possibly be unnecessary","commit_id":"dff0cc41337e693b0029ec5123fc91697ce408cf"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"985e95fe871e882e31d98574d94d5b826301e151","unresolved":false,"context_lines":[{"line_number":19,"context_line":"a record in the placement service for the compute node the resource tracker is"},{"line_number":20,"context_line":"managing."},{"line_number":21,"context_line":""},{"line_number":22,"context_line":"We will also change the default values of existing"},{"line_number":23,"context_line":"``CONF.xxx_allocation_ratio`` options relating to allocation ratios to ``None``"},{"line_number":24,"context_line":"from the existing default values of ``0.0`` and modify the behaviour of the"},{"line_number":25,"context_line":"resource tracker to only override allocation ratios *after* the compute node is"},{"line_number":26,"context_line":"already up *if and only if* the ``CONF.xxx_allocation_ratio`` option values are"},{"line_number":27,"context_line":"*not* ``None``."}],"source_content_type":"text/x-rst","patch_set":5,"id":"3f79a3b5_e0f03695","line":24,"range":{"start_line":22,"start_character":0,"end_line":24,"end_character":43},"in_reply_to":"3f79a3b5_68edf98c","updated":"2018-10-09 21:06:52.000000000","message":"Possibly but I think the idea is to change the default as a signal that it\u0027s really not set and not being used. 0.0 as a default is weird and only works today because of the facade in the ComputeNode object, which we agreed to remove as part of this change.","commit_id":"dff0cc41337e693b0029ec5123fc91697ce408cf"},{"author":{"_account_id":7166,"name":"Sylvain Bauza","email":"sbauza@redhat.com","username":"sbauza"},"change_message_id":"2880ec35e28a6cf270c51aba414aad2eb22ac7cc","unresolved":false,"context_lines":[{"line_number":30,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"},{"line_number":31,"context_line":""},{"line_number":32,"context_line":"The saga of the allocation ratio values on the compute host"},{"line_number":33,"context_line":"-----------------------------------------------------------"},{"line_number":34,"context_line":""},{"line_number":35,"context_line":"The process by which nova determines the allocation ratio for CPU, RAM and disk"},{"line_number":36,"context_line":"resources on a hypervisor is confusing and `error`_ `prone`_. The"}],"source_content_type":"text/x-rst","patch_set":5,"id":"3f79a3b5_a88f91cb","line":33,"updated":"2018-09-13 16:33:59.000000000","message":"that\u0027s probably something we could consider as bugs, hence not requiring a spec... but see my comment later on L81","commit_id":"dff0cc41337e693b0029ec5123fc91697ce408cf"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"985e95fe871e882e31d98574d94d5b826301e151","unresolved":false,"context_lines":[{"line_number":30,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"},{"line_number":31,"context_line":""},{"line_number":32,"context_line":"The saga of the allocation ratio values on the compute host"},{"line_number":33,"context_line":"-----------------------------------------------------------"},{"line_number":34,"context_line":""},{"line_number":35,"context_line":"The process by which nova determines the allocation ratio for CPU, RAM and disk"},{"line_number":36,"context_line":"resources on a hypervisor is confusing and `error`_ `prone`_. The"}],"source_content_type":"text/x-rst","patch_set":5,"id":"3f79a3b5_40100aac","line":33,"in_reply_to":"3f79a3b5_a88f91cb","updated":"2018-10-09 21:06:52.000000000","message":"It\u0027s a design change to fix bugs, so a spec is fine IMO so we\u0027re all on the same page.","commit_id":"dff0cc41337e693b0029ec5123fc91697ce408cf"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"985e95fe871e882e31d98574d94d5b826301e151","unresolved":false,"context_lines":[{"line_number":40,"context_line":"nova running on the ``nova-compute`` service."},{"line_number":41,"context_line":""},{"line_number":42,"context_line":".. _error: https://bugs.launchpad.net/nova/+bug/1742747"},{"line_number":43,"context_line":".. _error: https://bugs.launchpad.net/nova/+bug/1789654"},{"line_number":44,"context_line":""},{"line_number":45,"context_line":"Upon starting up, the resource tracker in the ``nova-compute`` service worker"},{"line_number":46,"context_line":"`checks`_ to see if a record exists in the ``compute_nodes`` table of the nova"}],"source_content_type":"text/x-rst","patch_set":5,"id":"3f79a3b5_e01ef6ba","line":43,"range":{"start_line":43,"start_character":3,"end_line":43,"end_character":9},"updated":"2018-10-09 21:06:52.000000000","message":"prone?","commit_id":"dff0cc41337e693b0029ec5123fc91697ce408cf"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"985e95fe871e882e31d98574d94d5b826301e151","unresolved":false,"context_lines":[{"line_number":52,"context_line":""},{"line_number":53,"context_line":".. _checks: https://github.com/openstack/nova/blob/852de1e/nova/compute/resource_tracker.py#L566"},{"line_number":54,"context_line":".. _creates: https://github.com/openstack/nova/blob/852de1e/nova/compute/resource_tracker.py#L577-L590"},{"line_number":55,"context_line":".. _setting: https://github.com/openstack/nova/blob/852de1e/nova/compute/resource_tracker.py#L611-L614"},{"line_number":56,"context_line":""},{"line_number":57,"context_line":"The default values of the ``cpu_allocation_ratio``, ``ram_allocation_ratio``"},{"line_number":58,"context_line":"and ``disk_allocation_ratio`` CONF options is `currently set`_ to ``0.0``."}],"source_content_type":"text/x-rst","patch_set":5,"id":"3f79a3b5_2045ce6f","line":55,"updated":"2018-10-09 21:06:52.000000000","message":"This is old now, we don\u0027t set the attributes on the object if the configured values are the 0.0 defaults:\n\nhttps://github.com/openstack/nova/blob/6a68f9140/nova/compute/resource_tracker.py#L621-L645","commit_id":"dff0cc41337e693b0029ec5123fc91697ce408cf"},{"author":{"_account_id":20722,"name":"Yikun Jiang","email":"yikunkero@gmail.com","username":"yikunkero"},"change_message_id":"7f41cc02d7af7f0e87515198322854ff99a5d1dd","unresolved":false,"context_lines":[{"line_number":52,"context_line":""},{"line_number":53,"context_line":".. _checks: https://github.com/openstack/nova/blob/852de1e/nova/compute/resource_tracker.py#L566"},{"line_number":54,"context_line":".. _creates: https://github.com/openstack/nova/blob/852de1e/nova/compute/resource_tracker.py#L577-L590"},{"line_number":55,"context_line":".. _setting: https://github.com/openstack/nova/blob/852de1e/nova/compute/resource_tracker.py#L611-L614"},{"line_number":56,"context_line":""},{"line_number":57,"context_line":"The default values of the ``cpu_allocation_ratio``, ``ram_allocation_ratio``"},{"line_number":58,"context_line":"and ``disk_allocation_ratio`` CONF options is `currently set`_ to ``0.0``."}],"source_content_type":"text/x-rst","patch_set":5,"id":"3f79a3b5_5bfeb004","line":55,"in_reply_to":"3f79a3b5_2045ce6f","updated":"2018-10-10 09:53:59.000000000","message":"Done","commit_id":"dff0cc41337e693b0029ec5123fc91697ce408cf"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"985e95fe871e882e31d98574d94d5b826301e151","unresolved":false,"context_lines":[{"line_number":72,"context_line":"these new values for some period of time while the record in the"},{"line_number":73,"context_line":"``compute_nodes`` table continues to have the wrong ``0.0`` values. When the"},{"line_number":74,"context_line":"resource tracker runs its ``update_available_resource()`` next perioidic task,"},{"line_number":75,"context_line":"the new ``16.0``/``1.5``/``1.0`` values are then save to the compute nodes"},{"line_number":76,"context_line":"table. So, for some amount of time -- typically around 5-15 minutes -- the"},{"line_number":77,"context_line":"resource usages reported by the compute node are incorrect (due to the"},{"line_number":78,"context_line":"allocation ratio of 0.0 being multiplied by the total amount in inventory,"}],"source_content_type":"text/x-rst","patch_set":5,"id":"3f79a3b5_e01b5681","line":75,"range":{"start_line":75,"start_character":49,"end_line":75,"end_character":53},"updated":"2018-10-09 21:06:52.000000000","message":"saved","commit_id":"dff0cc41337e693b0029ec5123fc91697ce408cf"},{"author":{"_account_id":20722,"name":"Yikun Jiang","email":"yikunkero@gmail.com","username":"yikunkero"},"change_message_id":"7f41cc02d7af7f0e87515198322854ff99a5d1dd","unresolved":false,"context_lines":[{"line_number":72,"context_line":"these new values for some period of time while the record in the"},{"line_number":73,"context_line":"``compute_nodes`` table continues to have the wrong ``0.0`` values. When the"},{"line_number":74,"context_line":"resource tracker runs its ``update_available_resource()`` next perioidic task,"},{"line_number":75,"context_line":"the new ``16.0``/``1.5``/``1.0`` values are then save to the compute nodes"},{"line_number":76,"context_line":"table. So, for some amount of time -- typically around 5-15 minutes -- the"},{"line_number":77,"context_line":"resource usages reported by the compute node are incorrect (due to the"},{"line_number":78,"context_line":"allocation ratio of 0.0 being multiplied by the total amount in inventory,"}],"source_content_type":"text/x-rst","patch_set":5,"id":"3f79a3b5_1b083825","line":75,"range":{"start_line":75,"start_character":49,"end_line":75,"end_character":53},"in_reply_to":"3f79a3b5_e01b5681","updated":"2018-10-10 09:53:59.000000000","message":"Done","commit_id":"dff0cc41337e693b0029ec5123fc91697ce408cf"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"985e95fe871e882e31d98574d94d5b826301e151","unresolved":false,"context_lines":[{"line_number":73,"context_line":"``compute_nodes`` table continues to have the wrong ``0.0`` values. When the"},{"line_number":74,"context_line":"resource tracker runs its ``update_available_resource()`` next perioidic task,"},{"line_number":75,"context_line":"the new ``16.0``/``1.5``/``1.0`` values are then save to the compute nodes"},{"line_number":76,"context_line":"table. So, for some amount of time -- typically around 5-15 minutes -- the"},{"line_number":77,"context_line":"resource usages reported by the compute node are incorrect (due to the"},{"line_number":78,"context_line":"allocation ratio of 0.0 being multiplied by the total amount in inventory,"},{"line_number":79,"context_line":"leading to 0 resources shown on the system)."}],"source_content_type":"text/x-rst","patch_set":5,"id":"3f79a3b5_802aa28e","line":76,"range":{"start_line":76,"start_character":38,"end_line":76,"end_character":67},"updated":"2018-10-09 21:06:52.000000000","message":"I asked this before, but again I\u0027m confused as to where these numbers come from.\n\nAlso, isn\u0027t this fixed by I43a23a3290db0c835fed01b8d6a38962dc61adce for bug 1789654 now?","commit_id":"dff0cc41337e693b0029ec5123fc91697ce408cf"},{"author":{"_account_id":20722,"name":"Yikun Jiang","email":"yikunkero@gmail.com","username":"yikunkero"},"change_message_id":"7f41cc02d7af7f0e87515198322854ff99a5d1dd","unresolved":false,"context_lines":[{"line_number":73,"context_line":"``compute_nodes`` table continues to have the wrong ``0.0`` values. When the"},{"line_number":74,"context_line":"resource tracker runs its ``update_available_resource()`` next perioidic task,"},{"line_number":75,"context_line":"the new ``16.0``/``1.5``/``1.0`` values are then save to the compute nodes"},{"line_number":76,"context_line":"table. So, for some amount of time -- typically around 5-15 minutes -- the"},{"line_number":77,"context_line":"resource usages reported by the compute node are incorrect (due to the"},{"line_number":78,"context_line":"allocation ratio of 0.0 being multiplied by the total amount in inventory,"},{"line_number":79,"context_line":"leading to 0 resources shown on the system)."}],"source_content_type":"text/x-rst","patch_set":5,"id":"3f79a3b5_f179db81","line":76,"range":{"start_line":76,"start_character":38,"end_line":76,"end_character":67},"in_reply_to":"3f79a3b5_802aa28e","updated":"2018-10-10 09:53:59.000000000","message":"Yes, this part is out of date, I will update","commit_id":"dff0cc41337e693b0029ec5123fc91697ce408cf"},{"author":{"_account_id":7166,"name":"Sylvain Bauza","email":"sbauza@redhat.com","username":"sbauza"},"change_message_id":"2880ec35e28a6cf270c51aba414aad2eb22ac7cc","unresolved":false,"context_lines":[{"line_number":78,"context_line":"allocation ratio of 0.0 being multiplied by the total amount in inventory,"},{"line_number":79,"context_line":"leading to 0 resources shown on the system)."},{"line_number":80,"context_line":""},{"line_number":81,"context_line":"Admins cannot manually set allocation ratios using the placement API"},{"line_number":82,"context_line":"--------------------------------------------------------------------"},{"line_number":83,"context_line":""},{"line_number":84,"context_line":"In addition to the confusing process by which the allocation ratio values are"}],"source_content_type":"text/x-rst","patch_set":5,"id":"3f79a3b5_4846fd7d","line":81,"range":{"start_line":81,"start_character":45,"end_line":81,"end_character":68},"updated":"2018-09-13 16:33:59.000000000","message":"no, I disagree. Admins don\u0027t really care of placement, they just want a controlplane API for managing their ratios, and they had that with the os-aggregates API in the past.\n\nWhat I guess people want is to yet manage thru os-aggregates API their own allocation ratios like we allowed in the past with Aggregate[Core/Disk/Ram]Filter","commit_id":"dff0cc41337e693b0029ec5123fc91697ce408cf"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"985e95fe871e882e31d98574d94d5b826301e151","unresolved":false,"context_lines":[{"line_number":78,"context_line":"allocation ratio of 0.0 being multiplied by the total amount in inventory,"},{"line_number":79,"context_line":"leading to 0 resources shown on the system)."},{"line_number":80,"context_line":""},{"line_number":81,"context_line":"Admins cannot manually set allocation ratios using the placement API"},{"line_number":82,"context_line":"--------------------------------------------------------------------"},{"line_number":83,"context_line":""},{"line_number":84,"context_line":"In addition to the confusing process by which the allocation ratio values are"}],"source_content_type":"text/x-rst","patch_set":5,"id":"3f79a3b5_c30e6432","line":81,"range":{"start_line":81,"start_character":45,"end_line":81,"end_character":68},"in_reply_to":"3f79a3b5_4846fd7d","updated":"2018-10-09 21:06:52.000000000","message":"What are you disagreeing with? The wording? Admins can set allocation ratios for an inventory resource class on a given provider, but that doesn\u0027t apply to aggregates in placement (placement resource provider aggregates don\u0027t have allocation ratios like nova host aggregates do).\n\nI think the description of this problem is pretty clear though - even if you change the resource provider inventory allocation ratio directly in placement, the RT overwrites it based on whatever is in the nova DB/config.\n\nMaybe re-word this subsection to be, \"Manually set placement allocation ratios are overwritten\"?","commit_id":"dff0cc41337e693b0029ec5123fc91697ce408cf"},{"author":{"_account_id":20722,"name":"Yikun Jiang","email":"yikunkero@gmail.com","username":"yikunkero"},"change_message_id":"7f41cc02d7af7f0e87515198322854ff99a5d1dd","unresolved":false,"context_lines":[{"line_number":78,"context_line":"allocation ratio of 0.0 being multiplied by the total amount in inventory,"},{"line_number":79,"context_line":"leading to 0 resources shown on the system)."},{"line_number":80,"context_line":""},{"line_number":81,"context_line":"Admins cannot manually set allocation ratios using the placement API"},{"line_number":82,"context_line":"--------------------------------------------------------------------"},{"line_number":83,"context_line":""},{"line_number":84,"context_line":"In addition to the confusing process by which the allocation ratio values are"}],"source_content_type":"text/x-rst","patch_set":5,"id":"3f79a3b5_7bc12c2f","line":81,"range":{"start_line":81,"start_character":45,"end_line":81,"end_character":68},"in_reply_to":"3f79a3b5_c30e6432","updated":"2018-10-10 09:53:59.000000000","message":"Done","commit_id":"dff0cc41337e693b0029ec5123fc91697ce408cf"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"985e95fe871e882e31d98574d94d5b826301e151","unresolved":false,"context_lines":[{"line_number":103,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"},{"line_number":104,"context_line":""},{"line_number":105,"context_line":"Change the default option values for ``CONF.cpu_allocation_ratio``,"},{"line_number":106,"context_line":"``CONF.ram_allocation_ratio`` and ``CONF.disk_allocation_ratio`` to ``None``."},{"line_number":107,"context_line":""},{"line_number":108,"context_line":"Change the resource tracker to **only** overwrite the compute node\u0027s"},{"line_number":109,"context_line":"allocation ratios to the value of the ``cpu_allocation_ratio``,"}],"source_content_type":"text/x-rst","patch_set":5,"id":"3f79a3b5_c33c24c2","line":106,"range":{"start_line":106,"start_character":70,"end_line":106,"end_character":74},"updated":"2018-10-09 21:06:52.000000000","message":"Would probably be good to explain why we want to change the defaults to None, as mentioned above on L24. I believe the reason is signaling and to get away from the weird 0.0 default behavior? That and the next paragraph I guess.","commit_id":"dff0cc41337e693b0029ec5123fc91697ce408cf"},{"author":{"_account_id":20722,"name":"Yikun Jiang","email":"yikunkero@gmail.com","username":"yikunkero"},"change_message_id":"7f41cc02d7af7f0e87515198322854ff99a5d1dd","unresolved":false,"context_lines":[{"line_number":103,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"},{"line_number":104,"context_line":""},{"line_number":105,"context_line":"Change the default option values for ``CONF.cpu_allocation_ratio``,"},{"line_number":106,"context_line":"``CONF.ram_allocation_ratio`` and ``CONF.disk_allocation_ratio`` to ``None``."},{"line_number":107,"context_line":""},{"line_number":108,"context_line":"Change the resource tracker to **only** overwrite the compute node\u0027s"},{"line_number":109,"context_line":"allocation ratios to the value of the ``cpu_allocation_ratio``,"}],"source_content_type":"text/x-rst","patch_set":5,"id":"3f79a3b5_d641350a","line":106,"range":{"start_line":106,"start_character":70,"end_line":106,"end_character":74},"in_reply_to":"3f79a3b5_c33c24c2","updated":"2018-10-10 09:53:59.000000000","message":"Done","commit_id":"dff0cc41337e693b0029ec5123fc91697ce408cf"},{"author":{"_account_id":7166,"name":"Sylvain Bauza","email":"sbauza@redhat.com","username":"sbauza"},"change_message_id":"2880ec35e28a6cf270c51aba414aad2eb22ac7cc","unresolved":false,"context_lines":[{"line_number":110,"context_line":"``ram_allocation_ratio`` and ``disk_allocation_ratio`` CONF options **if the"},{"line_number":111,"context_line":"value of these options is NOT ``None``**."},{"line_number":112,"context_line":""},{"line_number":113,"context_line":"In other words, if any of these CONF options is set to something *other than*"},{"line_number":114,"context_line":"``None``, then the CONF option should be considered the complete override value"},{"line_number":115,"context_line":"for that resource class\u0027 allocation ratio. Even if an admin manually adjusts"},{"line_number":116,"context_line":"the allocation ratio of the resource class in the placement API, the next time"},{"line_number":117,"context_line":"the ``update_available_resource()`` periodic task runs, it will be overwritten"}],"source_content_type":"text/x-rst","patch_set":5,"id":"3f79a3b5_2811415e","line":114,"range":{"start_line":113,"start_character":16,"end_line":114,"end_character":9},"updated":"2018-09-13 16:33:59.000000000","message":"there could be an upgrade impact if we remove the _from_db_object() facade and operators somehow generated conf files having 0.0 defaults. We should probably allow 0.0 to be doing the exact same thing, do a release note explaining that we move to None leaving operators one cycle to change their configuration files, and then remove the 0.0 condition on the next cycle.","commit_id":"dff0cc41337e693b0029ec5123fc91697ce408cf"},{"author":{"_account_id":20722,"name":"Yikun Jiang","email":"yikunkero@gmail.com","username":"yikunkero"},"change_message_id":"92d83e2624309173819634fa4df84e6342820236","unresolved":false,"context_lines":[{"line_number":110,"context_line":"``ram_allocation_ratio`` and ``disk_allocation_ratio`` CONF options **if the"},{"line_number":111,"context_line":"value of these options is NOT ``None``**."},{"line_number":112,"context_line":""},{"line_number":113,"context_line":"In other words, if any of these CONF options is set to something *other than*"},{"line_number":114,"context_line":"``None``, then the CONF option should be considered the complete override value"},{"line_number":115,"context_line":"for that resource class\u0027 allocation ratio. Even if an admin manually adjusts"},{"line_number":116,"context_line":"the allocation ratio of the resource class in the placement API, the next time"},{"line_number":117,"context_line":"the ``update_available_resource()`` periodic task runs, it will be overwritten"}],"source_content_type":"text/x-rst","patch_set":5,"id":"3f79a3b5_2cefce87","line":114,"range":{"start_line":113,"start_character":16,"end_line":114,"end_character":9},"in_reply_to":"3f79a3b5_2811415e","updated":"2018-09-18 03:18:44.000000000","message":"Yes, and how do we address the zero ratio which is already stored in db when upgrading?\n\nIf the old version is already recorded in db, in old version we can get the 16.0(transfer from 0.0), but the new version we only get the real 0.0 (and initial ratio is not work).\n\nSo, perhaps we could first refresh the zero ratio to initial ratio in db to keep the same behavior?","commit_id":"dff0cc41337e693b0029ec5123fc91697ce408cf"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"d1e2e7a39900676107b310d0ff64a1c54ae501ee","unresolved":false,"context_lines":[{"line_number":110,"context_line":"``ram_allocation_ratio`` and ``disk_allocation_ratio`` CONF options **if the"},{"line_number":111,"context_line":"value of these options is NOT ``None``**."},{"line_number":112,"context_line":""},{"line_number":113,"context_line":"In other words, if any of these CONF options is set to something *other than*"},{"line_number":114,"context_line":"``None``, then the CONF option should be considered the complete override value"},{"line_number":115,"context_line":"for that resource class\u0027 allocation ratio. Even if an admin manually adjusts"},{"line_number":116,"context_line":"the allocation ratio of the resource class in the placement API, the next time"},{"line_number":117,"context_line":"the ``update_available_resource()`` periodic task runs, it will be overwritten"}],"source_content_type":"text/x-rst","patch_set":5,"id":"3f79a3b5_c093baa3","line":114,"range":{"start_line":113,"start_character":16,"end_line":114,"end_character":9},"in_reply_to":"3f79a3b5_2cefce87","updated":"2018-10-09 20:16:39.000000000","message":"\u003e Yes, and how do we address the zero ratio which is already stored\n \u003e in db when upgrading?\n \u003e \n \u003e If the old version is already recorded in db, in old version we can\n \u003e get the 16.0(transfer from 0.0), but the new version we only get\n \u003e the real 0.0 (and initial ratio is not work).\n \u003e \n \u003e So, perhaps we could first refresh the zero ratio to initial ratio\n \u003e in db to keep the same behavior?\n\nI would think that we need an online data migration and continue to read the initial_allocation* config on read from the DB if the values are 0.0. Then add an online data migration that updates all compute_nodes table records that have 0.0 allocation ratios. Then we drop that at some point with a blocker migration.","commit_id":"dff0cc41337e693b0029ec5123fc91697ce408cf"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"307817c2d0ed65832f224651fbd1e3f3da485867","unresolved":false,"context_lines":[{"line_number":110,"context_line":"``ram_allocation_ratio`` and ``disk_allocation_ratio`` CONF options **if the"},{"line_number":111,"context_line":"value of these options is NOT ``None``**."},{"line_number":112,"context_line":""},{"line_number":113,"context_line":"In other words, if any of these CONF options is set to something *other than*"},{"line_number":114,"context_line":"``None``, then the CONF option should be considered the complete override value"},{"line_number":115,"context_line":"for that resource class\u0027 allocation ratio. Even if an admin manually adjusts"},{"line_number":116,"context_line":"the allocation ratio of the resource class in the placement API, the next time"},{"line_number":117,"context_line":"the ``update_available_resource()`` periodic task runs, it will be overwritten"}],"source_content_type":"text/x-rst","patch_set":5,"id":"3f79a3b5_9cd194cd","line":114,"range":{"start_line":113,"start_character":16,"end_line":114,"end_character":9},"in_reply_to":"3f79a3b5_3c3160ee","updated":"2018-10-10 16:35:06.000000000","message":"Although there are some scheduler filters and weighers that read the allocation ratios off the compute node object:\n\nhttps://github.com/openstack/nova/blob/6bf11e1dc14afad78b11d980c2544a3dc41579ff/nova/scheduler/host_manager.py#L256","commit_id":"dff0cc41337e693b0029ec5123fc91697ce408cf"},{"author":{"_account_id":7,"name":"Jay Pipes","email":"jaypipes@gmail.com","username":"jaypipes"},"change_message_id":"542c7eaced53c38127193f3473fad04df4adf779","unresolved":false,"context_lines":[{"line_number":110,"context_line":"``ram_allocation_ratio`` and ``disk_allocation_ratio`` CONF options **if the"},{"line_number":111,"context_line":"value of these options is NOT ``None``**."},{"line_number":112,"context_line":""},{"line_number":113,"context_line":"In other words, if any of these CONF options is set to something *other than*"},{"line_number":114,"context_line":"``None``, then the CONF option should be considered the complete override value"},{"line_number":115,"context_line":"for that resource class\u0027 allocation ratio. Even if an admin manually adjusts"},{"line_number":116,"context_line":"the allocation ratio of the resource class in the placement API, the next time"},{"line_number":117,"context_line":"the ``update_available_resource()`` periodic task runs, it will be overwritten"}],"source_content_type":"text/x-rst","patch_set":5,"id":"3f79a3b5_50ae69e4","line":114,"range":{"start_line":113,"start_character":16,"end_line":114,"end_character":9},"in_reply_to":"3f79a3b5_4fa26041","updated":"2018-10-11 12:38:52.000000000","message":"\u003e So, I think we can probably update the compute node records with\n \u003e the same policy we use to update placement. That being \"set them if\n \u003e they\u0027re overridden in config, otherwise leave them alone\". Longer\n \u003e term, we should probably work to either remove those extra uses in\n \u003e the scheduler, or work on getting the placement-resident ratios\n \u003e communicated back to the scheduler during /a_c and update our\n \u003e host_state objects before we dive into the filters.\n\nThat\u0027s already done:\n\nhttps://github.com/openstack/placement/blob/2c87b3524508b7e56879b13c7f5bc8a516582490/placement/objects/resource_provider.py#L3324-L3333\n\nThe \"capacity\" field of the provider summary accounts for the allocation ratio stored in placement. There\u0027s no reason I can think of to communicate the actual allocation ratio back to the scheduler filters versus the capacity, which already takes into account usage as well as allocation ratio.","commit_id":"dff0cc41337e693b0029ec5123fc91697ce408cf"},{"author":{"_account_id":20722,"name":"Yikun Jiang","email":"yikunkero@gmail.com","username":"yikunkero"},"change_message_id":"7f41cc02d7af7f0e87515198322854ff99a5d1dd","unresolved":false,"context_lines":[{"line_number":110,"context_line":"``ram_allocation_ratio`` and ``disk_allocation_ratio`` CONF options **if the"},{"line_number":111,"context_line":"value of these options is NOT ``None``**."},{"line_number":112,"context_line":""},{"line_number":113,"context_line":"In other words, if any of these CONF options is set to something *other than*"},{"line_number":114,"context_line":"``None``, then the CONF option should be considered the complete override value"},{"line_number":115,"context_line":"for that resource class\u0027 allocation ratio. Even if an admin manually adjusts"},{"line_number":116,"context_line":"the allocation ratio of the resource class in the placement API, the next time"},{"line_number":117,"context_line":"the ``update_available_resource()`` periodic task runs, it will be overwritten"}],"source_content_type":"text/x-rst","patch_set":5,"id":"3f79a3b5_916427b5","line":114,"range":{"start_line":113,"start_character":16,"end_line":114,"end_character":9},"in_reply_to":"3f79a3b5_83b4ec37","updated":"2018-10-10 09:53:59.000000000","message":"Yes, I will add this in next PS.\n\nand I think if db value is 0.0(the node add before bug/1789654 fix) or None(the node after bug/1789654 fix), we should migrate it to initial_allocation* to keep the same db value after this bp, right?","commit_id":"dff0cc41337e693b0029ec5123fc91697ce408cf"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"7d017c65accac036b5ddd6f15b369496ef02e494","unresolved":false,"context_lines":[{"line_number":110,"context_line":"``ram_allocation_ratio`` and ``disk_allocation_ratio`` CONF options **if the"},{"line_number":111,"context_line":"value of these options is NOT ``None``**."},{"line_number":112,"context_line":""},{"line_number":113,"context_line":"In other words, if any of these CONF options is set to something *other than*"},{"line_number":114,"context_line":"``None``, then the CONF option should be considered the complete override value"},{"line_number":115,"context_line":"for that resource class\u0027 allocation ratio. Even if an admin manually adjusts"},{"line_number":116,"context_line":"the allocation ratio of the resource class in the placement API, the next time"},{"line_number":117,"context_line":"the ``update_available_resource()`` periodic task runs, it will be overwritten"}],"source_content_type":"text/x-rst","patch_set":5,"id":"3f79a3b5_3c3160ee","line":114,"range":{"start_line":113,"start_character":16,"end_line":114,"end_character":9},"in_reply_to":"3f79a3b5_876f0292","updated":"2018-10-10 16:08:30.000000000","message":"Right, I think we mentioned that in Denver. Once we have the two configs, based on those we can just explicitly override or not the values when we\u0027re processing inventory. We don\u0027t need to care about the values on the records in the database anymore going forward.","commit_id":"dff0cc41337e693b0029ec5123fc91697ce408cf"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"b6b88fdce9aea73a12bed4ebfc82f840015102b3","unresolved":false,"context_lines":[{"line_number":110,"context_line":"``ram_allocation_ratio`` and ``disk_allocation_ratio`` CONF options **if the"},{"line_number":111,"context_line":"value of these options is NOT ``None``**."},{"line_number":112,"context_line":""},{"line_number":113,"context_line":"In other words, if any of these CONF options is set to something *other than*"},{"line_number":114,"context_line":"``None``, then the CONF option should be considered the complete override value"},{"line_number":115,"context_line":"for that resource class\u0027 allocation ratio. Even if an admin manually adjusts"},{"line_number":116,"context_line":"the allocation ratio of the resource class in the placement API, the next time"},{"line_number":117,"context_line":"the ``update_available_resource()`` periodic task runs, it will be overwritten"}],"source_content_type":"text/x-rst","patch_set":5,"id":"3f79a3b5_876f0292","line":114,"range":{"start_line":113,"start_character":16,"end_line":114,"end_character":9},"in_reply_to":"3f79a3b5_916427b5","updated":"2018-10-10 14:54:05.000000000","message":"Alternatively, we just never look at ComputeNode.*_allocation_ratio attributes anymore. The ResourceTracker._normalize_inventory_from_cn_obj method would just look at config after this change, not the ComputeNode object.","commit_id":"dff0cc41337e693b0029ec5123fc91697ce408cf"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"f235a11c1b8184aed7263fce2e73c66e56012179","unresolved":false,"context_lines":[{"line_number":110,"context_line":"``ram_allocation_ratio`` and ``disk_allocation_ratio`` CONF options **if the"},{"line_number":111,"context_line":"value of these options is NOT ``None``**."},{"line_number":112,"context_line":""},{"line_number":113,"context_line":"In other words, if any of these CONF options is set to something *other than*"},{"line_number":114,"context_line":"``None``, then the CONF option should be considered the complete override value"},{"line_number":115,"context_line":"for that resource class\u0027 allocation ratio. Even if an admin manually adjusts"},{"line_number":116,"context_line":"the allocation ratio of the resource class in the placement API, the next time"},{"line_number":117,"context_line":"the ``update_available_resource()`` periodic task runs, it will be overwritten"}],"source_content_type":"text/x-rst","patch_set":5,"id":"3f79a3b5_4fa26041","line":114,"range":{"start_line":113,"start_character":16,"end_line":114,"end_character":9},"in_reply_to":"3f79a3b5_9cd194cd","updated":"2018-10-10 17:21:18.000000000","message":"Yeah, okay, I didn\u0027t expect that they were used outside of the filters that we have since deprecated. Those uses of the ratios are/were already kinda wrong with the aggregate-based ratios that we broke recently I think. But with moving to a world where the placement values can be authoritative, they\u0027ll be wrong whether they look at the values on the compute node object or not.\n\nSo, I think we can probably update the compute node records with the same policy we use to update placement. That being \"set them if they\u0027re overridden in config, otherwise leave them alone\". Longer term, we should probably work to either remove those extra uses in the scheduler, or work on getting the placement-resident ratios communicated back to the scheduler during /a_c and update our host_state objects before we dive into the filters.","commit_id":"dff0cc41337e693b0029ec5123fc91697ce408cf"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"985e95fe871e882e31d98574d94d5b826301e151","unresolved":false,"context_lines":[{"line_number":110,"context_line":"``ram_allocation_ratio`` and ``disk_allocation_ratio`` CONF options **if the"},{"line_number":111,"context_line":"value of these options is NOT ``None``**."},{"line_number":112,"context_line":""},{"line_number":113,"context_line":"In other words, if any of these CONF options is set to something *other than*"},{"line_number":114,"context_line":"``None``, then the CONF option should be considered the complete override value"},{"line_number":115,"context_line":"for that resource class\u0027 allocation ratio. Even if an admin manually adjusts"},{"line_number":116,"context_line":"the allocation ratio of the resource class in the placement API, the next time"},{"line_number":117,"context_line":"the ``update_available_resource()`` periodic task runs, it will be overwritten"}],"source_content_type":"text/x-rst","patch_set":5,"id":"3f79a3b5_83b4ec37","line":114,"range":{"start_line":113,"start_character":16,"end_line":114,"end_character":9},"in_reply_to":"3f79a3b5_c093baa3","updated":"2018-10-09 21:06:52.000000000","message":"Also, we\u0027d have a nova-status upgrade check to iterate the cells looking for compute_nodes records with 0.0 allocation ratios and signal that as a warning that you haven\u0027t done the online data migration. We could also check the conf options to see if they are explicitly set to 0.0 and if so, we should fail the status check.","commit_id":"dff0cc41337e693b0029ec5123fc91697ce408cf"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"985e95fe871e882e31d98574d94d5b826301e151","unresolved":false,"context_lines":[{"line_number":112,"context_line":""},{"line_number":113,"context_line":"In other words, if any of these CONF options is set to something *other than*"},{"line_number":114,"context_line":"``None``, then the CONF option should be considered the complete override value"},{"line_number":115,"context_line":"for that resource class\u0027 allocation ratio. Even if an admin manually adjusts"},{"line_number":116,"context_line":"the allocation ratio of the resource class in the placement API, the next time"},{"line_number":117,"context_line":"the ``update_available_resource()`` periodic task runs, it will be overwritten"},{"line_number":118,"context_line":"to the value of the CONF option."},{"line_number":119,"context_line":""},{"line_number":120,"context_line":"Second, add three new CONF options to the nova.conf file:"},{"line_number":121,"context_line":""}],"source_content_type":"text/x-rst","patch_set":5,"id":"3f79a3b5_835f0c0e","line":118,"range":{"start_line":115,"start_character":43,"end_line":118,"end_character":32},"updated":"2018-10-09 21:06:52.000000000","message":"Yup, this means you can either drive this stuff via config (CERN does this) or the API (internap/iweb does this), but not both. Config trumps the API if set.","commit_id":"dff0cc41337e693b0029ec5123fc91697ce408cf"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"985e95fe871e882e31d98574d94d5b826301e151","unresolved":false,"context_lines":[{"line_number":182,"context_line":"Upgrade impact"},{"line_number":183,"context_line":"--------------"},{"line_number":184,"context_line":""},{"line_number":185,"context_line":"None, however clearly in order to take advantage of the ability to manually set"},{"line_number":186,"context_line":"allocation ratios on a compute node, that hypervisor would need to be upgraded."},{"line_number":187,"context_line":"No impact to old compute hosts."},{"line_number":188,"context_line":""},{"line_number":189,"context_line":"Implementation"},{"line_number":190,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"}],"source_content_type":"text/x-rst","patch_set":5,"id":"3f79a3b5_23f2b806","line":187,"range":{"start_line":185,"start_character":0,"end_line":187,"end_character":31},"updated":"2018-10-09 21:06:52.000000000","message":"As noted above around L114 I believe there is an upgrade impact and we have to do online data migrations for any compute_nodes with existing 0.0 allocation ratios.","commit_id":"dff0cc41337e693b0029ec5123fc91697ce408cf"},{"author":{"_account_id":20722,"name":"Yikun Jiang","email":"yikunkero@gmail.com","username":"yikunkero"},"change_message_id":"7f41cc02d7af7f0e87515198322854ff99a5d1dd","unresolved":false,"context_lines":[{"line_number":182,"context_line":"Upgrade impact"},{"line_number":183,"context_line":"--------------"},{"line_number":184,"context_line":""},{"line_number":185,"context_line":"None, however clearly in order to take advantage of the ability to manually set"},{"line_number":186,"context_line":"allocation ratios on a compute node, that hypervisor would need to be upgraded."},{"line_number":187,"context_line":"No impact to old compute hosts."},{"line_number":188,"context_line":""},{"line_number":189,"context_line":"Implementation"},{"line_number":190,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"}],"source_content_type":"text/x-rst","patch_set":5,"id":"3f79a3b5_11833705","line":187,"range":{"start_line":185,"start_character":0,"end_line":187,"end_character":31},"in_reply_to":"3f79a3b5_23f2b806","updated":"2018-10-10 09:53:59.000000000","message":"Done, and also need adress None and 0.0","commit_id":"dff0cc41337e693b0029ec5123fc91697ce408cf"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"985e95fe871e882e31d98574d94d5b826301e151","unresolved":false,"context_lines":[{"line_number":237,"context_line":"* When the deployer wants to **ALWAYS** use the placement API to set allocation"},{"line_number":238,"context_line":"  ratios, then the deployer should ensure that ``CONF.xxx_allocation_ratio``"},{"line_number":239,"context_line":"  options are all set to ``None`` and the deployer should issue calls to"},{"line_number":240,"context_line":"  ``openstack provider inventory update`` to set the allocation ratios of their"},{"line_number":241,"context_line":"  resources as needed"},{"line_number":242,"context_line":""},{"line_number":243,"context_line":"References"}],"source_content_type":"text/x-rst","patch_set":5,"id":"3f79a3b5_83694c8d","line":240,"range":{"start_line":240,"start_character":4,"end_line":240,"end_character":39},"updated":"2018-10-09 21:06:52.000000000","message":"openstack resource provider inventory class set:\n\nhttps://docs.openstack.org/osc-placement/latest/cli/index.html#resource-provider-inventory-class-set\n\nor\n\nopenstack resource provider inventory set:\n\nhttps://docs.openstack.org/osc-placement/latest/cli/index.html#resource-provider-inventory-set","commit_id":"dff0cc41337e693b0029ec5123fc91697ce408cf"},{"author":{"_account_id":20722,"name":"Yikun Jiang","email":"yikunkero@gmail.com","username":"yikunkero"},"change_message_id":"7f41cc02d7af7f0e87515198322854ff99a5d1dd","unresolved":false,"context_lines":[{"line_number":237,"context_line":"* When the deployer wants to **ALWAYS** use the placement API to set allocation"},{"line_number":238,"context_line":"  ratios, then the deployer should ensure that ``CONF.xxx_allocation_ratio``"},{"line_number":239,"context_line":"  options are all set to ``None`` and the deployer should issue calls to"},{"line_number":240,"context_line":"  ``openstack provider inventory update`` to set the allocation ratios of their"},{"line_number":241,"context_line":"  resources as needed"},{"line_number":242,"context_line":""},{"line_number":243,"context_line":"References"}],"source_content_type":"text/x-rst","patch_set":5,"id":"3f79a3b5_d1c29f35","line":240,"range":{"start_line":240,"start_character":4,"end_line":240,"end_character":39},"in_reply_to":"3f79a3b5_83694c8d","updated":"2018-10-10 09:53:59.000000000","message":"Done","commit_id":"dff0cc41337e693b0029ec5123fc91697ce408cf"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"985e95fe871e882e31d98574d94d5b826301e151","unresolved":false,"context_lines":[{"line_number":240,"context_line":"  ``openstack provider inventory update`` to set the allocation ratios of their"},{"line_number":241,"context_line":"  resources as needed"},{"line_number":242,"context_line":""},{"line_number":243,"context_line":"References"},{"line_number":244,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"},{"line_number":245,"context_line":""},{"line_number":246,"context_line":"Bugs:"}],"source_content_type":"text/x-rst","patch_set":5,"id":"3f79a3b5_c3e2e402","line":243,"updated":"2018-10-09 21:06:52.000000000","message":"Could also reference the PTG discussion:\n\nhttps://etherpad.openstack.org/p/nova-ptg-stein","commit_id":"dff0cc41337e693b0029ec5123fc91697ce408cf"},{"author":{"_account_id":20722,"name":"Yikun Jiang","email":"yikunkero@gmail.com","username":"yikunkero"},"change_message_id":"7f41cc02d7af7f0e87515198322854ff99a5d1dd","unresolved":false,"context_lines":[{"line_number":240,"context_line":"  ``openstack provider inventory update`` to set the allocation ratios of their"},{"line_number":241,"context_line":"  resources as needed"},{"line_number":242,"context_line":""},{"line_number":243,"context_line":"References"},{"line_number":244,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"},{"line_number":245,"context_line":""},{"line_number":246,"context_line":"Bugs:"}],"source_content_type":"text/x-rst","patch_set":5,"id":"3f79a3b5_11e6d7e8","line":243,"in_reply_to":"3f79a3b5_c3e2e402","updated":"2018-10-10 09:53:59.000000000","message":"Done","commit_id":"dff0cc41337e693b0029ec5123fc91697ce408cf"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"985e95fe871e882e31d98574d94d5b826301e151","unresolved":false,"context_lines":[{"line_number":258,"context_line":""},{"line_number":259,"context_line":"   * - Release Name"},{"line_number":260,"context_line":"     - Description"},{"line_number":261,"context_line":"   * - Rocky"},{"line_number":262,"context_line":"     - Originally proposed with ``0.0`` default values for ``CONF.xxx_allocation_ratio`` options"},{"line_number":263,"context_line":"   * - Stein"},{"line_number":264,"context_line":"     - Re-proposed with ``None`` default values for ``CONF.xxx_allocation_ratio`` options"}],"source_content_type":"text/x-rst","patch_set":5,"id":"3f79a3b5_e3efe0f7","line":264,"range":{"start_line":261,"start_character":3,"end_line":264,"end_character":89},"updated":"2018-10-09 21:06:52.000000000","message":"I would drop Rocky from this and just say it\u0027s initially proposed for Stein since it was never accepted in Rocky.","commit_id":"dff0cc41337e693b0029ec5123fc91697ce408cf"},{"author":{"_account_id":20722,"name":"Yikun Jiang","email":"yikunkero@gmail.com","username":"yikunkero"},"change_message_id":"7f41cc02d7af7f0e87515198322854ff99a5d1dd","unresolved":false,"context_lines":[{"line_number":258,"context_line":""},{"line_number":259,"context_line":"   * - Release Name"},{"line_number":260,"context_line":"     - Description"},{"line_number":261,"context_line":"   * - Rocky"},{"line_number":262,"context_line":"     - Originally proposed with ``0.0`` default values for ``CONF.xxx_allocation_ratio`` options"},{"line_number":263,"context_line":"   * - Stein"},{"line_number":264,"context_line":"     - Re-proposed with ``None`` default values for ``CONF.xxx_allocation_ratio`` options"}],"source_content_type":"text/x-rst","patch_set":5,"id":"3f79a3b5_11ffb766","line":264,"range":{"start_line":261,"start_character":3,"end_line":264,"end_character":89},"in_reply_to":"3f79a3b5_e3efe0f7","updated":"2018-10-10 09:53:59.000000000","message":"Done","commit_id":"dff0cc41337e693b0029ec5123fc91697ce408cf"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"2b2345089e43a2fb7eabb24b911f5a6092bd284b","unresolved":false,"context_lines":[{"line_number":34,"context_line":""},{"line_number":35,"context_line":"Upon starting up, the resource tracker in the ``nova-compute`` service worker"},{"line_number":36,"context_line":"`checks`_ to see if a record exists in the ``compute_nodes`` table of the nova"},{"line_number":37,"context_line":"cell DB for itself. If it does not find one, the resource tracker `creates`_ a"},{"line_number":38,"context_line":"record in the table, `setting`_ the associated allocation ratio values in the"},{"line_number":39,"context_line":"``compute_nodes`` table to the value it finds in the ``cpu_allocation_ratio``,"},{"line_number":40,"context_line":"``ram_allocation_ratio`` and ``disk_allocation_ratio`` nova.conf configuration"},{"line_number":41,"context_line":"options."},{"line_number":42,"context_line":""},{"line_number":43,"context_line":".. _checks: https://github.com/openstack/nova/blob/852de1e/nova/compute/resource_tracker.py#L566"},{"line_number":44,"context_line":".. _creates: https://github.com/openstack/nova/blob/852de1e/nova/compute/resource_tracker.py#L577-L590"}],"source_content_type":"text/x-rst","patch_set":7,"id":"3f79a3b5_dc12ac61","line":41,"range":{"start_line":37,"start_character":20,"end_line":41,"end_character":8},"updated":"2018-10-10 16:54:05.000000000","message":"As mentioned in PS5, this is not completely accurate since change I43a23a3290db0c835fed01b8d6a38962dc61adce so it\u0027s probably more accurate to say the above with \"but only if the config option value is not equal to 0.0.\".","commit_id":"28e69040e050ee5568f4f85fb9842e1737dcad59"},{"author":{"_account_id":20722,"name":"Yikun Jiang","email":"yikunkero@gmail.com","username":"yikunkero"},"change_message_id":"614aa3474887fb0438bb437e701afdb37655a266","unresolved":false,"context_lines":[{"line_number":34,"context_line":""},{"line_number":35,"context_line":"Upon starting up, the resource tracker in the ``nova-compute`` service worker"},{"line_number":36,"context_line":"`checks`_ to see if a record exists in the ``compute_nodes`` table of the nova"},{"line_number":37,"context_line":"cell DB for itself. If it does not find one, the resource tracker `creates`_ a"},{"line_number":38,"context_line":"record in the table, `setting`_ the associated allocation ratio values in the"},{"line_number":39,"context_line":"``compute_nodes`` table to the value it finds in the ``cpu_allocation_ratio``,"},{"line_number":40,"context_line":"``ram_allocation_ratio`` and ``disk_allocation_ratio`` nova.conf configuration"},{"line_number":41,"context_line":"options."},{"line_number":42,"context_line":""},{"line_number":43,"context_line":".. _checks: https://github.com/openstack/nova/blob/852de1e/nova/compute/resource_tracker.py#L566"},{"line_number":44,"context_line":".. _creates: https://github.com/openstack/nova/blob/852de1e/nova/compute/resource_tracker.py#L577-L590"}],"source_content_type":"text/x-rst","patch_set":7,"id":"3f79a3b5_cbfdf66d","line":41,"range":{"start_line":37,"start_character":20,"end_line":41,"end_character":8},"in_reply_to":"3f79a3b5_dc12ac61","updated":"2018-10-11 08:36:16.000000000","message":"Done","commit_id":"28e69040e050ee5568f4f85fb9842e1737dcad59"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"2b2345089e43a2fb7eabb24b911f5a6092bd284b","unresolved":false,"context_lines":[{"line_number":98,"context_line":"First, we propose to change the default option values of existing"},{"line_number":99,"context_line":"``CONF.cpu_allocation_ratio``, ``CONF.ram_allocation_ratio`` and"},{"line_number":100,"context_line":"``CONF.disk_allocation_ratio`` options relating to allocation ratios to"},{"line_number":101,"context_line":"``None`` from the existing default values of ``0.0``. The reason of we change"},{"line_number":102,"context_line":"it is that this value will be change from ``0.0`` to ``16.0``, ``1.5`` or"},{"line_number":103,"context_line":"``1.0`` later, which is wired and confusing."},{"line_number":104,"context_line":""}],"source_content_type":"text/x-rst","patch_set":7,"id":"3f79a3b5_ef232ca9","line":101,"range":{"start_line":101,"start_character":65,"end_line":101,"end_character":67},"updated":"2018-10-10 16:54:05.000000000","message":"s/of//","commit_id":"28e69040e050ee5568f4f85fb9842e1737dcad59"},{"author":{"_account_id":20722,"name":"Yikun Jiang","email":"yikunkero@gmail.com","username":"yikunkero"},"change_message_id":"614aa3474887fb0438bb437e701afdb37655a266","unresolved":false,"context_lines":[{"line_number":98,"context_line":"First, we propose to change the default option values of existing"},{"line_number":99,"context_line":"``CONF.cpu_allocation_ratio``, ``CONF.ram_allocation_ratio`` and"},{"line_number":100,"context_line":"``CONF.disk_allocation_ratio`` options relating to allocation ratios to"},{"line_number":101,"context_line":"``None`` from the existing default values of ``0.0``. The reason of we change"},{"line_number":102,"context_line":"it is that this value will be change from ``0.0`` to ``16.0``, ``1.5`` or"},{"line_number":103,"context_line":"``1.0`` later, which is wired and confusing."},{"line_number":104,"context_line":""}],"source_content_type":"text/x-rst","patch_set":7,"id":"3f79a3b5_4be9e6a8","line":101,"range":{"start_line":101,"start_character":65,"end_line":101,"end_character":67},"in_reply_to":"3f79a3b5_ef232ca9","updated":"2018-10-11 08:36:16.000000000","message":"Done","commit_id":"28e69040e050ee5568f4f85fb9842e1737dcad59"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"2b2345089e43a2fb7eabb24b911f5a6092bd284b","unresolved":false,"context_lines":[{"line_number":100,"context_line":"``CONF.disk_allocation_ratio`` options relating to allocation ratios to"},{"line_number":101,"context_line":"``None`` from the existing default values of ``0.0``. The reason of we change"},{"line_number":102,"context_line":"it is that this value will be change from ``0.0`` to ``16.0``, ``1.5`` or"},{"line_number":103,"context_line":"``1.0`` later, which is wired and confusing."},{"line_number":104,"context_line":""},{"line_number":105,"context_line":"there is a wired 0.0 default behavior which will change the values from"},{"line_number":106,"context_line":"``0.0`` to ."}],"source_content_type":"text/x-rst","patch_set":7,"id":"3f79a3b5_af1d3463","line":103,"range":{"start_line":103,"start_character":24,"end_line":103,"end_character":29},"updated":"2018-10-10 16:54:05.000000000","message":"weird","commit_id":"28e69040e050ee5568f4f85fb9842e1737dcad59"},{"author":{"_account_id":20722,"name":"Yikun Jiang","email":"yikunkero@gmail.com","username":"yikunkero"},"change_message_id":"614aa3474887fb0438bb437e701afdb37655a266","unresolved":false,"context_lines":[{"line_number":100,"context_line":"``CONF.disk_allocation_ratio`` options relating to allocation ratios to"},{"line_number":101,"context_line":"``None`` from the existing default values of ``0.0``. The reason of we change"},{"line_number":102,"context_line":"it is that this value will be change from ``0.0`` to ``16.0``, ``1.5`` or"},{"line_number":103,"context_line":"``1.0`` later, which is wired and confusing."},{"line_number":104,"context_line":""},{"line_number":105,"context_line":"there is a wired 0.0 default behavior which will change the values from"},{"line_number":106,"context_line":"``0.0`` to ."}],"source_content_type":"text/x-rst","patch_set":7,"id":"3f79a3b5_8b385e3b","line":103,"range":{"start_line":103,"start_character":24,"end_line":103,"end_character":29},"in_reply_to":"3f79a3b5_af1d3463","updated":"2018-10-11 08:36:16.000000000","message":"Done","commit_id":"28e69040e050ee5568f4f85fb9842e1737dcad59"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"2b2345089e43a2fb7eabb24b911f5a6092bd284b","unresolved":false,"context_lines":[{"line_number":102,"context_line":"it is that this value will be change from ``0.0`` to ``16.0``, ``1.5`` or"},{"line_number":103,"context_line":"``1.0`` later, which is wired and confusing."},{"line_number":104,"context_line":""},{"line_number":105,"context_line":"there is a wired 0.0 default behavior which will change the values from"},{"line_number":106,"context_line":"``0.0`` to ."},{"line_number":107,"context_line":""},{"line_number":108,"context_line":"We will also change the resource tracker to **only** overwrite the compute"},{"line_number":109,"context_line":"node\u0027s allocation ratios to the value of the ``cpu_allocation_ratio``,"}],"source_content_type":"text/x-rst","patch_set":7,"id":"3f79a3b5_cf5510fb","line":106,"range":{"start_line":105,"start_character":0,"end_line":106,"end_character":12},"updated":"2018-10-10 16:54:05.000000000","message":"Remove this. You said it above.","commit_id":"28e69040e050ee5568f4f85fb9842e1737dcad59"},{"author":{"_account_id":20722,"name":"Yikun Jiang","email":"yikunkero@gmail.com","username":"yikunkero"},"change_message_id":"614aa3474887fb0438bb437e701afdb37655a266","unresolved":false,"context_lines":[{"line_number":102,"context_line":"it is that this value will be change from ``0.0`` to ``16.0``, ``1.5`` or"},{"line_number":103,"context_line":"``1.0`` later, which is wired and confusing."},{"line_number":104,"context_line":""},{"line_number":105,"context_line":"there is a wired 0.0 default behavior which will change the values from"},{"line_number":106,"context_line":"``0.0`` to ."},{"line_number":107,"context_line":""},{"line_number":108,"context_line":"We will also change the resource tracker to **only** overwrite the compute"},{"line_number":109,"context_line":"node\u0027s allocation ratios to the value of the ``cpu_allocation_ratio``,"}],"source_content_type":"text/x-rst","patch_set":7,"id":"3f79a3b5_4b3ec626","line":106,"range":{"start_line":105,"start_character":0,"end_line":106,"end_character":12},"in_reply_to":"3f79a3b5_cf5510fb","updated":"2018-10-11 08:36:16.000000000","message":"Done","commit_id":"28e69040e050ee5568f4f85fb9842e1737dcad59"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"2b2345089e43a2fb7eabb24b911f5a6092bd284b","unresolved":false,"context_lines":[{"line_number":140,"context_line":"nova cell DB for that hypervisor."},{"line_number":141,"context_line":""},{"line_number":142,"context_line":"Finally, we will need also add an online data migration and continue to read"},{"line_number":143,"context_line":"the initial_allocation* config on read from the DB if the values are ``0.0``"},{"line_number":144,"context_line":"or ``None``. Then add an online data migration that updates all compute_nodes"},{"line_number":145,"context_line":"table records that have ``0.0`` or ``None`` allocation ratios. Then we drop"},{"line_number":146,"context_line":"that at some point with a blocker migration and emove the code in the"}],"source_content_type":"text/x-rst","patch_set":7,"id":"3f79a3b5_af79b482","line":143,"range":{"start_line":143,"start_character":4,"end_line":143,"end_character":22},"updated":"2018-10-10 16:54:05.000000000","message":"Well, would we only use the initial allocation ratio on upgrade? If it\u0027s an existing record with 0.0 values, we\u0027d want to do what the compute does, which is use the configure *_allocation_ratio config if it\u0027s not None, and fallback to using the initial_*_allocation_ratio otherwise.","commit_id":"28e69040e050ee5568f4f85fb9842e1737dcad59"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"2b2345089e43a2fb7eabb24b911f5a6092bd284b","unresolved":false,"context_lines":[{"line_number":140,"context_line":"nova cell DB for that hypervisor."},{"line_number":141,"context_line":""},{"line_number":142,"context_line":"Finally, we will need also add an online data migration and continue to read"},{"line_number":143,"context_line":"the initial_allocation* config on read from the DB if the values are ``0.0``"},{"line_number":144,"context_line":"or ``None``. Then add an online data migration that updates all compute_nodes"},{"line_number":145,"context_line":"table records that have ``0.0`` or ``None`` allocation ratios. Then we drop"},{"line_number":146,"context_line":"that at some point with a blocker migration and emove the code in the"}],"source_content_type":"text/x-rst","patch_set":7,"id":"3f79a3b5_2f5fe40f","line":143,"range":{"start_line":143,"start_character":22,"end_line":143,"end_character":23},"updated":"2018-10-10 16:54:05.000000000","message":"missing opening * for formatting","commit_id":"28e69040e050ee5568f4f85fb9842e1737dcad59"},{"author":{"_account_id":20722,"name":"Yikun Jiang","email":"yikunkero@gmail.com","username":"yikunkero"},"change_message_id":"614aa3474887fb0438bb437e701afdb37655a266","unresolved":false,"context_lines":[{"line_number":140,"context_line":"nova cell DB for that hypervisor."},{"line_number":141,"context_line":""},{"line_number":142,"context_line":"Finally, we will need also add an online data migration and continue to read"},{"line_number":143,"context_line":"the initial_allocation* config on read from the DB if the values are ``0.0``"},{"line_number":144,"context_line":"or ``None``. Then add an online data migration that updates all compute_nodes"},{"line_number":145,"context_line":"table records that have ``0.0`` or ``None`` allocation ratios. Then we drop"},{"line_number":146,"context_line":"that at some point with a blocker migration and emove the code in the"}],"source_content_type":"text/x-rst","patch_set":7,"id":"3f79a3b5_ae544857","line":143,"range":{"start_line":143,"start_character":4,"end_line":143,"end_character":22},"in_reply_to":"3f79a3b5_af79b482","updated":"2018-10-11 08:36:16.000000000","message":"Done","commit_id":"28e69040e050ee5568f4f85fb9842e1737dcad59"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"2b2345089e43a2fb7eabb24b911f5a6092bd284b","unresolved":false,"context_lines":[{"line_number":143,"context_line":"the initial_allocation* config on read from the DB if the values are ``0.0``"},{"line_number":144,"context_line":"or ``None``. Then add an online data migration that updates all compute_nodes"},{"line_number":145,"context_line":"table records that have ``0.0`` or ``None`` allocation ratios. Then we drop"},{"line_number":146,"context_line":"that at some point with a blocker migration and emove the code in the"},{"line_number":147,"context_line":"``nova.objects.ComputeNode._from_db_obj`` that adjusts allocation ratios."},{"line_number":148,"context_line":""},{"line_number":149,"context_line":"We propose to add a nova-status upgrade check to iterate the cells looking"}],"source_content_type":"text/x-rst","patch_set":7,"id":"3f79a3b5_8f8e3878","line":146,"range":{"start_line":146,"start_character":48,"end_line":146,"end_character":53},"updated":"2018-10-10 16:54:05.000000000","message":"remove","commit_id":"28e69040e050ee5568f4f85fb9842e1737dcad59"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"2b2345089e43a2fb7eabb24b911f5a6092bd284b","unresolved":false,"context_lines":[{"line_number":266,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"},{"line_number":267,"context_line":""},{"line_number":268,"context_line":"Nova Stein PTG discussion:"},{"line_number":269,"context_line":"* https://etherpad.openstack.org/p/nova-ptg-stein"},{"line_number":270,"context_line":""},{"line_number":271,"context_line":"Bugs:"},{"line_number":272,"context_line":""}],"source_content_type":"text/x-rst","patch_set":7,"id":"3f79a3b5_0f36a8b4","line":269,"updated":"2018-10-10 16:54:05.000000000","message":"This doesn\u0027t format properly:\n\nhttp://logs.openstack.org/05/552105/7/check/openstack-tox-docs/7037129/html/specs/stein/approved/initial-allocation-ratios.html#references\n\nEither add a blank line before the bullet list or remove the bullet list.","commit_id":"28e69040e050ee5568f4f85fb9842e1737dcad59"},{"author":{"_account_id":20722,"name":"Yikun Jiang","email":"yikunkero@gmail.com","username":"yikunkero"},"change_message_id":"614aa3474887fb0438bb437e701afdb37655a266","unresolved":false,"context_lines":[{"line_number":266,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"},{"line_number":267,"context_line":""},{"line_number":268,"context_line":"Nova Stein PTG discussion:"},{"line_number":269,"context_line":"* https://etherpad.openstack.org/p/nova-ptg-stein"},{"line_number":270,"context_line":""},{"line_number":271,"context_line":"Bugs:"},{"line_number":272,"context_line":""}],"source_content_type":"text/x-rst","patch_set":7,"id":"3f79a3b5_eeec8093","line":269,"in_reply_to":"3f79a3b5_0f36a8b4","updated":"2018-10-11 08:36:16.000000000","message":"Done","commit_id":"28e69040e050ee5568f4f85fb9842e1737dcad59"},{"author":{"_account_id":7166,"name":"Sylvain Bauza","email":"sbauza@redhat.com","username":"sbauza"},"change_message_id":"4d23626e59e2091640ae0b349c9318d1aff08a71","unresolved":false,"context_lines":[{"line_number":14,"context_line":"ratio for compute nodes. Change the default values for"},{"line_number":15,"context_line":"CONF.xxx_allocation_ratio options to None and change the behaviour of"},{"line_number":16,"context_line":"the resource tracker to only override allocation ratios for *existing*"},{"line_number":17,"context_line":"compute nodes if the CONF.xxx_allocation_ratio value is not None."},{"line_number":18,"context_line":""},{"line_number":19,"context_line":"Problem description"},{"line_number":20,"context_line":"\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":8,"id":"3f79a3b5_363966a2","line":17,"updated":"2018-10-12 08:53:57.000000000","message":"Sure, that\u0027s the implementation. But the real goal of this spec is to have a way to fix the bug below and to have in Nova both API and config ways to pass allocation ratios, hence these \"initial allocation ratio\" options. \n\nThat said, it\u0027s a nit.","commit_id":"591d12cda662acc0c4fb085d6dd0d83e10c73987"},{"author":{"_account_id":20722,"name":"Yikun Jiang","email":"yikunkero@gmail.com","username":"yikunkero"},"change_message_id":"4a61c9910fa747205d50d41324d603e67bff11dc","unresolved":false,"context_lines":[{"line_number":14,"context_line":"ratio for compute nodes. Change the default values for"},{"line_number":15,"context_line":"CONF.xxx_allocation_ratio options to None and change the behaviour of"},{"line_number":16,"context_line":"the resource tracker to only override allocation ratios for *existing*"},{"line_number":17,"context_line":"compute nodes if the CONF.xxx_allocation_ratio value is not None."},{"line_number":18,"context_line":""},{"line_number":19,"context_line":"Problem description"},{"line_number":20,"context_line":"\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":8,"id":"3f79a3b5_d676b93f","line":17,"in_reply_to":"3f79a3b5_363966a2","updated":"2018-10-19 01:26:24.000000000","message":"Done","commit_id":"591d12cda662acc0c4fb085d6dd0d83e10c73987"},{"author":{"_account_id":7166,"name":"Sylvain Bauza","email":"sbauza@redhat.com","username":"sbauza"},"change_message_id":"4d23626e59e2091640ae0b349c9318d1aff08a71","unresolved":false,"context_lines":[{"line_number":63,"context_line":"``compute_nodes`` table continues to have the wrong ``0.0`` values. When the"},{"line_number":64,"context_line":"resource tracker runs its ``update_available_resource()`` next perioidic task,"},{"line_number":65,"context_line":"the new ``16.0``/``1.5``/``1.0`` values are then saved to the compute nodes"},{"line_number":66,"context_line":"table. There was a `fix`_ for `bug/1789654`_, which is try to don\u0027t persist"},{"line_number":67,"context_line":"zero allocation ratios in ResourceTracker to avoid to initialized placement"},{"line_number":68,"context_line":"allocation_ratio with 0.0 (due to the allocation ratio of 0.0 being multiplied"},{"line_number":69,"context_line":"by the total amount in inventory, leading to 0 resources shown on the system)."}],"source_content_type":"text/x-rst","patch_set":8,"id":"3f79a3b5_76f83ec0","line":66,"range":{"start_line":66,"start_character":6,"end_line":66,"end_character":16},"updated":"2018-10-12 08:53:57.000000000","message":"There /is/\n\nNow we have this fix, the bug is no longer here so while the saga is important to explain, maybe we should explain it\u0027s no longer a problem, right?","commit_id":"591d12cda662acc0c4fb085d6dd0d83e10c73987"},{"author":{"_account_id":20722,"name":"Yikun Jiang","email":"yikunkero@gmail.com","username":"yikunkero"},"change_message_id":"4a61c9910fa747205d50d41324d603e67bff11dc","unresolved":false,"context_lines":[{"line_number":63,"context_line":"``compute_nodes`` table continues to have the wrong ``0.0`` values. When the"},{"line_number":64,"context_line":"resource tracker runs its ``update_available_resource()`` next perioidic task,"},{"line_number":65,"context_line":"the new ``16.0``/``1.5``/``1.0`` values are then saved to the compute nodes"},{"line_number":66,"context_line":"table. There was a `fix`_ for `bug/1789654`_, which is try to don\u0027t persist"},{"line_number":67,"context_line":"zero allocation ratios in ResourceTracker to avoid to initialized placement"},{"line_number":68,"context_line":"allocation_ratio with 0.0 (due to the allocation ratio of 0.0 being multiplied"},{"line_number":69,"context_line":"by the total amount in inventory, leading to 0 resources shown on the system)."}],"source_content_type":"text/x-rst","patch_set":8,"id":"3f79a3b5_368dad29","line":66,"range":{"start_line":66,"start_character":6,"end_line":66,"end_character":16},"in_reply_to":"3f79a3b5_76f83ec0","updated":"2018-10-19 01:26:24.000000000","message":"Done","commit_id":"591d12cda662acc0c4fb085d6dd0d83e10c73987"},{"author":{"_account_id":7166,"name":"Sylvain Bauza","email":"sbauza@redhat.com","username":"sbauza"},"change_message_id":"4d23626e59e2091640ae0b349c9318d1aff08a71","unresolved":false,"context_lines":[{"line_number":79,"context_line":"individual compute node resource provider\u0027s inventory record in the placement"},{"line_number":80,"context_line":"API without the resource tracker eventually overwriting that value the next"},{"line_number":81,"context_line":"time it runs the ``update_available_resources`` periodic task on the"},{"line_number":82,"context_line":"``nova-compute`` service."},{"line_number":83,"context_line":""},{"line_number":84,"context_line":"Use Cases"},{"line_number":85,"context_line":"---------"}],"source_content_type":"text/x-rst","patch_set":8,"id":"3f79a3b5_169eaa68","line":82,"updated":"2018-10-12 08:53:57.000000000","message":"This ^ is the main reason why we need a spec, right? Like I said above, the saga paragraphs are important for understanding the design, but this paragraph is the main problem description.\n\nAgain, maybe a nit, but I think about operators looking at this spec and trying to understand what and why we change.","commit_id":"591d12cda662acc0c4fb085d6dd0d83e10c73987"},{"author":{"_account_id":20722,"name":"Yikun Jiang","email":"yikunkero@gmail.com","username":"yikunkero"},"change_message_id":"4a61c9910fa747205d50d41324d603e67bff11dc","unresolved":false,"context_lines":[{"line_number":79,"context_line":"individual compute node resource provider\u0027s inventory record in the placement"},{"line_number":80,"context_line":"API without the resource tracker eventually overwriting that value the next"},{"line_number":81,"context_line":"time it runs the ``update_available_resources`` periodic task on the"},{"line_number":82,"context_line":"``nova-compute`` service."},{"line_number":83,"context_line":""},{"line_number":84,"context_line":"Use Cases"},{"line_number":85,"context_line":"---------"}],"source_content_type":"text/x-rst","patch_set":8,"id":"3f79a3b5_36292df1","line":82,"in_reply_to":"3f79a3b5_169eaa68","updated":"2018-10-19 01:26:24.000000000","message":"Sure, I will put this paragraphs before \"saga\" one.","commit_id":"591d12cda662acc0c4fb085d6dd0d83e10c73987"},{"author":{"_account_id":7166,"name":"Sylvain Bauza","email":"sbauza@redhat.com","username":"sbauza"},"change_message_id":"4d23626e59e2091640ae0b349c9318d1aff08a71","unresolved":false,"context_lines":[{"line_number":86,"context_line":""},{"line_number":87,"context_line":"An administrator would like to set allocation ratios for individual resources"},{"line_number":88,"context_line":"on a compute node via the placement API *without that value being overwritten*"},{"line_number":89,"context_line":"by the compute node\u0027s resource tracker."},{"line_number":90,"context_line":""},{"line_number":91,"context_line":"An administrator chooses to only use the configuration file to set allocation"},{"line_number":92,"context_line":"ratio overrides on their compute nodes and does not want to use the placement"}],"source_content_type":"text/x-rst","patch_set":8,"id":"3f79a3b5_f6a8ce8b","line":89,"updated":"2018-10-12 08:53:57.000000000","message":"++","commit_id":"591d12cda662acc0c4fb085d6dd0d83e10c73987"},{"author":{"_account_id":7166,"name":"Sylvain Bauza","email":"sbauza@redhat.com","username":"sbauza"},"change_message_id":"4d23626e59e2091640ae0b349c9318d1aff08a71","unresolved":false,"context_lines":[{"line_number":90,"context_line":""},{"line_number":91,"context_line":"An administrator chooses to only use the configuration file to set allocation"},{"line_number":92,"context_line":"ratio overrides on their compute nodes and does not want to use the placement"},{"line_number":93,"context_line":"API to set these ratios."},{"line_number":94,"context_line":""},{"line_number":95,"context_line":"Proposed change"},{"line_number":96,"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":8,"id":"3f79a3b5_16878a14","line":93,"updated":"2018-10-12 08:53:57.000000000","message":"++","commit_id":"591d12cda662acc0c4fb085d6dd0d83e10c73987"},{"author":{"_account_id":7166,"name":"Sylvain Bauza","email":"sbauza@redhat.com","username":"sbauza"},"change_message_id":"4d23626e59e2091640ae0b349c9318d1aff08a71","unresolved":false,"context_lines":[{"line_number":203,"context_line":"--------------"},{"line_number":204,"context_line":""},{"line_number":205,"context_line":"We need an online data migrations for any compute_nodes with existing 0.0"},{"line_number":206,"context_line":"allocation ratio."},{"line_number":207,"context_line":""},{"line_number":208,"context_line":"And clearly in order to take advantage of the ability to manually set"},{"line_number":209,"context_line":"allocation ratios on a compute node, that hypervisor would need to be upgraded."}],"source_content_type":"text/x-rst","patch_set":8,"id":"3f79a3b5_7716e65a","line":206,"updated":"2018-10-12 08:53:57.000000000","message":"You should explain what the data migration will transform into.\nI guess it would be 0.0 \u003e None.","commit_id":"591d12cda662acc0c4fb085d6dd0d83e10c73987"},{"author":{"_account_id":20722,"name":"Yikun Jiang","email":"yikunkero@gmail.com","username":"yikunkero"},"change_message_id":"4a61c9910fa747205d50d41324d603e67bff11dc","unresolved":false,"context_lines":[{"line_number":203,"context_line":"--------------"},{"line_number":204,"context_line":""},{"line_number":205,"context_line":"We need an online data migrations for any compute_nodes with existing 0.0"},{"line_number":206,"context_line":"allocation ratio."},{"line_number":207,"context_line":""},{"line_number":208,"context_line":"And clearly in order to take advantage of the ability to manually set"},{"line_number":209,"context_line":"allocation ratios on a compute node, that hypervisor would need to be upgraded."}],"source_content_type":"text/x-rst","patch_set":8,"id":"3f79a3b5_963da12a","line":206,"in_reply_to":"3f79a3b5_7716e65a","updated":"2018-10-19 01:26:24.000000000","message":"Done, and will transform from 0.0/None to ``xxx_allocation_ratio`` or ``initial_xxx_allocation_ratio``.","commit_id":"591d12cda662acc0c4fb085d6dd0d83e10c73987"},{"author":{"_account_id":7166,"name":"Sylvain Bauza","email":"sbauza@redhat.com","username":"sbauza"},"change_message_id":"4d23626e59e2091640ae0b349c9318d1aff08a71","unresolved":false,"context_lines":[{"line_number":229,"context_line":"  tracker\u0027s initial compute node creation to use these values"},{"line_number":230,"context_line":"* Remove code in the ``ComputeNode._from_db_obj()`` that changes allocation"},{"line_number":231,"context_line":"  ratio values"},{"line_number":232,"context_line":""},{"line_number":233,"context_line":"Dependencies"},{"line_number":234,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"},{"line_number":235,"context_line":""}],"source_content_type":"text/x-rst","patch_set":8,"id":"3f79a3b5_d7fc9a0e","line":232,"updated":"2018-10-12 08:53:57.000000000","message":"you also need like we said :\n- a db online migration \n- a nova-status upgrade check","commit_id":"591d12cda662acc0c4fb085d6dd0d83e10c73987"},{"author":{"_account_id":20722,"name":"Yikun Jiang","email":"yikunkero@gmail.com","username":"yikunkero"},"change_message_id":"4a61c9910fa747205d50d41324d603e67bff11dc","unresolved":false,"context_lines":[{"line_number":229,"context_line":"  tracker\u0027s initial compute node creation to use these values"},{"line_number":230,"context_line":"* Remove code in the ``ComputeNode._from_db_obj()`` that changes allocation"},{"line_number":231,"context_line":"  ratio values"},{"line_number":232,"context_line":""},{"line_number":233,"context_line":"Dependencies"},{"line_number":234,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"},{"line_number":235,"context_line":""}],"source_content_type":"text/x-rst","patch_set":8,"id":"3f79a3b5_160bd17b","line":232,"in_reply_to":"3f79a3b5_d7fc9a0e","updated":"2018-10-19 01:26:24.000000000","message":"Done","commit_id":"591d12cda662acc0c4fb085d6dd0d83e10c73987"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"2f29d62a7cffe8902357efaa76a1d9bbff3b0706","unresolved":false,"context_lines":[{"line_number":8,"context_line":"Default allocation ratio configuration"},{"line_number":9,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"},{"line_number":10,"context_line":""},{"line_number":11,"context_line":"https://blueprints.launchpad.net/nova/+spec/default-allocation-ratios"},{"line_number":12,"context_line":""},{"line_number":13,"context_line":"Provide separate CONF options for specifying the initial allocation"},{"line_number":14,"context_line":"ratio for compute nodes. Change the default values for"}],"source_content_type":"text/x-rst","patch_set":9,"id":"3f79a3b5_bb2639b9","line":11,"range":{"start_line":11,"start_character":44,"end_line":11,"end_character":51},"updated":"2018-10-17 21:46:06.000000000","message":"wrong bp name","commit_id":"6cb7eb3d8546bf63a8eb94bdbce6d2387fc4aedb"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"546d620af5f9b8e68ea61f742e791358c429e1ef","unresolved":false,"context_lines":[{"line_number":25,"context_line":"Manually set placement allocation ratios are overwritten"},{"line_number":26,"context_line":"--------------------------------------------------------------------"},{"line_number":27,"context_line":""},{"line_number":28,"context_line":"In addition to the confusing process by which the allocation ratio values are"},{"line_number":29,"context_line":"set, there is currently no way for an admin to set the allocation ratio on an"},{"line_number":30,"context_line":"individual compute node resource provider\u0027s inventory record in the placement"},{"line_number":31,"context_line":"API without the resource tracker eventually overwriting that value the next"},{"line_number":32,"context_line":"time it runs the ``update_available_resources`` periodic task on the"}],"source_content_type":"text/x-rst","patch_set":9,"id":"3f79a3b5_00881c69","line":29,"range":{"start_line":28,"start_character":0,"end_line":29,"end_character":4},"updated":"2018-10-17 21:10:27.000000000","message":"nit: this used to make sense when this section came after the details about how the allocation ratios get set, but now it\u0027s just confusing since it comes first, so just remove this sentence.","commit_id":"6cb7eb3d8546bf63a8eb94bdbce6d2387fc4aedb"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"b49f94906811a1d81d173ecd63725a1aaf65f877","unresolved":false,"context_lines":[{"line_number":25,"context_line":"Manually set placement allocation ratios are overwritten"},{"line_number":26,"context_line":"--------------------------------------------------------------------"},{"line_number":27,"context_line":""},{"line_number":28,"context_line":"In addition to the confusing process by which the allocation ratio values are"},{"line_number":29,"context_line":"set, there is currently no way for an admin to set the allocation ratio on an"},{"line_number":30,"context_line":"individual compute node resource provider\u0027s inventory record in the placement"},{"line_number":31,"context_line":"API without the resource tracker eventually overwriting that value the next"},{"line_number":32,"context_line":"time it runs the ``update_available_resources`` periodic task on the"}],"source_content_type":"text/x-rst","patch_set":9,"id":"3f79a3b5_e0e960e4","line":29,"range":{"start_line":28,"start_character":0,"end_line":29,"end_character":4},"in_reply_to":"3f79a3b5_00881c69","updated":"2018-10-17 21:40:14.000000000","message":"Done","commit_id":"6cb7eb3d8546bf63a8eb94bdbce6d2387fc4aedb"},{"author":{"_account_id":11564,"name":"Chris Dent","email":"cdent@anticdent.org","username":"chdent"},"change_message_id":"f3c60a72e57639d5a138fd5ae0054e5e01de1a2b","unresolved":false,"context_lines":[{"line_number":78,"context_line":"the new ``16.0``/``1.5``/``1.0`` values are then saved to the compute nodes"},{"line_number":79,"context_line":"table."},{"line_number":80,"context_line":""},{"line_number":81,"context_line":"There is a `fix`_ for `bug/1789654`_, which is try to don\u0027t persist"},{"line_number":82,"context_line":"zero allocation ratios in ResourceTracker to avoid to initialized placement"},{"line_number":83,"context_line":"allocation_ratio with 0.0 (due to the allocation ratio of 0.0 being multiplied"},{"line_number":84,"context_line":"by the total amount in inventory, leading to 0 resources shown on the system)."}],"source_content_type":"text/x-rst","patch_set":9,"id":"3f79a3b5_ab49368e","line":81,"range":{"start_line":81,"start_character":47,"end_line":81,"end_character":59},"updated":"2018-10-16 13:25:24.000000000","message":"trying to not","commit_id":"6cb7eb3d8546bf63a8eb94bdbce6d2387fc4aedb"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"b49f94906811a1d81d173ecd63725a1aaf65f877","unresolved":false,"context_lines":[{"line_number":78,"context_line":"the new ``16.0``/``1.5``/``1.0`` values are then saved to the compute nodes"},{"line_number":79,"context_line":"table."},{"line_number":80,"context_line":""},{"line_number":81,"context_line":"There is a `fix`_ for `bug/1789654`_, which is try to don\u0027t persist"},{"line_number":82,"context_line":"zero allocation ratios in ResourceTracker to avoid to initialized placement"},{"line_number":83,"context_line":"allocation_ratio with 0.0 (due to the allocation ratio of 0.0 being multiplied"},{"line_number":84,"context_line":"by the total amount in inventory, leading to 0 resources shown on the system)."}],"source_content_type":"text/x-rst","patch_set":9,"id":"3f79a3b5_40c6146c","line":81,"range":{"start_line":81,"start_character":47,"end_line":81,"end_character":59},"in_reply_to":"3f79a3b5_ab49368e","updated":"2018-10-17 21:40:14.000000000","message":"Done","commit_id":"6cb7eb3d8546bf63a8eb94bdbce6d2387fc4aedb"},{"author":{"_account_id":11564,"name":"Chris Dent","email":"cdent@anticdent.org","username":"chdent"},"change_message_id":"f3c60a72e57639d5a138fd5ae0054e5e01de1a2b","unresolved":false,"context_lines":[{"line_number":79,"context_line":"table."},{"line_number":80,"context_line":""},{"line_number":81,"context_line":"There is a `fix`_ for `bug/1789654`_, which is try to don\u0027t persist"},{"line_number":82,"context_line":"zero allocation ratios in ResourceTracker to avoid to initialized placement"},{"line_number":83,"context_line":"allocation_ratio with 0.0 (due to the allocation ratio of 0.0 being multiplied"},{"line_number":84,"context_line":"by the total amount in inventory, leading to 0 resources shown on the system)."},{"line_number":85,"context_line":""}],"source_content_type":"text/x-rst","patch_set":9,"id":"3f79a3b5_6b3f9ede","line":82,"range":{"start_line":82,"start_character":51,"end_line":82,"end_character":65},"updated":"2018-10-16 13:25:24.000000000","message":"initializing","commit_id":"6cb7eb3d8546bf63a8eb94bdbce6d2387fc4aedb"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"b49f94906811a1d81d173ecd63725a1aaf65f877","unresolved":false,"context_lines":[{"line_number":79,"context_line":"table."},{"line_number":80,"context_line":""},{"line_number":81,"context_line":"There is a `fix`_ for `bug/1789654`_, which is try to don\u0027t persist"},{"line_number":82,"context_line":"zero allocation ratios in ResourceTracker to avoid to initialized placement"},{"line_number":83,"context_line":"allocation_ratio with 0.0 (due to the allocation ratio of 0.0 being multiplied"},{"line_number":84,"context_line":"by the total amount in inventory, leading to 0 resources shown on the system)."},{"line_number":85,"context_line":""}],"source_content_type":"text/x-rst","patch_set":9,"id":"3f79a3b5_80b42cf3","line":82,"range":{"start_line":82,"start_character":51,"end_line":82,"end_character":65},"in_reply_to":"3f79a3b5_6b3f9ede","updated":"2018-10-17 21:40:14.000000000","message":"Done","commit_id":"6cb7eb3d8546bf63a8eb94bdbce6d2387fc4aedb"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"546d620af5f9b8e68ea61f742e791358c429e1ef","unresolved":false,"context_lines":[{"line_number":211,"context_line":"and ``None`` allocation ratio. If it\u0027s an existing record with 0.0 values, we"},{"line_number":212,"context_line":"will replace it with the configure ``xxx_allocation_ratio`` config if it\u0027s not"},{"line_number":213,"context_line":"None, and fallback to using the ``initial_xxx_allocation_ratio`` otherwise."},{"line_number":214,"context_line":""},{"line_number":215,"context_line":"And clearly in order to take advantage of the ability to manually set"},{"line_number":216,"context_line":"allocation ratios on a compute node, that hypervisor would need to be upgraded."},{"line_number":217,"context_line":"No impact to old compute hosts."}],"source_content_type":"text/x-rst","patch_set":9,"id":"3f79a3b5_00b6dc26","line":214,"updated":"2018-10-17 21:10:27.000000000","message":"Given the discussion in PS5, I think it would probably be good to note that we have to deal with exiting compute_nodes.xxx_allocation_ratio values in the database because they are used in the scheduler, specifically the NUMATopologyFilter and CPUWeigher (the core/disk/ram filters also use it, but those are deprecated so we don\u0027t really care about those).","commit_id":"6cb7eb3d8546bf63a8eb94bdbce6d2387fc4aedb"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"b49f94906811a1d81d173ecd63725a1aaf65f877","unresolved":false,"context_lines":[{"line_number":211,"context_line":"and ``None`` allocation ratio. If it\u0027s an existing record with 0.0 values, we"},{"line_number":212,"context_line":"will replace it with the configure ``xxx_allocation_ratio`` config if it\u0027s not"},{"line_number":213,"context_line":"None, and fallback to using the ``initial_xxx_allocation_ratio`` otherwise."},{"line_number":214,"context_line":""},{"line_number":215,"context_line":"And clearly in order to take advantage of the ability to manually set"},{"line_number":216,"context_line":"allocation ratios on a compute node, that hypervisor would need to be upgraded."},{"line_number":217,"context_line":"No impact to old compute hosts."}],"source_content_type":"text/x-rst","patch_set":9,"id":"3f79a3b5_607d501d","line":214,"in_reply_to":"3f79a3b5_00b6dc26","updated":"2018-10-17 21:40:14.000000000","message":"Done","commit_id":"6cb7eb3d8546bf63a8eb94bdbce6d2387fc4aedb"},{"author":{"_account_id":11564,"name":"Chris Dent","email":"cdent@anticdent.org","username":"chdent"},"change_message_id":"f3c60a72e57639d5a138fd5ae0054e5e01de1a2b","unresolved":false,"context_lines":[{"line_number":272,"context_line":"  options are all set to ``None`` and the deployer should issue calls to"},{"line_number":273,"context_line":"  ``openstack resource provider inventory class set`` or"},{"line_number":274,"context_line":"  ``openstack resource provider inventory set`` to set the allocation ratios"},{"line_number":275,"context_line":"  of their resources as needed"},{"line_number":276,"context_line":""},{"line_number":277,"context_line":"References"},{"line_number":278,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"}],"source_content_type":"text/x-rst","patch_set":9,"id":"3f79a3b5_463417df","line":275,"updated":"2018-10-16 13:25:24.000000000","message":"When we document this last point I would prefer that we indicate the deployer use the api calls, with links to the api-ref, rather than foregrounding the use of the client. The client is but one way to do it; the point of having an HTTP API is to allow many different tools. We don\u0027t want to give the deployer the impression that the openstack client is required by whatever automation they are using.\n\nOf course, we should say \"one way to do this is with openstack [blah blah]\", I simply think we need to be clear about the options.","commit_id":"6cb7eb3d8546bf63a8eb94bdbce6d2387fc4aedb"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"b49f94906811a1d81d173ecd63725a1aaf65f877","unresolved":false,"context_lines":[{"line_number":272,"context_line":"  options are all set to ``None`` and the deployer should issue calls to"},{"line_number":273,"context_line":"  ``openstack resource provider inventory class set`` or"},{"line_number":274,"context_line":"  ``openstack resource provider inventory set`` to set the allocation ratios"},{"line_number":275,"context_line":"  of their resources as needed"},{"line_number":276,"context_line":""},{"line_number":277,"context_line":"References"},{"line_number":278,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"}],"source_content_type":"text/x-rst","patch_set":9,"id":"3f79a3b5_2077583f","line":275,"in_reply_to":"3f79a3b5_463417df","updated":"2018-10-17 21:40:14.000000000","message":"Done","commit_id":"6cb7eb3d8546bf63a8eb94bdbce6d2387fc4aedb"},{"author":{"_account_id":4690,"name":"melanie witt","display_name":"melwitt","email":"melwittt@gmail.com","username":"melwitt"},"change_message_id":"699b45c149944143298bf98771427cd50966d5f7","unresolved":false,"context_lines":[{"line_number":32,"context_line":"``nova-compute`` service."},{"line_number":33,"context_line":""},{"line_number":34,"context_line":"The saga of the allocation ratio values on the compute host"},{"line_number":35,"context_line":"-----------------------------------------------------------"},{"line_number":36,"context_line":""},{"line_number":37,"context_line":"The process by which nova determines the allocation ratio for CPU, RAM and disk"},{"line_number":38,"context_line":"resources on a hypervisor is confusing and `error`_ `prone`_. The"}],"source_content_type":"text/x-rst","patch_set":10,"id":"3f79a3b5_59aa1fd3","line":35,"updated":"2018-10-23 20:14:38.000000000","message":"OMG, all so confusing. Thank you for documenting it.","commit_id":"22b389641f7ef5df4ec0ae6957cf3fddaea2f573"},{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"fd6f12c45e9124d4c8b781798677f4ed384b0f78","unresolved":false,"context_lines":[{"line_number":130,"context_line":"corresponding inventory records in the placement service. The value of these"},{"line_number":131,"context_line":"new configuration options will only be used if the compute service\u0027s resource"},{"line_number":132,"context_line":"tracker is not able to find a record in the placement service for the compute"},{"line_number":133,"context_line":"node the resource tracker is managing."},{"line_number":134,"context_line":""},{"line_number":135,"context_line":"The default value of each of these CONF options shall be ``16.0``, ``1.5``, and"},{"line_number":136,"context_line":"``1.0`` respectively. This is to match the default values for the original"}],"source_content_type":"text/x-rst","patch_set":10,"id":"3f79a3b5_c73a2c96","line":133,"updated":"2018-10-18 12:56:25.000000000","message":"Why don\u0027t we use the placement default value (1.0) in this case? \nI mean:\n\n1) if the deployer wants a global ratio then she sets *_allocation_ratio in the CONF and the resource tracker will use that towards placement.\n2) if the deployer wants to manually adjust allocation ratio in placement then she keeps *_allocation_ratio None, resource tracker does not set anything in placement so it will be 1.0 by placement default and then the deployer goes to placement and sets the value how she wants it.","commit_id":"22b389641f7ef5df4ec0ae6957cf3fddaea2f573"},{"author":{"_account_id":4690,"name":"melanie witt","display_name":"melwitt","email":"melwittt@gmail.com","username":"melwitt"},"change_message_id":"699b45c149944143298bf98771427cd50966d5f7","unresolved":false,"context_lines":[{"line_number":130,"context_line":"corresponding inventory records in the placement service. The value of these"},{"line_number":131,"context_line":"new configuration options will only be used if the compute service\u0027s resource"},{"line_number":132,"context_line":"tracker is not able to find a record in the placement service for the compute"},{"line_number":133,"context_line":"node the resource tracker is managing."},{"line_number":134,"context_line":""},{"line_number":135,"context_line":"The default value of each of these CONF options shall be ``16.0``, ``1.5``, and"},{"line_number":136,"context_line":"``1.0`` respectively. This is to match the default values for the original"}],"source_content_type":"text/x-rst","patch_set":10,"id":"3f79a3b5_d9294f3a","line":133,"in_reply_to":"3f79a3b5_c73a2c96","updated":"2018-10-23 20:14:38.000000000","message":"I think it\u0027s tricky territory to instead use the placement default (1.0) because the historical and backward compat defaults are 16.0 cpu, 1.5 ram, and 1.0 disk. Changing those to 1.0 would give users an unpleasant surprise, IMHO.\n\nSo these options will let deployers choose what they want to use as defaults, which I think would be appreciated.","commit_id":"22b389641f7ef5df4ec0ae6957cf3fddaea2f573"},{"author":{"_account_id":7166,"name":"Sylvain Bauza","email":"sbauza@redhat.com","username":"sbauza"},"change_message_id":"a8d0ede8155b90ed2b8d56f82e5cfc184f30405e","unresolved":false,"context_lines":[{"line_number":130,"context_line":"corresponding inventory records in the placement service. The value of these"},{"line_number":131,"context_line":"new configuration options will only be used if the compute service\u0027s resource"},{"line_number":132,"context_line":"tracker is not able to find a record in the placement service for the compute"},{"line_number":133,"context_line":"node the resource tracker is managing."},{"line_number":134,"context_line":""},{"line_number":135,"context_line":"The default value of each of these CONF options shall be ``16.0``, ``1.5``, and"},{"line_number":136,"context_line":"``1.0`` respectively. This is to match the default values for the original"}],"source_content_type":"text/x-rst","patch_set":10,"id":"3f79a3b5_d4bc86dc","line":133,"in_reply_to":"3f79a3b5_d9294f3a","updated":"2018-10-25 14:35:39.000000000","message":"I agree with Mel, we shouldn\u0027t change the default values for ratios, even if Placement has a separate default value.","commit_id":"22b389641f7ef5df4ec0ae6957cf3fddaea2f573"},{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"fd6f12c45e9124d4c8b781798677f4ed384b0f78","unresolved":false,"context_lines":[{"line_number":132,"context_line":"tracker is not able to find a record in the placement service for the compute"},{"line_number":133,"context_line":"node the resource tracker is managing."},{"line_number":134,"context_line":""},{"line_number":135,"context_line":"The default value of each of these CONF options shall be ``16.0``, ``1.5``, and"},{"line_number":136,"context_line":"``1.0`` respectively. This is to match the default values for the original"},{"line_number":137,"context_line":"allocation ratio CONF options before they were set to ``0.0``."},{"line_number":138,"context_line":""},{"line_number":139,"context_line":"These new ``initial_xxx_allocation_ratio`` CONF options shall **ONLY** be used"}],"source_content_type":"text/x-rst","patch_set":10,"id":"3f79a3b5_87e0b4fb","line":136,"range":{"start_line":135,"start_character":0,"end_line":136,"end_character":21},"updated":"2018-10-18 12:56:25.000000000","message":"These values are selected to keep nova backward compatible? I think the placement default 1.0 is also meaningful (but not backward compatible) default.","commit_id":"22b389641f7ef5df4ec0ae6957cf3fddaea2f573"},{"author":{"_account_id":4690,"name":"melanie witt","display_name":"melwitt","email":"melwittt@gmail.com","username":"melwitt"},"change_message_id":"699b45c149944143298bf98771427cd50966d5f7","unresolved":false,"context_lines":[{"line_number":132,"context_line":"tracker is not able to find a record in the placement service for the compute"},{"line_number":133,"context_line":"node the resource tracker is managing."},{"line_number":134,"context_line":""},{"line_number":135,"context_line":"The default value of each of these CONF options shall be ``16.0``, ``1.5``, and"},{"line_number":136,"context_line":"``1.0`` respectively. This is to match the default values for the original"},{"line_number":137,"context_line":"allocation ratio CONF options before they were set to ``0.0``."},{"line_number":138,"context_line":""},{"line_number":139,"context_line":"These new ``initial_xxx_allocation_ratio`` CONF options shall **ONLY** be used"}],"source_content_type":"text/x-rst","patch_set":10,"id":"3f79a3b5_b9d9f355","line":136,"range":{"start_line":135,"start_character":0,"end_line":136,"end_character":21},"in_reply_to":"3f79a3b5_59fef104","updated":"2018-10-23 20:14:38.000000000","message":"FWIW I think it\u0027s important to stay backward compatible here. Nova has always defaulted to some overcommit and to change it to default to zero overcommit, that\u0027s a big change and I don\u0027t know how users would respond. If we wanted to consider doing that, I think we should socialize it on the ML and at forum/ptg sessions with operators to learn more about whether the change would be welcome.","commit_id":"22b389641f7ef5df4ec0ae6957cf3fddaea2f573"},{"author":{"_account_id":20722,"name":"Yikun Jiang","email":"yikunkero@gmail.com","username":"yikunkero"},"change_message_id":"4a61c9910fa747205d50d41324d603e67bff11dc","unresolved":false,"context_lines":[{"line_number":132,"context_line":"tracker is not able to find a record in the placement service for the compute"},{"line_number":133,"context_line":"node the resource tracker is managing."},{"line_number":134,"context_line":""},{"line_number":135,"context_line":"The default value of each of these CONF options shall be ``16.0``, ``1.5``, and"},{"line_number":136,"context_line":"``1.0`` respectively. This is to match the default values for the original"},{"line_number":137,"context_line":"allocation ratio CONF options before they were set to ``0.0``."},{"line_number":138,"context_line":""},{"line_number":139,"context_line":"These new ``initial_xxx_allocation_ratio`` CONF options shall **ONLY** be used"}],"source_content_type":"text/x-rst","patch_set":10,"id":"3f79a3b5_59fef104","line":136,"range":{"start_line":135,"start_character":0,"end_line":136,"end_character":21},"in_reply_to":"3f79a3b5_87e0b4fb","updated":"2018-10-19 01:26:24.000000000","message":"Yeah, I think these values are selected to keep compatible.","commit_id":"22b389641f7ef5df4ec0ae6957cf3fddaea2f573"},{"author":{"_account_id":11604,"name":"sean mooney","email":"smooney@redhat.com","username":"sean-k-mooney"},"change_message_id":"6eaba76ae85f909bc068ac3ea45e8a3e52c02fff","unresolved":false,"context_lines":[{"line_number":132,"context_line":"tracker is not able to find a record in the placement service for the compute"},{"line_number":133,"context_line":"node the resource tracker is managing."},{"line_number":134,"context_line":""},{"line_number":135,"context_line":"The default value of each of these CONF options shall be ``16.0``, ``1.5``, and"},{"line_number":136,"context_line":"``1.0`` respectively. This is to match the default values for the original"},{"line_number":137,"context_line":"allocation ratio CONF options before they were set to ``0.0``."},{"line_number":138,"context_line":""},{"line_number":139,"context_line":"These new ``initial_xxx_allocation_ratio`` CONF options shall **ONLY** be used"}],"source_content_type":"text/x-rst","patch_set":10,"id":"3f79a3b5_f9376bae","line":136,"range":{"start_line":135,"start_character":0,"end_line":136,"end_character":21},"in_reply_to":"3f79a3b5_87e0b4fb","updated":"2018-10-23 19:59:44.000000000","message":"backward compatiblity is a failly stong argument but other then cpus i actully consider it a bug to over subsibe memory or disk.\n\nsure you can make it work in some limited cases but its almost always a bad idea for memroy or disk to be set to anything over 1.0\n\nwith that said these are the values people expect when you dont set anything at all so we likely should not change it.","commit_id":"22b389641f7ef5df4ec0ae6957cf3fddaea2f573"},{"author":{"_account_id":7166,"name":"Sylvain Bauza","email":"sbauza@redhat.com","username":"sbauza"},"change_message_id":"a8d0ede8155b90ed2b8d56f82e5cfc184f30405e","unresolved":false,"context_lines":[{"line_number":132,"context_line":"tracker is not able to find a record in the placement service for the compute"},{"line_number":133,"context_line":"node the resource tracker is managing."},{"line_number":134,"context_line":""},{"line_number":135,"context_line":"The default value of each of these CONF options shall be ``16.0``, ``1.5``, and"},{"line_number":136,"context_line":"``1.0`` respectively. This is to match the default values for the original"},{"line_number":137,"context_line":"allocation ratio CONF options before they were set to ``0.0``."},{"line_number":138,"context_line":""},{"line_number":139,"context_line":"These new ``initial_xxx_allocation_ratio`` CONF options shall **ONLY** be used"}],"source_content_type":"text/x-rst","patch_set":10,"id":"3f79a3b5_14be7ecd","line":136,"range":{"start_line":135,"start_character":0,"end_line":136,"end_character":21},"in_reply_to":"3f79a3b5_b9d9f355","updated":"2018-10-25 14:35:39.000000000","message":"Again, +1 to Mel\u0027s point, please don\u0027t change the existing default behaviour here.","commit_id":"22b389641f7ef5df4ec0ae6957cf3fddaea2f573"},{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"fd6f12c45e9124d4c8b781798677f4ed384b0f78","unresolved":false,"context_lines":[{"line_number":145,"context_line":"read from the DB if the values are ``0.0`` or ``None``. If it\u0027s an existing"},{"line_number":146,"context_line":"record with 0.0 values, we\u0027d want to do what the compute does, which is use"},{"line_number":147,"context_line":"the configure ``xxx_allocation_ratio`` config if it\u0027s not None, and fallback"},{"line_number":148,"context_line":"to using the ``initial_xxx_allocation_ratio`` otherwise."},{"line_number":149,"context_line":""},{"line_number":150,"context_line":"And add an online data migration that updates all compute_nodes"},{"line_number":151,"context_line":"table records that have ``0.0`` or ``None`` allocation ratios. Then we drop"}],"source_content_type":"text/x-rst","patch_set":10,"id":"3f79a3b5_27a0c0a4","line":148,"range":{"start_line":148,"start_character":46,"end_line":148,"end_character":55},"updated":"2018-10-18 12:56:25.000000000","message":"Do you mean when the db contains allocation_ratio\u003dNone OR the db does not contain compute record? Can any of these happen?","commit_id":"22b389641f7ef5df4ec0ae6957cf3fddaea2f573"},{"author":{"_account_id":20722,"name":"Yikun Jiang","email":"yikunkero@gmail.com","username":"yikunkero"},"change_message_id":"4a61c9910fa747205d50d41324d603e67bff11dc","unresolved":false,"context_lines":[{"line_number":145,"context_line":"read from the DB if the values are ``0.0`` or ``None``. If it\u0027s an existing"},{"line_number":146,"context_line":"record with 0.0 values, we\u0027d want to do what the compute does, which is use"},{"line_number":147,"context_line":"the configure ``xxx_allocation_ratio`` config if it\u0027s not None, and fallback"},{"line_number":148,"context_line":"to using the ``initial_xxx_allocation_ratio`` otherwise."},{"line_number":149,"context_line":""},{"line_number":150,"context_line":"And add an online data migration that updates all compute_nodes"},{"line_number":151,"context_line":"table records that have ``0.0`` or ``None`` allocation ratios. Then we drop"}],"source_content_type":"text/x-rst","patch_set":10,"id":"3f79a3b5_fe3fa3dc","line":148,"range":{"start_line":148,"start_character":46,"end_line":148,"end_character":55},"in_reply_to":"3f79a3b5_27a0c0a4","updated":"2018-10-19 01:26:24.000000000","message":"It means: When db value is None or 0.0, if xxx_allocation_ratio it\u0027s None, we will set ratio to initial_xxx_allocation_ratio.","commit_id":"22b389641f7ef5df4ec0ae6957cf3fddaea2f573"},{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"fd6f12c45e9124d4c8b781798677f4ed384b0f78","unresolved":false,"context_lines":[{"line_number":148,"context_line":"to using the ``initial_xxx_allocation_ratio`` otherwise."},{"line_number":149,"context_line":""},{"line_number":150,"context_line":"And add an online data migration that updates all compute_nodes"},{"line_number":151,"context_line":"table records that have ``0.0`` or ``None`` allocation ratios. Then we drop"},{"line_number":152,"context_line":"that at some point with a blocker migration and remove the code in the"},{"line_number":153,"context_line":"``nova.objects.ComputeNode._from_db_obj`` that adjusts allocation ratios."},{"line_number":154,"context_line":""}],"source_content_type":"text/x-rst","patch_set":10,"id":"3f79a3b5_0784a40d","line":151,"range":{"start_line":151,"start_character":35,"end_line":151,"end_character":43},"updated":"2018-10-18 12:56:25.000000000","message":"How can that happen?","commit_id":"22b389641f7ef5df4ec0ae6957cf3fddaea2f573"},{"author":{"_account_id":20722,"name":"Yikun Jiang","email":"yikunkero@gmail.com","username":"yikunkero"},"change_message_id":"4a61c9910fa747205d50d41324d603e67bff11dc","unresolved":false,"context_lines":[{"line_number":148,"context_line":"to using the ``initial_xxx_allocation_ratio`` otherwise."},{"line_number":149,"context_line":""},{"line_number":150,"context_line":"And add an online data migration that updates all compute_nodes"},{"line_number":151,"context_line":"table records that have ``0.0`` or ``None`` allocation ratios. Then we drop"},{"line_number":152,"context_line":"that at some point with a blocker migration and remove the code in the"},{"line_number":153,"context_line":"``nova.objects.ComputeNode._from_db_obj`` that adjusts allocation ratios."},{"line_number":154,"context_line":""}],"source_content_type":"text/x-rst","patch_set":10,"id":"3f79a3b5_3e5d1b54","line":151,"range":{"start_line":151,"start_character":35,"end_line":151,"end_character":43},"in_reply_to":"3f79a3b5_0784a40d","updated":"2018-10-19 01:26:24.000000000","message":"The allocation ratio default value is None [1], if the allocation ratio is not set (Default is 0.0 [2]), and the 0.0 would not be set in [3].\n\nSo, ratio keeps None value in this case.\n\n[1] https://github.com/openstack/nova/blob/01c33c5/nova/db/sqlalchemy/models.py#L180-L182\n[2] https://github.com/openstack/nova/blob/852de1e/nova/conf/compute.py#L400\n[3] https://github.com/openstack/nova/blob/6a68f9140/nova/compute/resource_tracker.py#L621-L645","commit_id":"22b389641f7ef5df4ec0ae6957cf3fddaea2f573"},{"author":{"_account_id":4690,"name":"melanie witt","display_name":"melwitt","email":"melwittt@gmail.com","username":"melwitt"},"change_message_id":"699b45c149944143298bf98771427cd50966d5f7","unresolved":false,"context_lines":[{"line_number":216,"context_line":"   records is what gets used in the scheduler [1]_, specifically the"},{"line_number":217,"context_line":"   ``NUMATopologyFilter`` and ``CPUWeigher`` (the ``CoreFilter``,"},{"line_number":218,"context_line":"   ``DiskFilter`` and ``RamFilter`` also use them but those filters are"},{"line_number":219,"context_line":"   deprecated for removal so they are not a concern here)."},{"line_number":220,"context_line":""},{"line_number":221,"context_line":"And clearly in order to take advantage of the ability to manually set"},{"line_number":222,"context_line":"allocation ratios on a compute node, that hypervisor would need to be upgraded."}],"source_content_type":"text/x-rst","patch_set":10,"id":"3f79a3b5_19c10750","line":219,"updated":"2018-10-23 20:14:38.000000000","message":"++ useful note","commit_id":"22b389641f7ef5df4ec0ae6957cf3fddaea2f573"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"92901c9895e6b9f19316b8e3c329b431cc716862","unresolved":false,"context_lines":[{"line_number":282,"context_line":"  ratios of their resources as needed (or use the related ``osc-placement``"},{"line_number":283,"context_line":"  plugin commands [4]_)."},{"line_number":284,"context_line":""},{"line_number":285,"context_line":"References"},{"line_number":286,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"},{"line_number":287,"context_line":""},{"line_number":288,"context_line":".. [1] https://github.com/openstack/nova/blob/a534ccc5a7/nova/scheduler/host_manager.py#L255"}],"source_content_type":"text/x-rst","patch_set":10,"id":"3f79a3b5_e93f6f20","line":285,"updated":"2018-10-25 14:10:52.000000000","message":"Recently reported bug 1799727 is also a regression due to how config is used and the update_provider_tree() interface in the resource tracker. We could link that in here as a reference if we want (in a follow up).","commit_id":"22b389641f7ef5df4ec0ae6957cf3fddaea2f573"},{"author":{"_account_id":7166,"name":"Sylvain Bauza","email":"sbauza@redhat.com","username":"sbauza"},"change_message_id":"a8d0ede8155b90ed2b8d56f82e5cfc184f30405e","unresolved":false,"context_lines":[{"line_number":282,"context_line":"  ratios of their resources as needed (or use the related ``osc-placement``"},{"line_number":283,"context_line":"  plugin commands [4]_)."},{"line_number":284,"context_line":""},{"line_number":285,"context_line":"References"},{"line_number":286,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"},{"line_number":287,"context_line":""},{"line_number":288,"context_line":".. [1] https://github.com/openstack/nova/blob/a534ccc5a7/nova/scheduler/host_manager.py#L255"}],"source_content_type":"text/x-rst","patch_set":10,"id":"3f79a3b5_d4a1e6a9","line":285,"in_reply_to":"3f79a3b5_e93f6f20","updated":"2018-10-25 14:35:39.000000000","message":"Sure, let\u0027s do this as a follow-up.","commit_id":"22b389641f7ef5df4ec0ae6957cf3fddaea2f573"}]}
