Information Technology Reference
In-Depth Information
domain controller. You must create the installation media from the same version of Windows
Server as the version you want to promote to a domain controller.
After you have the installation media for the IFM option, use the following to promote the
server to a domain controller:
$myCred = Get-Credential -Message "Enter your domain credentials"
Install-ADDSDomainController `
-DomainName "TreyResearch.net" `
-Credential $myCred `
-InstallDNS `
-InstallationMediaPath "D:\IFM"
If you are logged in with an account that has Domain Admin privileges, you can skip the
credentials. If you are promoting a domain controller that is also a DNS server, the installation
media has to be created on a domain controller that is also a DNS server.
Optimizing an active Directory database
You can optimize an Active Directory database by defragmenting it. Normally, defragmentation
automatically occurs online. However, you can do an offline defragmentation to recover
space in the AD DS database and optimize it. The tool for offline defragmentation is Ntdsutil.
exe. Use the following sequence from an elevated command prompt with Domain Admin
credentials on the domain controller where you want to defragment the database:
Net stop NTDS
Ntdsutil.exe
activate instance ntds
files
compact to "<location>"
quit
quit
If the compaction occurred without error, ntdsutil reports success and lists the remaining
steps, as shown in Figure 5-16.
Once back at the command prompt, copy the existing C:\Windows\ntds\ntds.dit file to a
temporary location, just in case, and then delete the log files, as described by the Ntdsutil.
exe shell, and copy the compacted ntds.nit file back to C:\Windows\ntds. Use the following
Ntdsutil.exe sequence to verify the integrity of the compacted database:
Ntdsutil.exe
activate instance ntds
files
Integrity
If there are no integrity problems with the Active Directory database, ntdsutil.exe reports
success and you can type quit and then quit again to exit Ntdsutil.exe. Restart the ntds
service by typing net start NTDS .
 
 
Search WWH ::




Custom Search