Hide Forgot
Description of problem: The stack would fail if using the suffix "_" with stack name. Version-Release number of selected component (if applicable): v0.9.2 How reproducible: always Steps to Reproduce: 1.Create a stack which named to the suffix "_". E.g: ghuang-test_15 heat stack-create ghuang-test_15 -t 10800 -e ocp.yaml -f /usr/share/openshift-on-openstack/openshift.yaml 2. 3. Actual results: Stack was failed due to service "named" can't be started on bastion host. -- Unit named.service has begun starting up. Oct 17 00:48:10 ghuang-test_15-bastion.example.com bash[12544]: dns_rdata_fromtext: openshift-cluster.zone:2: near 'ghuang-test_15-bastion': bad name (check-names) Oct 17 00:48:10 ghuang-test_15-bastion.example.com bash[12544]: dns_rdata_fromtext: openshift-cluster.zone:10: near 'ghuang-test_15-bastion': bad name (check-names) Oct 17 00:48:10 ghuang-test_15-bastion.example.com bash[12544]: openshift-cluster.zone:11: ghuang-test_15-bastion.example.com: bad owner name (check-names) Oct 17 00:48:10 ghuang-test_15-bastion.example.com bash[12544]: openshift-cluster.zone:12: ghuang-test_15-openshift-master-0.example.com: bad owner name (check-names) Oct 17 00:48:10 ghuang-test_15-bastion.example.com bash[12544]: openshift-cluster.zone:13: ghuang-test_15-openshift-master-1.example.com: bad owner name (check-names) Oct 17 00:48:10 ghuang-test_15-bastion.example.com bash[12544]: openshift-cluster.zone:14: ghuang-test_15-openshift-master-2.example.com: bad owner name (check-names) Oct 17 00:48:10 ghuang-test_15-bastion.example.com bash[12544]: openshift-cluster.zone:15: ghuang-test_15-openshift-infra-0.example.com: bad owner name (check-names) Oct 17 00:48:10 ghuang-test_15-bastion.example.com bash[12544]: openshift-cluster.zone:16: ghuang-test_15-openshift-infra-1.example.com: bad owner name (check-names) Oct 17 00:48:10 ghuang-test_15-bastion.example.com bash[12544]: openshift-cluster.zone:17: ghuang-test_15-openshift-node-rux9f429.example.com: bad owner name (check-names) Oct 17 00:48:10 ghuang-test_15-bastion.example.com bash[12544]: openshift-cluster.zone:18: ghuang-test_15-openshift-node-6b76p1f9.example.com: bad owner name (check-names) Oct 17 00:48:10 ghuang-test_15-bastion.example.com bash[12544]: openshift-cluster.zone:19: ghuang-test_15-lb.example.com: bad owner name (check-names) Oct 17 00:48:10 ghuang-test_15-bastion.example.com bash[12544]: zone example.com/IN: loading from master file openshift-cluster.zone failed: bad name (check-names) Oct 17 00:48:10 ghuang-test_15-bastion.example.com bash[12544]: zone example.com/IN: not loaded due to errors. Oct 17 00:48:10 ghuang-test_15-bastion.example.com bash[12544]: _default/example.com/IN: bad name (check-names) Oct 17 00:48:10 ghuang-test_15-bastion.example.com systemd[1]: named.service: control process exited, code=exited status=1 Oct 17 00:48:10 ghuang-test_15-bastion.example.com systemd[1]: Failed to start Berkeley Internet Name Domain (DNS). Expected results: Stack can be created successfully if the stack name includes the suffix "_" Additional info: http://ben.goodacre.name/tech/Bad_owner_name_%28check-names%29_Error_%28BIND%29
stackname is used as part of instance hostnames, '_' is not a valid hostname character. We can add a heat stack validation constraint to check for '[a-z0-9-]' characters only.
Fixed in PR: https://github.com/redhat-openstack/openshift-on-openstack/pull/283
Waiting for v0.9.4 which should include this fix.
Fixed in 0.9.4 (sorry for confusion, it was switched from MODIFIED to ON_QA automatically)
Verified with 0.9.4 1. Stack name with "_" $ heat stack-create ghuang-auto_1 -t 10800 -e ocp.yaml -f /usr/share/openshift-on-openstack/openshift.yaml ERROR: Property error: : resources.bastion_host.properties.hostname: : Hostname must contain only characters [a-z0-9\-]. 2. lb_hostname with "_" $ heat stack-create ghuang-test1 -t 10800 -e ocp.yaml -f /usr/share/openshift-on-openstack/openshift.yaml ERROR: Property error: : resources.loadbalancer.properties.hostname: : Hostname must contain only characters [a-z0-9\-].