Thursday, May 26, 2016

Renaming AD hostname

In this exercise I want to show you how to rename AD Server Hostname from LON-DC1.adatum.com to MIZI01.cpx.local..
Now, if their domain controllers are running 2012 server you are good-to-go, because starting with 2003, you can rename the domain name.
** Domain Controllers configured as a Certificate Authority (CA) cannot be renamed
So.. let’s get started..
1 – Here what I have is a Server 2012 call LON-DC1.adatum.com, and i going torename it to MIZI01.cpx.local.. this Windows Server 2012 previous domain name was adatum.com and if you want to know how to change domain name, please refer to my last post here https://mizitechinfo.wordpress.com/2013/06/10/simple-guide-how-to-rename-domain-name-in-windows-server-2012/ 1
2 – Next, open CMD.. and this is the SYNTAX : netdom computername <currentDC FQDN> /add:<newDCName FQDN> 
— so in your cmd, type netdom computername LON-DC1.adatum.com/add:MIZI01.cpx.local
2

3 – After you get “The command completed successfully”, the next syntax is : netdom computername <currentDC FQDN> /makeprimary:<newDCName FQDN>
— so in your cmd, type netdom computername LON-DC1.adatum.com/makeprimary:MIZI01.cpx.local
— After you get  “The command completed successfully”.. Restart your Server..
3
4 – After your Windows Server 2012 domain server reboot.. go to System Properties and confirm that the new server hostname is listed.
4

5 – Next, open CMD and the next syntax is : netdom computername <newDCName FQDN> /remove:<oldDCName FQDN>
—  This command is to remove old Server Hostname which is LOC-DC1..
— so in your CMD type this : netdom computername MIZI01.cpx.local/remove:LON-DC1.adatum.com and press enter…
5
6 – your last step, do confirm that your Domain Server running without any issue, on the CMD run this command : dcdiag
6
7

Renaming Domain Name

For Server Admin who familiar with Windows Server 2000 & 2003, you maybe still remember about RENDOM utility, which is this use to rename Windows 2000 @ 2003 domain name and have to install manually.
But in Windows Server 2012 domain you don’t have to separately install “Rendom” utility.
It gets installed as part of “Active Directory Domain Services” role when you promote a server to the DC role. And It can be found here : %windir%\system32\rendom.exe.
For this time Simple Guide, I will show you all how to rename domain name in Windows Server 2012, the process is straightforward.. but as usual.. backup any necessary information @ Server before you proceed & I always advice especially to my students, please do this exercises in LAB Environment (Hyper-V).  Don’t simply take any risk by doing this is production environment unless you have to!!.
For this exercises, I’m using MCT courseware from 20410B (Installing and Configuring Windows Server 2012).
The existing domain is ADATUM.COM and I will rename it to CPX.LOCAL.
1 – Open your System Properties and check your existing domain name, if you see from my Windows Server 2012 system properties, my existing domain name isAdatum.com. This will be change to cpx.local in the short while.
1
2 – Next, open your Server Dashboard, go to Tools & click DNS to open DNS Manager..
2
3 – on the DNS Manager, you must create the New DNS Zone (cpx.local), this is to make sure that after whole process successfully, your member server @ Windows clients can join to new Domain name.
** to create new DNS Zone, Right Click Forward Lookup Zone, and click New Zone
3
4 – On the Welcome to the New Zone Wizard, just click Next button..
4
5 – On the Zone Type, Click Primary Zone and click Next..
5
6 – On the Active Directory Zone Replication Scope, click button To all DNS servers running on domain controllers in this domain:Adatum.com and click Next…
6
7 – In the Zone Name, key in your new Domain Name, my new Domain Name iscpx.local
7
8 – On the Dynamic Update, Click Allow only secure dynamic updates (recommended for Active Directory), and click Next…
8
9 – On the completing the New Zone Wizard, click Finish to complete the process.
9
10 – On DNS Manager, you can see my new Domain Name is listed (cpx.local)
10
11 – Next, open Command Prompt, run as administrator.. 
11
12 – In CMD, type rendom /list and press enter – this command use to generate a state file named Domainlist.xml. This file contains the current forest configuration.
12
13 – Next, open computer and browse to C:\Users\Administrator folder to get your Domainlist.xml.
13
14 – Once you see the Domainlist.xml, right click the file name & choose Edit.. I going to change the DNSname and NetBiosName in this  Domainlist.xml file.
14
15 – Once the  Domainlist.xml open, you can see there are few existing Domain name, change this existing domain name to new domain name.. refer to picture:
15
16 – once you change to new Domain name, make sure you save the  Domainlist.xml file..
16
17 – After you save the  Domainlist.xml file, close it and return to CMD. On the CMD, type rendom /showforest. This is to show the potential changes; this step does not make any changes.
17
18 – Next, type rendom /upload. This is to upload the rename instructions (Domainlist.xml) to the configuration directory partition on the domain controller holding the domain naming operations master role.
18
19 – Next, type rendom /prepare. This use to verify the readiness of each DC in the forest to carry out the rename instructions. This should contact all DC’s successfully and return no errors before proceed to next process.
19
20 – Next, type rendom /execute. This is to verifies readiness of all DC’s and then preforms the rename action on each one.
** Remember also there will be a service interruption during this process. Once the process successful, your DC Server will be restarted.
20
21
21 – Once your DC Server restarted, log in using the new Domain name as administrator.
22
22 – Next, after you successfully log in, open System Properties and check your old Domain Name is now gone.. replace by new Domain name…
23
23 – Next, open CMD again, and type gpfixup /olddns:adatum.com/newdns:cpx.local. This is to refresh all intradomain references and links to group policy objects.
24

