Inproper configuration of DNS in kolla-ansible
Affects | Status | Importance | Assigned to | Milestone | ||
---|---|---|---|---|---|---|
kolla-ansible | Status tracked in Caracal | |||||
Antelope |
Fix Committed
|
Undecided
|
Unassigned | |||
Bobcat |
Fix Committed
|
Undecided
|
Unassigned | |||
Caracal |
Fix Released
|
Undecided
|
Michal Arbet | |||
Zed |
Fix Committed
|
Undecided
|
Unassigned |
Bug Description
Hi,
In kolla-ansible we are configuring DNS in bad way, we are not settings dns_domain in neutron which is REQUIRED for both internal/external DNS configuration ...
I suggest adding a user switch that will tell whether DNS is turned on or not + precheck that will check the dns_domain setup for neutron ..and write tests for designate..
Check logs below :
BUGGY >>>>>
root@controller0:~# cat /etc/kolla/
external_dns_driver = designate
dns_domain = openstacklocal
root@deploy:
{
"dns_domain": "public.
"id": "d2fa31a9-
"name": "public-network-1"
}
root@deploy:
{
"dns_
"id": "128aaa74-
"name": "public-subnet-1",
"network_id": "d2fa31a9-
}
(kolla-
+------
| ID | Name | MAC Address | Fixed IP Addresses | Status |
+------
| b024c8c8-
| fa86d086-
+------
DNSmasq - fqdns created with openstacklocal. which is default and kolla don't set
(neutron-
fa:16:3e:
fa:16:3e:
root@deploy:
+------
| id | name | type | serial | status | action |
+------
| 778823c7-
| 4fd09ee4-
+------
Records in zone :
root@deploy:
+------
| id | name | type | records | status | action |
+------
| f4e03a03-
| cf879a02-
+------
Create server (DNS record creation should be automatic)
root@deploy:
+------
| Field | Value |
+------
| OS-DCF:diskConfig | MANUAL |
| OS-EXT-
| OS-EXT-
| OS-EXT-
| OS-EXT-STS:vm_state | building |
| OS-SRV-
| OS-SRV-
| accessIPv4 | |
| accessIPv6 | |
| addresses | |
| adminPass | 8H7S9d6Qtau6 |
| config_drive | |
| created | 2024-01-
| flavor | m1.tiny (1) |
| hostId | |
| id | 81ab249b-
| image | cirros (3f738cfd-
| key_name | None |
| name | kevko-test |
| progress | 0 |
| project_id | df3687b4123b46a
| properties | |
| security_groups | name='default' |
| status | BUILD |
| updated | 2024-01-
| user_id | 3f0eb0e10d3a442
| volumes_attached | |
+------
DNS record not created :
root@deploy:
+------
| id | name | type | records | status | action |
+------
| f4e03a03-
| cf879a02-
+------
DNSmasq :
(neutron-
fa:16:3e:
fa:16:3e:
fa:16:3e:
FIXED >>>>
So, designate integration not working in kolla out of the box. As per designate documentation there is need to sed dns_domain in neutron to designate integration start to WORK !
Let's reconfigure dns_domain in neutron services because it need to be different as it is in default
kolla-ansible -i /etc/kolla/
.
.
.
.
--- before: /etc/kolla/
+++ after: /root/.
@@ -18,7 +18,7 @@
transport_url = rabbit:
external_
ipam_driver = internal
-dns_domain = openstacklocal
+dns_domain = openstack.local.
Soooo , DNSmasq regenerated :
(neutron-
fa:16:3e:
fa:16:3e:
fa:16:3e:
Let's remove old server we created before as this setup didn't work:
openstack server delete 81ab249b-
And create new one when it's finally working as it could :
openstack server create --flavor 1 --image 3f738cfd-
(kolla-
+------
| Field | Value |
+------
| OS-DCF:diskConfig | MANUAL |
| OS-EXT-
| OS-EXT-
| OS-EXT-
| OS-EXT-STS:vm_state | building |
| OS-SRV-
| OS-SRV-
| accessIPv4 | |
| accessIPv6 | |
| addresses | |
| adminPass | yDCYD3Ggqge6 |
| config_drive | |
| created | 2024-01-
| flavor | m1.tiny (1) |
| hostId | |
| id | 778490cf-
| image | cirros (3f738cfd-
| key_name | None |
| name | kevko-test-
| progress | 0 |
| project_id | df3687b4123b46a
| properties | |
| security_groups | name='default' |
| status | BUILD |
| updated | 2024-01-
| user_id | 3f0eb0e10d3a442
| volumes_attached | |
+------
(kolla-
+------
| id | name | type | records | status | action |
+------
| f4e03a03-
| cf879a02-
| 37a4ff07-
+------
DNSmasq also fixed
(neutron-
fa:16:3e:
fa:16:3e:
fa:16:3e:
External DNS also ok :
root@controller0:~# dig kevko-test-
; <<>> DiG 9.18.12-
;; global options: +cmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 27840
;; flags: qr aa rd; QUERY: 1, ANSWER: 1, AUTHORITY: 0, ADDITIONAL: 1
;; WARNING: recursion requested but not available
;; OPT PSEUDOSECTION:
; EDNS: version: 0, flags:; udp: 1232
; COOKIE: 305a750bd4d29d3
;; QUESTION SECTION:
;kevko-
;; ANSWER SECTION:
kevko-test-
;; Query time: 0 msec
;; SERVER: 192.168.
;; WHEN: Tue Jan 16 11:11:21 UTC 2024
;; MSG SIZE rcvd: 121
Everything working like a charm :
(kolla-
(kolla-
+------
| id | name | type | records | status | action |
+------
| f4e03a03-
| cf879a02-
+------
Changed in kolla-ansible: | |
assignee: | nobody → Michal Arbet (michalarbet) |
Changed in kolla-ansible: | |
status: | New → In Progress |
Designate documentation where it is specified that it's requirement for both internal/external DNS setup
https:/ /docs.openstack .org/neutron/ latest/ admin/config- dns-int. html
INTERNAL :
"Edit the /etc/neutron/ neutron. conf file and assign a value different to openstacklocal (its default value) to the dns_domain parameter in the [default] section. As an example:
"
EXTERNAL :
The enablement of this functionality is prerequisite for the enablement of the Networking service integration with an external DNS service, which is described in detail in DNS Integration with an External Service.