Skip to content

Complete‑SqlDscImage

dscbot edited this page Oct 26, 2024 · 1 revision

SYNOPSIS

Completes the image installation of an SQL Server instance.

SYNTAX

Complete-SqlDscImage [-AcceptLicensingTerms] [-MediaPath] <String> [[-InstanceName] <String>] [-Enu]
 [[-InstanceId] <String>] [[-PBEngSvcAccount] <String>] [[-PBEngSvcPassword] <SecureString>]
 [[-PBEngSvcStartupType] <String>] [[-PBStartPortRange] <UInt16>] [[-PBEndPortRange] <UInt16>] [-PBScaleOut]
 [[-ProductKey] <String>] [[-AgtSvcAccount] <String>] [[-AgtSvcPassword] <SecureString>]
 [[-AgtSvcStartupType] <String>] [[-BrowserSvcStartupType] <String>] [-EnableRanU]
 [[-InstallSqlDataDir] <String>] [[-SqlBackupDir] <String>] [[-SecurityMode] <String>]
 [[-SAPwd] <SecureString>] [[-SqlCollation] <String>] [[-SqlSvcAccount] <String>]
 [[-SqlSvcPassword] <SecureString>] [[-SqlSvcStartupType] <String>] [[-SqlSysAdminAccounts] <String[]>]
 [[-SqlTempDbDir] <String>] [[-SqlTempDbLogDir] <String>] [[-SqlTempDbFileCount] <UInt16>]
 [[-SqlTempDbFileSize] <UInt16>] [[-SqlTempDbFileGrowth] <UInt16>] [[-SqlTempDbLogFileSize] <UInt16>]
 [[-SqlTempDbLogFileGrowth] <UInt16>] [[-SqlUserDbDir] <String>] [[-SqlUserDbLogDir] <String>]
 [[-FileStreamLevel] <UInt16>] [[-FileStreamShareName] <String>] [-NpEnabled] [-TcpEnabled]
 [[-RsInstallMode] <String>] [[-RSSvcAccount] <String>] [[-RSSvcPassword] <SecureString>]
 [[-RSSvcStartupType] <String>] [-ProductCoveredBySA] [[-Timeout] <UInt32>] [-Force]
 [-WhatIf] [-Confirm] [<CommonParameters>]

DESCRIPTION

Completes the image installation of an SQL Server instance that was prepared using Install-SqlDscServer with the parameter -PrepareImage.

See the link in the commands help for information on each parameter. The link points to SQL Server command line setup documentation.

EXAMPLES

EXAMPLE 1

Complete-SqlDscImage -AcceptLicensingTerms -MediaPath 'E:\'

Completes the image installation of the SQL Server default instance that was prepared using Install-SqlDscServer with the parameter -PrepareImage.

PARAMETERS

-AcceptLicensingTerms

Required parameter to be able to run unattended install. By specifying this parameter you acknowledge the acceptance all license terms and notices for the specified features, the terms and notices that the Microsoft SQL Server setup executable normally ask for.

Type: SwitchParameter
Parameter Sets: (All)
Aliases:

Required: True
Position: Named
Default value: False
Accept pipeline input: False
Accept wildcard characters: False

-AgtSvcAccount

See the notes section for more information.

Type: String
Parameter Sets: (All)
Aliases:

Required: False
Position: 10
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-AgtSvcPassword

See the notes section for more information.

Type: SecureString
Parameter Sets: (All)
Aliases:

Required: False
Position: 11
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-AgtSvcStartupType

See the notes section for more information.

Type: String
Parameter Sets: (All)
Aliases:

Required: False
Position: 12
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-BrowserSvcStartupType

See the notes section for more information.

Type: String
Parameter Sets: (All)
Aliases:

Required: False
Position: 13
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-EnableRanU

See the notes section for more information.

Type: SwitchParameter
Parameter Sets: (All)
Aliases:

Required: False
Position: Named
Default value: False
Accept pipeline input: False
Accept wildcard characters: False

