robocopy \\WIN-DC\SYSVOL\lab.lan\ \\LIN-DC\SYSVOL\lab.lan\ /mir /sec
find /var/lib/samba/sysvol
ntdsutil
C:\Windows\System32\ntdsutil.exe: roles
fsmo maintenance: connections
server connections: connect to server lin-dc
server connections: q
fsmo maintenance: transfer naming master
fsmo maintenance: transfer infrastructure master
fsmo maintenance: transfer rid master
fsmo maintenance: transfer schema master
fsmo maintenance: transfer pdc
fsmo maintenance: q
C:\Windows\System32\ntdsutil.exe: q
samba-tool fsmo seize --role=forestdns
samba-tool fsmo seize --role=domaindns
samba-tool fsmo show
apt install ldap-utils
ldapsearch -x -D "cn=Administrator,cn=Users,dc=lab,dc=lan" -W -H ldap://lin-dc -b "dc=lab,dc=lan" "sAMAccountName=support"
samba-tool domain demote --remove-other-dead-server=WIN-DC