-
Notifications
You must be signed in to change notification settings - Fork 26
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
"ERROR: more units requested" when --hyperconverged is used for OpenStack #293
Comments
@marino-mrc that message is printed when the bundle being deployed does not have enough physical machines to accommodate 3 units of a charm. This is because the default value of num computes is 1. A simple way to fix this would be to default to 3 computes if the deployments is hyperconverged. What do you think? |
Hyperconvereged mode needs at least 3 phyiscal machines to deploy so that applications with min 3 units have somewhere to go. Resolves: canonical#293
@dosaboy I think your solution doesn't work because even with 3 compute nodes, we still have an insufficient number of units. I mean, the script could work, but incompatible services will be placed on the same units. Some assumptions should be made for the controller (I'm trying to align with what I think was the initial idea when --hyperconverged is used in the stsstack-bundles project):
Under the previous assumptions, the minimum number of units is 7 and 3 of them MUST support LXD containers (I'm assuming --hyperconverged and --ml2-ovs):
If you agree with my vision, the following pseudo-code works (only if you use --hyperconverged and --ml2-ovs): #define a static value for the number of controller units
num_controller_units = 3 # We have 3 machines, and on top of them many LXD containers
num_neutron_gateway_units = 1 # We don't need this in the code. It's defined in openstack/pipeline/02configure. This line is just for clarity
# Check if the number of compute units has been defined, and use the appropriate number of num_ceph_osd_units
if num_compute_units < 3
num_ceph_osd_units = 3
else
num_ceph_osd_units = num_compute_units
end
num_placement_machines = num_controller_units + num_ceph_osd_units + num_neutron_gateway_units I tried to set the value to 7 and the script works without any error. EDIT: The previous pseudo-code should be added in substitution of line 182 |
So, the placement of the units is something that you can change to suite your needs by modifying the unit_placement.yaml file. After you make changes to that file you need to use the |
@dosaboy It works for me. Based on your suggestion, the current workaround is to simply pass --num-compute 3 to the CLI: ./generate-bundle.sh -r ussuri -s focal --ceph --ml2-ovs --default-binding oam --hyperconverged --num-compute 3 -n teststs Just tested and it works. This should be summarized by saying that if --hyperconverged is used, --num-compute is forced to 3. Thanks! |
Hello,
I'm trying to run the script with the --hyperconverged flag and I'm getting the following error:
$ ./generate-bundle.sh -r ussuri -s focal --ceph --ml2-ovs --default-binding oam --hyperconverged -n teststs Juju model 'teststs' already exists and is the current context - skipping create Created focal-ussuri bundle and overlays: + openstack/glance.yaml + openstack/keystone.yaml + openstack/neutron-gateway.yaml + openstack/neutron-openvswitch.yaml + openstack/rabbitmq-source.yaml + ceph/ceph.yaml + openstack/openstack-ceph.yaml + openstack/neutron-ml2dns.yaml + openstack/neutron-ml2dns-gateway.yaml + openstack/neutron-ml2dns-openvswitch.yaml + mysql-innodb-cluster.yaml + mysql-innodb-cluster-router.yaml + openstack/placement.yaml ERROR: more units requested (3) that machines available (2) (template=mysql.yaml) - hint: add more compute nodes/units
I think the problem is in common/generate_bundle_base when ${num_placement_machines} is calculated.
Actually, we have the following:
num_placement_machines=$((${MOD_PARAMS[__NUM_NEUTRON_GATEWAY_UNITS__]} + ${MOD_PARAMS[__NUM_COMPUTE_UNITS__]}))
But this is conceptually wrong because it doesn't consider the number of controller units (I'm assuming 3 because a MySQL cluster is the default) and miscalculates the minimum number of ceph-osd units (think about the case where the number of compute units is less than 3. We still need at least 3 ceph-osd units).
Assuming that we want to use hyper-convergency for storage and compute, we should have the following pseudo-code:
Also, I tried to work around the code using a fixed value and I noticed that compute and ceph-osd units are misplaced (LXD containers of the control plane are started on top of compute units)
Regards,
Marco
The text was updated successfully, but these errors were encountered: