s4 dns: use the internal DNS server per default
authorKai Blin <kai@samba.org>
Tue, 11 Sep 2012 07:07:47 +0000 (09:07 +0200)
committerStefan Metzmacher <metze@samba.org>
Wed, 12 Sep 2012 14:51:29 +0000 (16:51 +0200)
source4/scripting/bin/samba_upgradedns
source4/scripting/python/samba/netcmd/domain.py
source4/scripting/python/samba/provision/__init__.py
wintest/wintest.py

index c1220bcc264d2c242e4f091b73c057aba5a452b7..efda448d480c6e9ce19a2cb7c27458f67d90effc 100755 (executable)
@@ -238,8 +238,8 @@ if __name__ == '__main__':
     parser.add_option_group(credopts)
 
     parser.add_option("--dns-backend", type="choice", metavar="<BIND9_DLZ|SAMBA_INTERNAL>",
-                      choices=["SAMBA_INTERNAL", "BIND9_DLZ"], default="BIND9_DLZ",
-                      help="The DNS server backend, default BIND9_DLZ")
+                      choices=["SAMBA_INTERNAL", "BIND9_DLZ"], default="SAMBA_INTERNAL",
+                      help="The DNS server backend, default SAMBA_INTERNAL")
     parser.add_option("--migrate", type="choice", metavar="<yes|no>",
                       choices=["yes","no"], default="yes",
                       help="Migrate existing zone data, default yes")
@@ -248,7 +248,7 @@ if __name__ == '__main__':
     opts = parser.parse_args()[0]
 
     if opts.dns_backend is None:
-        opts.dns_backend = 'DLZ_BIND9'
+        opts.dns_backend = 'SAMBA_INTERNAL'
 
     if opts.migrate:
         autofill = False
index d35ee577ea99dc212a04dbba42954495454021d6..119c19757f8de464a315e1b0d0a4718e14221684 100644 (file)
@@ -174,11 +174,11 @@ class cmd_domain_provision(Command):
                 help="choose machine password (otherwise random)"),
          Option("--dns-backend", type="choice", metavar="NAMESERVER-BACKEND",
                 choices=["SAMBA_INTERNAL", "BIND9_FLATFILE", "BIND9_DLZ", "NONE"],
-                help="The DNS server backend. SAMBA_INTERNAL is the builtin name server, " \
+                help="The DNS server backend. SAMBA_INTERNAL is the builtin name server (default), " \
                      "BIND9_FLATFILE uses bind9 text database to store zone information, " \
-                     "BIND9_DLZ uses samba4 AD to store zone information (default), " \
+                     "BIND9_DLZ uses samba4 AD to store zone information, " \
                      "NONE skips the DNS setup entirely (not recommended)",
-                default="BIND9_DLZ"),
+                default="SAMBA_INTERNAL"),
          Option("--dnspass", type="string", metavar="PASSWORD",
                 help="choose dns password (otherwise random)"),
          Option("--ldapadminpass", type="string", metavar="PASSWORD",
@@ -297,7 +297,7 @@ class cmd_domain_provision(Command):
 
             server_role = ask("Server Role (dc, member, standalone)", "dc")
 
-            dns_backend = ask("DNS backend (SAMBA_INTERNAL, BIND9_FLATFILE, BIND9_DLZ, NONE)", "BIND9_DLZ")
+            dns_backend = ask("DNS backend (SAMBA_INTERNAL, BIND9_FLATFILE, BIND9_DLZ, NONE)", "SAMBA_INTERNAL")
             if dns_backend in (None, ''):
                 raise CommandError("No DNS backend set!")
 
@@ -412,10 +412,10 @@ class cmd_domain_dcpromo(Command):
                action="store_true"),
         Option("--dns-backend", type="choice", metavar="NAMESERVER-BACKEND",
                choices=["SAMBA_INTERNAL", "BIND9_DLZ", "NONE"],
-               help="The DNS server backend. SAMBA_INTERNAL is the builtin name server, " \
-                   "BIND9_DLZ uses samba4 AD to store zone information (default), " \
+               help="The DNS server backend. SAMBA_INTERNAL is the builtin name server (default), " \
+                   "BIND9_DLZ uses samba4 AD to store zone information, " \
                    "NONE skips the DNS setup entirely (this DC will not be a DNS server)",
-               default="BIND9_DLZ")
+               default="SAMBA_INTERNAL")
        ]
 
     takes_args = ["domain", "role?"]
