Description of problem:
When deploying more than 10 compute nodes with custom hostnames, nodes with an index >=10 have an incorrect hostname, like below:
In scheduler_hints_env.yaml:
overcloud-novacompute-10: osrtpz11011
overcloud-novacompute-11: osrtpz11012
overcloud-novacompute-12: osrtpz11013
However when the nodes are created they get assigned:
overcloud-novacompute-10: osrtpz110021
overcloud-novacompute-11: osrtpz110022
overcloud-novacompute-12: osrtpz110023
$ cat scheduler_hints_env.yaml
parameter_defaults:
ControllerSchedulerHints:
'capabilities:node': 'controller-%index%'
NovaComputeSchedulerHints:
'capabilities:node': 'novacompute-%index%'
HostnameMap:
overcloud-controller-0: oscntrtpz101
overcloud-controller-1: oscntrtpz102
overcloud-controller-2: oscntrtpz103
overcloud-novacompute-0: osrtpz11001
overcloud-novacompute-1: osrtpz11002
overcloud-novacompute-2: osrtpz11003
overcloud-novacompute-3: osrtpz11004
overcloud-novacompute-4: osrtpz11005
overcloud-novacompute-5: osrtpz11006
overcloud-novacompute-6: osrtpz11007
overcloud-novacompute-7: osrtpz11008
overcloud-novacompute-8: osrtpz11009
overcloud-novacompute-9: osrtpz11010
overcloud-novacompute-10: osrtpz11011
overcloud-novacompute-11: osrtpz11012
overcloud-novacompute-12: osrtpz11013
overcloud-novacompute-13: osrtpz11014
Version-Release number of selected component (if applicable):
How reproducible:
Every time, seen in 2 separate deployments
Steps to Reproduce:
1. Configure templates and deployment command for >10 compute nodes
2. Set custom hostnames such as above
3. Deploy the overcloud
Actual results:
Compute nodes index >10 are assigned an incorrect hostname
Expected results:
Nodes are assigned the correct hostnames
Additional info:
This feature appears to have been added upstream in this commit: https://review.openstack.org/gitweb?p=openstack/tripleo-heat-templates.git;a=commitdiff;h=3c1850b780c3841ffcab1e35f81be623f0000e37
From the customer case, this theory:
It looks like tripleo is taking the name from novacompute-1 and just appending 1, 2, 3 to the end:
overcloud-novacompute-1: osrtpz21002
From Dimitri Savineau:
https://bugzilla.redhat.com/show_bug.cgi?id=1353920https://bugs.launchpad.net/tripleo/+bug/1600209
I'm going to mark as a duplicate of bug #1353920
shardy has a suggested workaround in that bug:
"
A workaround for this is probably to add a trailing character to the HostnameFormat parameter, e.g:
parameter_defaults:
ComputeHostnameFormat: '%stackname%-novacompute-%index%X'
HostnameMap:
overcloud-controller-0X: foo-a123-n1
overcloud-controller-1X: foo-a123-n2
...
overcloud-compute-12X: foo-b123-n13
"
*** This bug has been marked as a duplicate of bug 1353920 ***
Description of problem: When deploying more than 10 compute nodes with custom hostnames, nodes with an index >=10 have an incorrect hostname, like below: In scheduler_hints_env.yaml: overcloud-novacompute-10: osrtpz11011 overcloud-novacompute-11: osrtpz11012 overcloud-novacompute-12: osrtpz11013 However when the nodes are created they get assigned: overcloud-novacompute-10: osrtpz110021 overcloud-novacompute-11: osrtpz110022 overcloud-novacompute-12: osrtpz110023 $ cat scheduler_hints_env.yaml parameter_defaults: ControllerSchedulerHints: 'capabilities:node': 'controller-%index%' NovaComputeSchedulerHints: 'capabilities:node': 'novacompute-%index%' HostnameMap: overcloud-controller-0: oscntrtpz101 overcloud-controller-1: oscntrtpz102 overcloud-controller-2: oscntrtpz103 overcloud-novacompute-0: osrtpz11001 overcloud-novacompute-1: osrtpz11002 overcloud-novacompute-2: osrtpz11003 overcloud-novacompute-3: osrtpz11004 overcloud-novacompute-4: osrtpz11005 overcloud-novacompute-5: osrtpz11006 overcloud-novacompute-6: osrtpz11007 overcloud-novacompute-7: osrtpz11008 overcloud-novacompute-8: osrtpz11009 overcloud-novacompute-9: osrtpz11010 overcloud-novacompute-10: osrtpz11011 overcloud-novacompute-11: osrtpz11012 overcloud-novacompute-12: osrtpz11013 overcloud-novacompute-13: osrtpz11014 Version-Release number of selected component (if applicable): How reproducible: Every time, seen in 2 separate deployments Steps to Reproduce: 1. Configure templates and deployment command for >10 compute nodes 2. Set custom hostnames such as above 3. Deploy the overcloud Actual results: Compute nodes index >10 are assigned an incorrect hostname Expected results: Nodes are assigned the correct hostnames Additional info: This feature appears to have been added upstream in this commit: https://review.openstack.org/gitweb?p=openstack/tripleo-heat-templates.git;a=commitdiff;h=3c1850b780c3841ffcab1e35f81be623f0000e37