Bug 53093 - univention-samba4 should provide script migrate_legacy_dns_zones
univention-samba4 should provide script migrate_legacy_dns_zones
Status: CLOSED FIXED
Product: UCS
Classification: Unclassified
Component: Samba4
UCS 4.4
Other Linux
: P5 enhancement (vote)
: UCS 5.0
Assigned To: Arvid Requate
Felix Botner
:
Depends on:
Blocks: 43692
  Show dependency treegraph
 
Reported: 2021-04-14 12:08 CEST by Arvid Requate
Modified: 2023-11-09 13:42 CET (History)
1 user (show)

See Also:
What kind of report is it?: Development Internal
What type of bug is this?: 5: Major Usability: Impairs usability in key scenarios
Who will be affected by this bug?: 3: Will affect average number of installed domains
How will those affected feel about the bug?: 2: A Pain – users won’t like this once they notice it
User Pain: 0.171
Enterprise Customer affected?:
School Customer affected?:
ISV affected?:
Waiting Support:
Flags outvoted (downgraded) after PO Review:
Ticket number:
Bug group (optional):
Max CVSS v3 score:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Arvid Requate univentionstaff 2021-04-14 12:08:37 CEST
In preparation for Bug #43692 univention-samba4 should provide script migrate_legacy_dns_zones.
Comment 1 Arvid Requate univentionstaff 2021-04-14 12:24:36 CEST
b0bc61c8bc | Provide script migrate_legacy_dns_zones.sh
8d65290cbd | advisory

This simply installs the script attached to 43692 with minor changes (e.g. log message and log file path) to

/usr/share/univention-samba4/scripts/migrate_legacy_dns_zones.sh


Package: univention-samba4
Version: 9.0.6-1A~5.0.0.202104141223
Branch: ucs_5.0-0
Comment 2 Arvid Requate univentionstaff 2021-04-14 13:44:04 CEST
b14e3655a3 | Copyright header

Package: univention-samba4
Version: 9.0.6-1A~5.0.0.202104141344
Branch: ucs_5.0-0
Comment 3 Felix Botner univentionstaff 2021-04-14 13:56:47 CEST
(1) make it executable (currently -rw-r--r--)
(2) started on a new UCS 5.0 
-> bash   /usr/share/univention-samba4/scripts/migrate_legacy_dns_zones.sh -h
INFO: No dnsZone objects found under CN=System, nothing to do.
cp: reguläre Datei '/var/univention-backup/samba/dns-202104141318/tmp' kann nicht angelegt werden: Datei oder Verzeichnis nicht gefunden

in the meantime i try to setup a system with legacy dns ...
Comment 4 Felix Botner univentionstaff 2021-04-14 15:18:28 CEST
bash /usr/share/univention-samba4/scripts/migrate_legacy_dns_zones.sh -h
INFO: connector/s4/mapping/dns/position == legacy

INFO: connector/s4/mapping/dns/position != legacy
INFO: Creating backup directory: /var/univention-backup/samba/dns-202104141515
Setting connector/s4/mapping/dns/ignorelist
Checking five.test
Traceback (most recent call last):
  File "<stdin>", line 2, in <module>
ImportError: No module named samba.dcerpc
Traceback (most recent call last):
  File "<stdin>", line 2, in <module>
ImportError: No module named samba.dcerpc
Traceback (most recent call last):
  File "<stdin>", line 2, in <module>
ImportError: No module named samba.dcerpc


i guess a python3 issue
Comment 5 Arvid Requate univentionstaff 2021-04-14 19:45:42 CEST
4820fad55b | Fixed:
* python -> python3
* make script executable

Package: univention-samba4
Version: 9.0.6-1A~5.0.0.202104141945
Branch: ucs_5.0-0
Comment 6 Felix Botner univentionstaff 2021-04-15 11:21:08 CEST
OK - script exists and is executable
OK - short test

 UCS 5.0
-> ucr set connector/s4/mapping/dns/position=legacy
-> univention-install univention-s4-connector
-> /usr/share/univention-samba4/scripts/migrate_legacy_dns_zones.sh

