Changing the IP Address of a Samba AD DC: Difference between revisions

From SambaWiki
m (Added category)
m (Updated link)
Line 5: Line 5:
To change the IP address of an Active Directory (AD) domain controller (DC) in a multi-domain environment:
To change the IP address of an Active Directory (AD) domain controller (DC) in a multi-domain environment:


* Demote the DC. For details, see [[Demote_a_Samba_AD_DC|Demote a Samba AD DC]].
* Demote the DC. For details, see [[Demoting a Samba AD DC]].


* Set the new IP address on the network interface and update the DNS server IP address in the <code>/etc/resolv.conf</code> file. For details, see your operating system's documentation.
* Set the new IP address on the network interface and update the DNS server IP address in the <code>/etc/resolv.conf</code> file. For details, see your operating system's documentation.

Revision as of 17:49, 29 March 2017

Changing the IP Address of an AD DC in a Multi-domain Environment

To change the IP address of an Active Directory (AD) domain controller (DC) in a multi-domain environment:

  • Set the new IP address on the network interface and update the DNS server IP address in the /etc/resolv.conf file. For details, see your operating system's documentation.
  • Update the IP address in all domain member's DNS configuration, if they use this DC to resolve the AD DNS zones.



Changing the IP Address of an AD DC in a Single-domain Environment

For example, to change the IP address of the domain controller (DC) from 10.99.0.1 to 10.88.0.1:

  • Disconnect or shut down clients connected to the AD DC.
  • Shut down the samba service.
  • Set the new IP address on the network interface and update the DNS server IP address in the /etc/resolv.conf file. For details, see your operating system's documentation.
  • If you use the BIND9_DLZ DNS back end:
  • If BIND is bound to the old IP address, update the listen-on parameter in the option{} section in the /etc/named.conf file:
# listen-on port 53 { 127.0.0.1;  10.99.0.1 10.88.0.1; };
  • Restart BIND.
  • Verify that BIND is listening on the new IP address:
# netstat -tulpn | grep ":53"
tcp        0      0 10.88.0.1:53       0.0.0.0:*          LISTEN      1109/named
tcp        0      0 127.0.0.1:53       0.0.0.0:*          LISTEN      1109/named
udp        0      0 10.88.0.1:53       0.0.0.0:*                      1109/named
udp        0      0 127.00.1:53        0.0.0.0:*                      1109/named
  • If you set the IP address in the interfaces parameter in the [global] section of your smb.conf file, update the address:
interfaces = 127.0.0.1 10.99.0.1 10.88.0.1
  • Start the samba service.
  • Update the DNS entries:
# samba_dnsupdate --verbose
The samba_dnsupdate utility automatically updates all records in the local database.
  • Verify that the DC's DNS records are resolved correctly:
# host -t A samdom.example.com
samdom.example.com has address 10.88.0.1

# host -t A DC.samdom.example.com
DC.samdom.example.com has address 10.88.0.1

# host -t A gc._msdcs.samdom.example.com
gc._msdcs.samdom.example.com has address 10.88.0.1
  • Update your AD clients to use the new IP address of the AD DNS server.