Install-ADDSForest

Install-ADDSForest is accessible with the help of addsdeployment module. To install addsdeployment on your system please refer to this link.

Synopsis

Installs a new Active Directory forest configuration.

Description

The Install-ADDSForest cmdlet installs a new Active Directory forest configuration.

Parameters

-CreateDnsDelegation 
         Indicates whether to create a DNS delegation that references the new DNS server that you are installing along with the domain controller. Valid for Active Directory-integrated DNS only. The default is computed automatically based on the environment.

    Required?                    false
    Position?                    named
    Default value                NULL
    Accept pipeline input?       false
    Accept wildcard characters?  false

-DatabasePath <String>
    Specifies the fully qualified, non-Universal Naming Convention (UNC) path to a directory on a fixed disk of the local computer that contains the domain database, for example, C:\Databases\NTDS. The default is %SYSTEMROOT%\NTDS.

    Required?                    false
    Position?                    named
    Default value                NULL
    Accept pipeline input?       false
    Accept wildcard characters?  false

-DnsDelegationCredential <PSCredential>
    Specifies the user name and password (account credentials) for creating DNS delegation. This parameter is skipped if the value for the -CreateDnsDelegation parameter is either specified or computed to be $false.

    Required?                    false
    Position?                    named
    Default value                NULL
    Accept pipeline input?       false
    Accept wildcard characters?  false

-DomainMode <DomainMode>
    Specifies the domain functional level of the first domain in the creation of a new forest. Supported values for this parameter can be either a valid integer or a corresponding enumerated string value. For example, to set the domain mode level to Windows Server 2008 R2, you can specify either a value of 4 or Win2008R2. Other supported values include those for Windows&nbsp;Server&nbsp;2003 (2 or Win2003) Windows&nbsp;Server&nbsp;2008 (3 or Win2008) and Windows&nbsp;Server&nbsp;2012 (5 or Win2012). The domain functional level cannot be lower than the forest functional level, but it can be higher. The default is automatically computed and set.

    Required?                    false
    Position?                    named
    Default value                Windows2008R2
    Accept pipeline input?       false
    Accept wildcard characters?  false

-DomainName <String>
    Specifies the fully qualified domain name (FQDN) for the root (first) domain in the forest.

    Required?                    true
    Position?                    named
    Default value                <mandatory>
    Accept pipeline input?       false
    Accept wildcard characters?  false

-DomainNetbiosName <String>
    Specifies the NetBIOS name for the root domain in the new forest. For NetBIOS names to be valid for use with this parameter they must be single label names of 15 characters or less.

    Required?                    false
    Position?                    named
    Default value                NULL
    Accept pipeline input?       false
    Accept wildcard characters?  false

-Force <SwitchParameter>
    When this parameter is specified any warnings that might normally appear during the installation of the new forest will be suppressed to allow the cmdlet to complete its operation. This parameter can be useful to include when scripting installation of new forests.

    Required?                    false
    Position?                    named
    Default value                
    Accept pipeline input?       false
    Accept wildcard characters?  false

-ForestMode <ForestMode>
    Specifies the forest functional level for the new forest. Supported values for this parameter can be either a valid integer or a corresponding enumerated string value. For example, to set the forest mode level to Windows Server 2008 R2, you can specify either a value of 4 or Win2008R2. Other supported values include those for Windows&nbsp;Server&nbsp;2003 (2 or Win2003) Windows&nbsp;Server&nbsp;2008 (3 or Win2008) and Windows&nbsp;Server&nbsp;2012 (5, Win2012). The default forest functional level in Windows&nbsp;Server&nbsp;2012 when you create a new forest is Windows&nbsp;Server&nbsp;2012 (5). The default forest functional level in Windows&nbsp;Server&nbsp;2008&nbsp;R2 when you create a new forest is Windows&nbsp;Server&nbsp;2003 (2).

    Required?                    false
    Position?                    named
    Default value                Windows2008R2
    Accept pipeline input?       false
    Accept wildcard characters?  false

-InstallDns <SwitchParameter>
    Specifies whether the DNS Server service should be installed and configured for the new forest. For forest installation, the default is $true (a new DNS server will be installed and configured).

    Required?                    false
    Position?                    named
    Default value                NULL
    Accept pipeline input?       false
    Accept wildcard characters?  false

-LogPath <String>
    Specifies the fully qualified, non-UNC path to a directory on a fixed disk of the local computer where the log file for this operation will be written. For example, C:\Logs. The default log file path if no other path is specified with this parameter is %SYSTEMROOT%\NTDS.

    Required?                    false
    Position?                    named
    Default value                NULL
    Accept pipeline input?       false
    Accept wildcard characters?  false

-NoDnsOnNetwork <SwitchParameter>
    Specifies that DNS service is not available on the network. This parameter is used only when the IP setting of the network adapter for this computer is not configured with the name of a DNS server for name resolution. It indicates that a DNS server will be installed on this computer for name resolution. Otherwise, the IP settings of the network adapter must first be configured with the address of a DNS server.


    Required?                    false
    Position?                    named
    Default value                
    Accept pipeline input?       false
    Accept wildcard characters?  false

