[Samba] Change hostname of the main domain controller of the Active Directory

Marc Muehlfeld mmuehlfeld at samba.org
Fri Aug 22 09:34:17 MDT 2014


Hello Quentin,

Am 22.08.2014 09:45, schrieb Quentin Gibeaux:
> With Samba4 and Active Directory the hostname of the server is read
> during provision, to set the netbios name. It's even asked to set
> /etc/hostname and /etc/hosts in respect with the chosen domain/realm names.
> 
> I've seen that on real windows AD that it's possible to change the
> hostname of the domain controller with netdom command, but is there a
> way to do so on Samba4 ?
> The netbios name seems to be referenced in several locations :
> 
>  * in smb.conf
>  * in the ldb :
>      o msSFU30MasterServerName in some entries located in
>        CN=ypServ30,CN=RpcServices,CN=System
>      o user's profilePath
>      o it's own domain controller entry located in
>        CN=$NETBIOS,OU=Domain Controllers,DC=...
>      o it's RID entry : CN=RID Set,CN=$NETBIOS,OU=Domain Controllers,DC=...
>      o fSMORoleOwner in CN=RID Manager$,CN=System,DC=... and in
>        CN=Infrastructure,DC=...
>      o the user dns-$NETBIOS
>      o fSMORoleOwner msDs-masteredBy msDS-IsDomainFor masteredBy in
>        DC=... entry
> 
> Any clue to update the server's hostname ?

Don't do the renaming manually inside the databases! You will corrupt
your AD!

Use
# source4/scripting/bin/renamedc
and set the new name in your smb.conf

But I suggest a test in a save environment first.


Regards,
Marc



More information about the samba mailing list