24 – Next, type gpfixup /oldnb:lon-dc1 /newnb:cpx..
25

25 – Next, type rendom /clean. This is to remove references of the old domain name from AD.
26

26 – Next, type rendom /end. This is to unfreeze the forest configuration and allow further changes. This was frozen during the rendom /upload step.
27

27 – Next, Open DNS Manager, click your new created domain (cpx.local), here you can see your own IP listed but we still have long way to go to make sure this DNS Zone is working..
28

28 – Next, turn on your client PC, for this exercise I’m using Windows 8 as a client. Open System Properties and join to new Domain (cpx.local). in case you getting an error, don’t get scared!!.. just click OK and you Windows Security box will show up and now key in administrator and domain password and click OK (Welcome to the cpx.local domain). Refer pictures..
29

30

31

29 – After your Windows 8 restart, log in as a domain administrator.
32

30 – Once you log in, double check Windows 8 System Properties. Now yourWindows 8 successfully join in to new Domain (cpx.local).
33

31 – Now, go to the Server 2012 and open DNS Manager, you can see now yourWindows 8 Client is listed in DNS.
34

32 – You can also check in Active Directory Users & Computers that your Windows 8 Client now also listed.
35

AD Installation

AD DS database stores information on user identity, computers,groupsservices and resources.
AD DS domain controllers also host the service that authenticates user and computer accounts when they log on to the domain. Because AD DS stores information about all of the objects in the domain, and all users and computers must connect to AD DS domain controllers when signing into the network, AD DS is the primary means by which you can configure and manage user and computer accounts on your network.
1 – Double confirm the Windows Server 2012 that you are using still in Workgroup configuration.
1
2 – Change your Server IP to static IP, for this exercise I’m using IP class A which is 10.10.0.10 / subnet mask : 255.255.0.0 / Default Gateway : 10.10.0.1 / Preferred DNS : 10.10.0.10
2
3 – Open your Server Dashboard, click Add roles and features link @ you can also click menu Manage and choose Add roles and features to continue install ADDS roles (refer picture)
3
4
4 – once you click Add roles and features link/button, you will get Add roles and features Wizard dialogue box, here you just click Next button..
5
5 – after you click Next button, you will get Select installation type dialogue box, and here, double confirm that the Role-based or feature-based installation is selected (this setting is selected by default), and click next…
6
6 – on the next process, you will get Select destination server dialogue box, for this step make sure you click Select a server from the server pool. on this page also you can check & double confirm your Server name now is in Server pool.. and click Next..
7
7 – after you click Next, you will see a lot of Roles on the Select server rolesdialogue box, here make sure you click Active Directory Domain Services box, andAdd features that are required for Active Directory Domain Services? will automatically pop up, then you just click Add features button to accept the default ADDS components..
8
8 – double confirm your selection which is Active Directory Domain Services, and click Next button..
9
9 – on the Select features, just click Next button..
10
10 – on the Active Directory Domain Services dialogue box, click Next..
11
11 – once you click next, on the Confirm installation selections dialogue box, you can click Restart the destination server automatically if required & click Yes button and then click Install to proceed with installation of your 1st ADDS…
12
13
12 – Next, on the installation progress dialogue box, you just wait for few minutes for the ADDS installation to take place..
14
13 – once your ADDS installation done without any error,  click Close
15
14 – Next, open your Server Dashboard, click on the yellow exclamation mark to open the drop menu.. here you have to click Promote this server to a domain controller link to start ADDS deployment..
16
15 – next, on the Deployment Configuration dialogue box, make sure you click Add a new forest button, this is because this Server is our very new server for our new domain. On the Root domain name, type your new domain name, for this example I’m using cpx.local.. and then click Next..
17
16 – on the Domain Controller Options, since this will be my new Infrastructure and all my existing server also running Server 2012, I just leave the Forest & Domain functional level as Windows Server 2012.. Under Specify domain controller capabilities, Domain Name System (DNS) server is selected by default (in case you have different DNS server, please un-tick the DNS box & make sure you change the preferred DNS IP address in the Network & Sharing Center point to your existing DNS server..). Under the Type the Directory Services Restore Mode (DSRM) password, key in any password that belong to Administrator and click Next.
18
17 – on the DNS options dialogue box, just click Next..
19
18 – on the Additional Options dialogue box, verify that your NetBIOS is pointing to your existing domain name.. and click Next..
20
19 – on the Paths dialogue box, you can just leave it the setting @ you can choose to point the ADDS database, log & sysvol file to different location.. and click Next..
21
20 – once you click next, you can review all your previous step & settings on theReview Options dialogue box.. if all correct click Next..
22
21 – on the Prerequisites Check dialogue box, you can see “All prerequisite check passed successfully. Click install to begin installation..” so just click Install button..
23
22 – if everything goes well.. you can see the AD installation progress is starting.. just wait for few minutes for the process to complete.. and your Server 2012 will auto reboot..
24

23 – after your Server 2012 reboot, you now can log in as a Domain Administrator..
25

24 – once you successfully log in, open your Server Dashboard and take few minutes to go open Active Directory Users & Computers and DNS Manager.. this is just to double check that all the installation is 100% successfully.
26

27

29
25 – Next, you can also double check your Server System Properties @ in your Local Server on the Dashboard, and see your full Server Info..
28

30
*