--- univention-backup2master.o 2013-11-14 14:36:12.111956116 +0100 +++ univention-backup2master 2013-11-14 14:36:32.483956058 +0100 @@ -464,6 +464,14 @@ fi } +# Move Samba4 FSMO roles to this host +# https://forge.univention.org/bugzilla/show_bug.cgi?id=26986 +if [ -x /usr/bin/samba-tool ]; then + if samba-tool fsmo show | grep -qi "CN=${old_ldap_master_hostname},CN=Servers,CN=Default-First-Site-Name,CN=Sites,CN=Configuration"; then + samba-tool fsmo seize --role=all --force + fi +fi + if [ -e "$samdb" ]; then samdb_remove_dc_account "$old_ldap_master_hostname" fi @@ -521,14 +529,6 @@ printf "\nReplacing package univention-server-backup with univention-server-master.\n" apt-get -y install univention-server-master univention-server-backup- -# Move Samba4 FSMO roles to this host -# https://forge.univention.org/bugzilla/show_bug.cgi?id=26986 -if [ -x /usr/bin/samba-tool ]; then - if samba-tool fsmo show | grep -qi "CN=${old_ldap_master_hostname},CN=Servers,CN=Default-First-Site-Name,CN=Sites,CN=Configuration"; then - samba-tool fsmo seize --role=all --force - fi -fi - udm_remove_dns_service_account "$old_ldap_master_hostname" # Any bind9 that might be running shall be restarted.