Bugzilla will be upgraded to version 5.0. The upgrade date is tentatively scheduled for 2 December 2018, pending final testing and feedback.
Bug 876644 - oo-register-dns is hardcoded to add entries to a BIND server at 127.0.0.1
oo-register-dns is hardcoded to add entries to a BIND server at 127.0.0.1
Status: CLOSED ERRATA
Product: OpenShift Container Platform
Classification: Red Hat
Component: Pod (Show other bugs)
1.2.0
Unspecified Linux
low Severity low
: ---
: ---
Assigned To: Brenton Leanhardt
libra bugs
: Triaged
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2012-11-14 11:28 EST by Javier Peña
Modified: 2017-03-08 12 EST (History)
4 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2013-01-31 15:32:47 EST
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)


External Trackers
Tracker ID Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2013:0220 normal SHIPPED_LIVE Important: Red Hat OpenShift Enterprise 1.1 update 2013-01-31 20:23:24 EST

  None (edit)
Description Javier Peña 2012-11-14 11:28:12 EST
Description of problem:
oo-register-dns will only work when the BIND server is running on the same host as the broker node. Checking the source, it contains the following:

<snip>
command =<<-EOF
server 127.0.0.1
update delete #{node_hostname}.#{node_domain} A
update add #{node_hostname}.#{node_domain} 180 A #{ip}
send
EOF

system "nsupdate -k #{key} <<EOF\n#{command}\nEOF"

There is no configurable option for an external BIND server.


Version-Release number of selected component (if applicable):
Checked on the public mirror from 2012-10-31

How reproducible:
Always

Steps to Reproduce:
1. Setup OpenShift broker using an external DNS service
2. Run oo-register-dns --with-node-hostname node1  --with-node-ip 192.168.0.1 --domain example.com 
3.
  
Actual results:
The DNS entry add will fail.

Expected results:
The command should read the DNS server from /etc/openshift/plugins.d/openshift-origin-dns-bind.conf or have a command-line option to set it.


Additional info:
Comment 1 Luke Meyer 2012-11-14 14:58:36 EST
Ugh. Thanks for pointing this out.

It should be really easy to generalize this.
1. At minimum, allow specifying server and key.
2. Better, pick those up from the plugin settings.
3. Best, use the plugin itself (whichever is configured) to make the update.
Comment 2 John Keck 2012-11-15 12:42:15 EST
Scheduling for dot release.
Comment 5 Brenton Leanhardt 2012-12-11 13:39:15 EST
The upstream pull request is here:
https://github.com/openshift/origin-server/pull/1057

This will ship with the next puddle.
Comment 6 xjia 2012-12-12 04:49:43 EST
Verify:

[root@xjia-client 1212]# ssh 10.4.59.150
root@10.4.59.150's password: 
Last login: Wed Dec 12 04:43:12 2012 from vm-188-59-4-10.ose.phx2.redhat.com
[root@broker ~]# ps aux | grep named
root      2289  0.0  0.0 103244   812 pts/0    S+   04:45   0:00 grep named
[root@broker ~]# oo-register-dns -n 10.4.59.176 -h node123 -d example.com -k /var/named/example.com.key  -s 10.4.59.174
[root@broker ~]# dig @10.4.59.174 node123.example.com

; <<>> DiG 9.8.2rc1-RedHat-9.8.2-0.10.rc1.el6_3.6 <<>> @10.4.59.174 node123.example.com
; (1 server found)
;; global options: +cmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 9667
;; flags: qr aa rd ra; QUERY: 1, ANSWER: 1, AUTHORITY: 1, ADDITIONAL: 1

;; QUESTION SECTION:
;node123.example.com.		IN	A

;; ANSWER SECTION:
node123.example.com.	180	IN	A	10.4.59.176

;; AUTHORITY SECTION:
example.com.		1	IN	NS	ns1.example.com.

;; ADDITIONAL SECTION:
ns1.example.com.	1	IN	A	127.0.0.1

;; Query time: 1 msec
;; SERVER: 10.4.59.174#53(10.4.59.174)
;; WHEN: Wed Dec 12 04:46:40 2012
;; MSG SIZE  rcvd: 87

[root@broker ~]# nslookup node123.example.com
Server:		10.4.59.174
Address:	10.4.59.174#53

Name:	node123.example.com
Address: 10.4.59.176

[root@broker ~]# 


Version:
OpenShiftEnterprise/1.1.x/2012-12-11.3/
Comment 8 errata-xmlrpc 2013-01-31 15:32:47 EST
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

http://rhn.redhat.com/errata/RHSA-2013-0220.html

Note You need to log in before you can comment on or make changes to this bug.