-> nslookup
-> kinit Administrator
-> univention-s4connector-list-rejected
Comment 7 Florian Best univentionstaff 2021-05-25 15:59:06 CEST
UCS 5.0 has been released:
 https://docs.software-univention.de/release-notes-5.0-0-en.html
 https://docs.software-univention.de/release-notes-5.0-0-de.html

If this error occurs again, please use "Clone This Bug".
Comment 8 Christian Zengel 2022-08-08 15:24:32 CEST
(In reply to Felix Botner from comment #6)
> OK - script exists and is executable
> OK - short test
> 
>  UCS 5.0
> -> ucr set connector/s4/mapping/dns/position=legacy
> -> univention-install univention-s4-connector
> -> /usr/share/univention-samba4/scripts/migrate_legacy_dns_zones.sh
> 
> -> nslookup
> -> kinit Administrator
> -> univention-s4connector-list-rejected

Working on 5.0.2
Comment 9 Christian Zengel 2023-11-09 13:42:44 CET
Still not working with 5.0.5 and 4.4-9

root@ucs:~# /usr/share/univention-samba4/scripts/check_essential_samba4_dns_records.sh
Host gc._msdcs.dfm.lan not found: 3(NXDOMAIN)
_gc._tcp.dfm.lan has SRV record 0 100 3268 ucs.dfm.lan.
Host _ldap._tcp.gc._msdcs.dfm.lan not found: 3(NXDOMAIN)
_ldap._tcp.dfm.lan has SRV record 0 100 389 ucs.dfm.lan.
Host _ldap._tcp.dc._msdcs.dfm.lan not found: 3(NXDOMAIN)
Host _ldap._tcp.pdc._msdcs.dfm.lan not found: 3(NXDOMAIN)
Host _ldap._tcp.a6dc9851-6c89-45cc-b177-1b45b8224099.domains._msdcs.dfm.lan not found: 3(NXDOMAIN)
Host _kerberos._tcp.dc._msdcs.dfm.lan not found: 3(NXDOMAIN)
_kerberos._tcp.dfm.lan has SRV record 0 100 88 ucs.dfm.lan.
_kerberos._udp.dfm.lan has SRV record 0 100 88 ucs.dfm.lan.
_kpasswd._tcp.dfm.lan has SRV record 0 100 464 ucs.dfm.lan.
_kpasswd._udp.dfm.lan has SRV record 0 100 464 ucs.dfm.lan.
Located DC 'ucs' in site 'Saarlouis'
Host 3fb3eee0-9b05-4f3e-b083-6a8bb605256b._msdcs.dfm.lan not found: 3(NXDOMAIN)
## Records for site Saarlouis:
_ldap._tcp.Saarlouis._sites.dfm.lan has SRV record 0 100 389 srv2008-dc01.dfm.lan.
_ldap._tcp.Saarlouis._sites.dfm.lan has SRV record 0 100 389 ucs.dfm.lan.
Host _ldap._tcp.Saarlouis._sites.dc._msdcs.dfm.lan not found: 3(NXDOMAIN)
_kerberos._tcp.Saarlouis._sites.dfm.lan has SRV record 0 100 88 srv2008-dc01.dfm.lan.
_kerberos._tcp.Saarlouis._sites.dfm.lan has SRV record 0 100 88 ucs.dfm.lan.
Host _kerberos._tcp.Saarlouis._sites.dc._msdcs.dfm.lan not found: 3(NXDOMAIN)
## Optional GC Records for site Saarlouis:
_gc._tcp.Saarlouis._sites.dfm.lan has SRV record 0 100 3268 srv2008-dc01.dfm.lan.
_gc._tcp.Saarlouis._sites.dfm.lan has SRV record 0 100 3268 ucs.dfm.lan.
Host _ldap._tcp.Saarlouis._sites.gc._msdcs.dfm.lan not found: 3(NXDOMAIN)
_kerberos.dfm.lan descriptive text "DFM.LAN"
root@ucs:~# locate legacy_dns^C
root@ucs:~# bash e08003da2ee3b63dca0c9efffbaa630c555886b1.sh
INFO: No dnsZone objects found under CN=System, nothing to do.
root@ucs:~# /usr/share/univention-samba4/scripts/check_essential_samba4_dns_records.sh