summaryrefslogtreecommitdiffstats
path: root/install/tools/ipa-dns-install
diff options
context:
space:
mode:
authorMartin Kosek <mkosek@redhat.com>2012-05-25 14:13:01 +0200
committerRob Crittenden <rcritten@redhat.com>2012-06-10 21:23:15 -0400
commitce97d6f8e7cb47927fccc27c258d32caf895a88c (patch)
tree9a6218678b2edf0f6fa9fd438f05a697fc67448a /install/tools/ipa-dns-install
parentc856fb60737612781fab30760bceeb8bbf6312d9 (diff)
downloadfreeipa-ce97d6f8e7cb47927fccc27c258d32caf895a88c.tar.gz
freeipa-ce97d6f8e7cb47927fccc27c258d32caf895a88c.tar.xz
freeipa-ce97d6f8e7cb47927fccc27c258d32caf895a88c.zip
Enable persistent search by default
From IPA version 3.0, the persistent search is a preferred mechanism to for DNS zone list management. It will be also a requirement for several bind-dyndb-ldap features, like SOA serial automatic updates or DNSSEC. Make this mechanism default in ipa-server-install and ipa-dns-istall. https://fedorahosted.org/freeipa/ticket/2524
Diffstat (limited to 'install/tools/ipa-dns-install')
-rwxr-xr-xinstall/tools/ipa-dns-install24
1 files changed, 14 insertions, 10 deletions
diff --git a/install/tools/ipa-dns-install b/install/tools/ipa-dns-install
index 063cf5bf5..6e9b99897 100755
--- a/install/tools/ipa-dns-install
+++ b/install/tools/ipa-dns-install
@@ -27,7 +27,7 @@ from ipapython import version
from ipapython import ipautil, sysrestore
from ipalib import api, errors, util
from ipapython.config import IPAOptionParser
-from ipalib.constants import DNS_ZONE_REFRESH
+from optparse import OptionGroup, SUPPRESS_HELP
import krbV
import ldap
from ipapython.ipa_log_manager import *
@@ -52,14 +52,16 @@ def parse_options():
parser.add_option("--zonemgr", action="callback", callback=bindinstance.zonemgr_callback,
type="string",
help="DNS zone manager e-mail address. Defaults to hostmaster@DOMAIN")
+ # this option name has been deprecated, persistent search has been enabled by default
parser.add_option("--zone-notif", dest="zone_notif",
- action="store_true", default=False,
- help="Let name server receive notification when a new zone is added." \
- "Zone refresh is turned off when zone notification is enabled")
+ action="store_true", default=False, help=SUPPRESS_HELP)
+ parser.add_option("--no-persistent-search", dest="persistent_search",
+ default=True, action="store_false",
+ help="Do not enable persistent search feature in the name server")
parser.add_option("--zone-refresh", dest="zone_refresh",
- default=DNS_ZONE_REFRESH, type="int",
- help="A delay between checks for new DNS zones. Defaults to %d" \
- % DNS_ZONE_REFRESH)
+ default=0, type="int",
+ help="When set to non-zero the name server will use DNS zone "
+ "detection based on polling instead of a persistent search")
parser.add_option("-U", "--unattended", dest="unattended", action="store_true",
default=False, help="unattended installation never prompts the user")
@@ -77,9 +79,11 @@ def parse_options():
if options.zone_refresh < 0:
parser.error("negative numbers not allowed for --zone-refresh")
+ elif options.zone_refresh > 0:
+ options.persistent_search = False # mutually exclusive features
- if options.zone_notif: # mutually exclusive features
- options.zone_refresh = 0
+ if options.zone_notif:
+ print >>sys.stderr, "WARNING: --zone-notif option is deprecated and has no effect"
return safe_options, options
@@ -220,7 +224,7 @@ def main():
bind.setup(api.env.host, ip_address, api.env.realm, api.env.domain,
dns_forwarders, conf_ntp, reverse_zone, zonemgr=options.zonemgr,
zone_refresh=options.zone_refresh,
- zone_notif=options.zone_notif)
+ persistent_search=options.persistent_search)
bind.create_instance()
# Restart http instance to make sure that python-dns has the right resolver