-Enu

See the notes section for more information.

Type: SwitchParameter
Parameter Sets: (All)
Aliases:

Required: False
Position: Named
Default value: False
Accept pipeline input: False
Accept wildcard characters: False

-FileStreamLevel

See the notes section for more information.

Type: UInt16
Parameter Sets: (All)
Aliases:

Required: False
Position: 32
Default value: 0
Accept pipeline input: False
Accept wildcard characters: False

-FileStreamShareName

See the notes section for more information.

Type: String
Parameter Sets: (All)
Aliases:

Required: False
Position: 33
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-Force

If specified the command will not ask for confirmation. Same as if Confirm:$false is used.

Type: SwitchParameter
Parameter Sets: (All)
Aliases:

Required: False
Position: Named
Default value: False
Accept pipeline input: False
Accept wildcard characters: False

-InstallSqlDataDir

See the notes section for more information.

Type: String
Parameter Sets: (All)
Aliases:

Required: False
Position: 14
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-InstanceId

See the notes section for more information.

Type: String
Parameter Sets: (All)
Aliases:

Required: False
Position: 3
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-InstanceName

See the notes section for more information.

Type: String
Parameter Sets: (All)
Aliases:

Required: False
Position: 2
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-MediaPath

Specifies the path where to find the SQL Server installation media. On this path the SQL Server setup executable must be found.

Type: String
Parameter Sets: (All)
Aliases:

Required: True
Position: 1
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-NpEnabled

See the notes section for more information.

Type: SwitchParameter
Parameter Sets: (All)
Aliases:

Required: False
Position: Named
Default value: False
Accept pipeline input: False
Accept wildcard characters: False

-PBEndPortRange

See the notes section for more information.

Type: UInt16
Parameter Sets: (All)
Aliases:

Required: False
Position: 8
Default value: 0
Accept pipeline input: False
Accept wildcard characters: False

-PBEngSvcAccount

See the notes section for more information.

Type: String
Parameter Sets: (All)
Aliases:

Required: False
Position: 4
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-PBEngSvcPassword

See the notes section for more information.

Type: SecureString
Parameter Sets: (All)
Aliases:

Required: False
Position: 5
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-PBEngSvcStartupType

See the notes section for more information.

Type: String
Parameter Sets: (All)
Aliases:

Required: False
Position: 6
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-PBScaleOut

See the notes section for more information.

Type: SwitchParameter
Parameter Sets: (All)
Aliases:

Required: False
Position: Named
Default value: False
Accept pipeline input: False
Accept wildcard characters: False

-PBStartPortRange

See the notes section for more information.

Type: UInt16
Parameter Sets: (All)
Aliases:

Required: False
Position: 7
Default value: 0
Accept pipeline input: False
Accept wildcard characters: False

-ProductCoveredBySA

See the notes section for more information.

Type: SwitchParameter
Parameter Sets: (All)
Aliases:

Required: False
Position: Named
Default value: False
Accept pipeline input: False
Accept wildcard characters: False

-ProductKey

See the notes section for more information.

Type: String
Parameter Sets: (All)
Aliases:

Required: False
Position: 9
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-RsInstallMode

See the notes section for more information.

Type: String
Parameter Sets: (All)
Aliases:

Required: False
Position: 34
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-RSSvcAccount

See the notes section for more information.

Type: String
Parameter Sets: (All)
Aliases:

Required: False
Position: 35
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-RSSvcPassword

See the notes section for more information.

Type: SecureString
Parameter Sets: (All)
Aliases:

Required: False
Position: 36
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-RSSvcStartupType

See the notes section for more information.

Type: String
Parameter Sets: (All)
Aliases:

Required: False
Position: 37
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-SAPwd

See the notes section for more information.

Type: SecureString
Parameter Sets: (All)
Aliases:

Required: False
Position: 17
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-SecurityMode

See the notes section for more information.

Type: String
Parameter Sets: (All)
Aliases:

Required: False
Position: 16
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-SqlBackupDir

See the notes section for more information.

Type: String
Parameter Sets: (All)
Aliases:

Required: False
Position: 15
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-SqlCollation

See the notes section for more information.

Type: String
Parameter Sets: (All)
Aliases:

Required: False
Position: 18
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-SqlSvcAccount

See the notes section for more information.

Type: String
Parameter Sets: (All)
Aliases:

Required: False
Position: 19
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-SqlSvcPassword

See the notes section for more information.

Type: SecureString
Parameter Sets: (All)
Aliases:

Required: False
Position: 20
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-SqlSvcStartupType

See the notes section for more information.

Type: String
Parameter Sets: (All)
Aliases:

Required: False
Position: 21
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-SqlSysAdminAccounts

See the notes section for more information.

Type: String[]
Parameter Sets: (All)
Aliases:

Required: False
Position: 22
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-SqlTempDbDir

See the notes section for more information.

Type: String
Parameter Sets: (All)
Aliases:

Required: False
Position: 23
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-SqlTempDbFileCount

See the notes section for more information.

Type: UInt16
Parameter Sets: (All)
Aliases:

Required: False
Position: 25
Default value: 0
Accept pipeline input: False
Accept wildcard characters: False

-SqlTempDbFileGrowth

See the notes section for more information.

Type: UInt16
Parameter Sets: (All)
Aliases:

Required: False
Position: 27
Default value: 0
Accept pipeline input: False
Accept wildcard characters: False

-SqlTempDbFileSize

See the notes section for more information.

Type: UInt16
Parameter Sets: (All)
Aliases:

Required: False
Position: 26
Default value: 0
Accept pipeline input: False
Accept wildcard characters: False

-SqlTempDbLogDir

See the notes section for more information.

Type: String
Parameter Sets: (All)
Aliases:

Required: False
Position: 24
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-SqlTempDbLogFileGrowth

See the notes section for more information.

Type: UInt16
Parameter Sets: (All)
Aliases:

Required: False
Position: 29
Default value: 0
Accept pipeline input: False
Accept wildcard characters: False

-SqlTempDbLogFileSize

See the notes section for more information.

Type: UInt16
Parameter Sets: (All)
Aliases:

Required: False
Position: 28
Default value: 0
Accept pipeline input: False
Accept wildcard characters: False

-SqlUserDbDir

See the notes section for more information.

Type: String
Parameter Sets: (All)
Aliases:

Required: False
Position: 30
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-SqlUserDbLogDir

See the notes section for more information.

Type: String
Parameter Sets: (All)
Aliases:

Required: False
Position: 31
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-TcpEnabled

See the notes section for more information.

Type: SwitchParameter
Parameter Sets: (All)
Aliases:

Required: False
Position: Named
Default value: False
Accept pipeline input: False
Accept wildcard characters: False

-Timeout

Specifies how long to wait for the setup process to finish. Default value is 7200 seconds (2 hours). If the setup process does not finish before this time, an exception will be thrown.

Type: UInt32
Parameter Sets: (All)
Aliases:

Required: False
Position: 38
Default value: 7200
Accept pipeline input: False
Accept wildcard characters: False

-Confirm

Prompts you for confirmation before running the cmdlet.

Type: SwitchParameter
Parameter Sets: (All)
Aliases: cf

Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-WhatIf

Shows what would happen if the cmdlet runs. The cmdlet is not run.

Type: SwitchParameter
Parameter Sets: (All)
Aliases: wi

Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

CommonParameters

This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.

INPUTS

OUTPUTS

None.

NOTES

The parameters are intentionally not described since it would take a lot of effort to keep them up to date. Instead there is a link that points to the SQL Server command line setup documentation which will stay relevant.

RELATED LINKS

https://docs.microsoft.com/en-us/sql/database-engine/install-windows/install-sql-server-from-the-command-prompt

Home

Commands

Resources

Usage

Clone this wiki locally