@@ -479,10 +479,10 @@ class cmd_domain_join(Command):
                action="store_true"),
         Option("--dns-backend", type="choice", metavar="NAMESERVER-BACKEND",
                choices=["SAMBA_INTERNAL", "BIND9_DLZ", "NONE"],
-               help="The DNS server backend. SAMBA_INTERNAL is the builtin name server, " \
-                   "BIND9_DLZ uses samba4 AD to store zone information (default), " \
+               help="The DNS server backend. SAMBA_INTERNAL is the builtin name server (default), " \
+                   "BIND9_DLZ uses samba4 AD to store zone information, " \
                    "NONE skips the DNS setup entirely (this DC will not be a DNS server)",
-               default="BIND9_DLZ")
+               default="SAMBA_INTERNAL")
        ]
 
     takes_args = ["domain", "role?"]
@@ -1177,11 +1177,11 @@ class cmd_domain_classicupgrade(Command):
                action="store_true"),
         Option("--dns-backend", type="choice", metavar="NAMESERVER-BACKEND",
                choices=["SAMBA_INTERNAL", "BIND9_FLATFILE", "BIND9_DLZ", "NONE"],
-               help="The DNS server backend. SAMBA_INTERNAL is the builtin name server, " \
+               help="The DNS server backend. SAMBA_INTERNAL is the builtin name server (default), " \
                    "BIND9_FLATFILE uses bind9 text database to store zone information, " \
-                   "BIND9_DLZ uses samba4 AD to store zone information (default), " \
+                   "BIND9_DLZ uses samba4 AD to store zone information, " \
                    "NONE skips the DNS setup entirely (this DC will not be a DNS server)",
-               default="BIND9_DLZ")
+               default="SAMBA_INTERNAL")
     ]
 
     takes_args = ["smbconf"]
index 862a0c77901fb7bb5c5b99ef5c17650d03fbc3c0..8b0737c226425a8d314d57a8ee62b640f2e51190 100644 (file)
@@ -1816,8 +1816,8 @@ def provision(logger, session_info, credentials, smbconf=None,
     if use_rfc2307:
         global_param["idmap_ldb:use rfc2307"] = ["yes"]
 
-    if dns_backend == "SAMBA_INTERNAL":
-        server_services.append("+dns")
+    if dns_backend != "SAMBA_INTERNAL":
+        server_services.append("-dns")
 
     if use_ntvfs:
         server_services.append("+smb")
index 6257fb45ddc63a2d6cbd9343c8186e071004a226..4ad2d8a651766ae62ccb10118a290698ad635984 100644 (file)
@@ -900,11 +900,11 @@ RebootOnCompletion=No
         self.parser.add_option("--use-ntvfs", action='store_true', default=False, help='use NTVFS for the fileserver')
         self.parser.add_option("--dns-backend", type="choice",
             choices=["SAMBA_INTERNAL", "BIND9_FLATFILE", "BIND9_DLZ", "NONE"],
-            help="The DNS server backend. SAMBA_INTERNAL is the builtin name server, " \
+            help="The DNS server backend. SAMBA_INTERNAL is the builtin name server (default), " \
                  "BIND9_FLATFILE uses bind9 text database to store zone information, " \
-                 "BIND9_DLZ uses samba4 AD to store zone information (default), " \
+                 "BIND9_DLZ uses samba4 AD to store zone information, " \
                  "NONE skips the DNS setup entirely (not recommended)",
-            default="BIND9_DLZ")
+            default="SAMBA_INTERNAL")
 
         self.opts, self.args = self.parser.parse_args()