Configuration driven Active Directory management.
Deploys a new forest / root domain.
Install-DCRootDomain [[-ComputerName] <ComputerParameter>] [[-Credential] <PSCredential>] [-DnsName] <String>
[[-NetBiosName] <String>] [[-SafeModeAdministratorPassword] <SecureString>] [-NoDNS] [-NoReboot]
[[-LogPath] <String>] [[-SysvolPath] <String>] [[-DatabasePath] <String>] [-NoResultCache] [-EnableException]
[-WhatIf] [-Confirm] [<CommonParameters>]
Deploys a new forest / root domain.
Install-DCRootDomain -DnsName 'contoso.com'
Creates the forest “contoso.com” while promoting the computer as DC.
The computer on which to install it. Uses WinRM / PowerShell remoting if not local execution.
Type: ComputerParameter
Parameter Sets: (All)
Aliases:
Required: False
Position: 1
Default value: Localhost
Accept pipeline input: False
Accept wildcard characters: False
The credentials to use for this operation.
Type: PSCredential
Parameter Sets: (All)
Aliases:
Required: False
Position: 2
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
The name of the new domain & forest.
Type: String
Parameter Sets: (All)
Aliases:
Required: True
Position: 3
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
The netbios name of the new domain. If not specified, it will automatically use the first element of the DNS name
Type: String
Parameter Sets: (All)
Aliases:
Required: False
Position: 4
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
The password to use as SafeModeAdministratorPassword. Autogenerates and reports a new password if not specified.
Type: SecureString
Parameter Sets: (All)
Aliases:
Required: False
Position: 5
Default value: (New-Password -Length 32 -AsSecureString)
Accept pipeline input: False
Accept wildcard characters: False
Disable deploying a DNS service with the new forest.
Type: SwitchParameter
Parameter Sets: (All)
Aliases:
Required: False
Position: Named
Default value: False
Accept pipeline input: False
Accept wildcard characters: False
Prevent reboot after finishing deployment
Type: SwitchParameter
Parameter Sets: (All)
Aliases:
Required: False
Position: Named
Default value: False
Accept pipeline input: False
Accept wildcard characters: False
The path where the DC will store the logs.
Type: String
Parameter Sets: (All)
Aliases:
Required: False
Position: 6
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
The path where the DC will store sysvol.
Type: String
Parameter Sets: (All)
Aliases:
Required: False
Position: 7
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
The path where the DC will store NTDS Database.
Type: String
Parameter Sets: (All)
Aliases:
Required: False
Position: 8
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
Disables caching the result object of the operation. By default, this command will cache the result of the installation (including the SafeModeAdministratorPassword), to reduce the risk of user error.
Type: SwitchParameter
Parameter Sets: (All)
Aliases:
Required: False
Position: Named
Default value: False
Accept pipeline input: False
Accept wildcard characters: False
This parameters disables user-friendly warnings and enables the throwing of exceptions. This is less user friendly, but allows catching exceptions in calling scripts.
Type: SwitchParameter
Parameter Sets: (All)
Aliases:
Required: False
Position: Named
Default value: False
Accept pipeline input: False
Accept wildcard characters: False
If this switch is enabled, no actions are performed but informational messages will be displayed that explain what would happen if the command were to run.
Type: SwitchParameter
Parameter Sets: (All)
Aliases: wi
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
If this switch is enabled, you will be prompted for confirmation before executing any operations that change state.
Type: SwitchParameter
Parameter Sets: (All)
Aliases: cf
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.