-NoRebootOnCompletion <SwitchParameter>
    Specifies that the computer is not to be rebooted upon completion of this command. Omitting this parameter (the default) indicates the computer will be rebooted upon completion of the command, regardless of success or failure. As a general rule, Microsoft support recommends that you not use this parameter except for testing or troubleshooting purposes because once configuration has completed the server will not function correctly as either a member server or a DC until it is rebooted.

    Required?                    false
    Position?                    named
    Default value                
    Accept pipeline input?       false
    Accept wildcard characters?  false

-SafeModeAdministratorPassword <SecureString>
    Supplies the password for the administrator account when the computer is started in Safe Mode or a variant of Safe Mode, such as Directory Services Restore Mode. You must supply a password that meets the password complexity rules of the domain and the password cannot be blank. If specified with a value, the value must be a secure string.

    Required?                    false
    Position?                    named
    Default value                <mandatory>
    Accept pipeline input?       false
    Accept wildcard characters?  false

-SkipAutoConfigureDns <SwitchParameter>
    Skips automatic configuration of DNS client settings, forwarders, and root hints. This parameter is in effect only if the DNS Server service is already installed.

    Required?                    false
    Position?                    named
    Default value                NULL
    Accept pipeline input?       false
    Accept wildcard characters?  false

-SkipPreChecks <SwitchParameter>
    Specifies that only a base set of validations will be performed. This behavior is equivalent to the validations that were performed when using Dcpromo.exe in earlier versions of Windows Server to add a new forest. When this switch parameter is set, it specifies that additional preliminary checks should be bypassed. For more information on the scope of these additional preliminary checks that the ADDSDeployment module performs by default when using Windows Server 2012, refer to the table in the section “Prerequisite Checking” in the Understand and Troubleshoot AD DS Simplified Administration in Windows&nbsp;Server&nbsp;2012 guide (http://go.microsoft.com/fwlink/?LinkID=237244).

    Required?                    false
    Position?                    named
    Default value                
    Accept pipeline input?       false
    Accept wildcard characters?  false

-SysvolPath <String>
    Specifies the fully qualified, non-UNC path to a directory on a fixed disk of the local computer where the Sysvol file will be written. For example, C:\Logs\SYSVOL. The default path if no other path is specified with this parameter is %SYSTEMROOT%\SYSVOL.

    Required?                    false
    Position?                    named
    Default value                NULL
    Accept pipeline input?       false
    Accept wildcard characters?  false

-Confirm <SwitchParameter>
    Prompts you for confirmation before running the cmdlet.

    Required?                    false
    Position?                    named
    Default value                false
    Accept pipeline input?       false
    Accept wildcard characters?  false

-WhatIf <SwitchParameter>
    Shows what would happen if the cmdlet runs. The cmdlet is not run.

    Required?                    false
    Position?                    named
    Default value                false
    Accept pipeline input?       false
    Accept wildcard characters?  false

Syntax

Install-ADDSForest [-SkipPreChecks] -DomainName <String> [-SafeModeAdministratorPassword <SecureString>] [-CreateDnsDelegation] [-DatabasePath <String>] [-DnsDelegationCredential <PSCredential>] [-NoDnsOnNetwork] [-DomainMode <DomainMode>] [-DomainNetbiosName <String>] [-ForestMode <ForestMode>] [-InstallDns] [-LogPath <String>] [-NoRebootOnCompletion] [-SkipAutoConfigureDns] [-SysvolPath <String>] [-Force] [-WhatIf] [-Confirm] [<CommonParameters>]

Notes
By default, the DNS Server service is installed when you create a new forest. It is strongly recommended that you install and use the Windows DNS Server to support the needs for DNS name resolution in your Active Directory deployment. You do not need to specifically include the -InstallDNS to install it.

————————– EXAMPLE 1 ————————–
C:\PS>Install-ADDSForest -DomainName “Dehli.TOSSolution.com” -InstallDNS
Installs a new forest named Dehli.TOSSolution.com, causes the user to be prompted to provide and confirm the Directory Services Restore Mode (DSRM) password and specifies a DNS server should also be installed during the forest installation process.

————————– EXAMPLE 2 ————————–
C:\PS>Install-ADDSForest -DomainName Dehli.TOSSolution.com -CreateDNSDelegation -DomainMode Win2008R2 -ForestMode Win2008R2 -DatabasePath “d:\NTDS” -SysvolPath “d:\SYSVOL” -LogPath “e:\Logs”
Installs a new forest named Dehli.TOSSolution.com, creates a DNS delegation in the TOSSolution.com domain, sets domain functional level to Windows Server 2008 R2 and sets forest functional level to Windows Server 2008, installs the Active Directory database and SYSVOL on the D:\ drive, installs the log files on the E:\ drive and has the server automatically restart after AD DS installation is complete and prompts the user to provide and confirm the Directory Services Restore Mode (DSRM) password.

You can check the Version, CommandType and Source of this cmdlet by giving below command.

Get-Command Install-ADDSForest

Get-Command Install-ADDSForest powershell script command cmdlet

You can also read about
. Install-ADDSDomain
. Test-ADDSForestInstallation

Click on this Link for an Single place where you get all the PowerShell cmdlet sorted based on the modules.

You can also refer other blogs on PowerShell at link

You can also refer other blogs on Microsoft at link

And also if you required any technology you want to learn, let us know below we will publish them in our site http://tossolution.com/

Like our page in Facebook and follow us for New technical information.

References are taken from Microsoft

Leave a Reply

Your email address will not be published. Required fields are marked *