Skip to content


Import License File to the License Server


Import-LicLicenseFile [-AdminAddress] <String> -FileName <String> [-Overwrite] [-CertHash <String>] [-Credentials <PSCredential>] [<CommonParameters>]

Detailed Description

Imports the file specified in the Filename parameter to the specified License Server, with an optional parameter to overwrite an existing file.


Name Description Required? Pipeline Input Default Value
AdminAddress Specifies the Web Services for Licensing address of the License Server that the PowerShell Snap-in will connect to. Retrieve this address with Get-LicLocation. true true (ByValue)
FileName Full Path to the Location of the License File. The Filename will be the same on the License Server. true false
Overwrite Switch to specify whether or not to overwrite an existing file with the same filename. false false false
CertHash Specifies the hash of the License Server certificate needing verification. false false
Credentials Specifies the username/password to be authenticated with the License Server. false false

Input Type

Return Values


If the command fails, one of the following errors is returned.
Error Codes
Succesfully Imported the File to License Server
License File Already Exists, use Overwrite flag
Failed to write the license file
Failed to open file for writing
License File Begin Imported is not a Valid License File
File Being Imported Does not Exist
An unexpected error occurred. For more details, see the Windows event logs on the controller.


Example 1

C:\PS>Import-LicLicenseFile -AdminAddress -FileName "C:\Demo.lic" -OverwriteImports the license file on the License Server and overwrites the license Demo.lic if already present.

Was this article helpful?