Skip to main content

Get-LXCABackups

Use this cmdlet to retrieve information about all Lenovo XClarity Administrator backups or export (download) an XClarity Administrator backup (.tar file) to the local system.

Note
You cannot pipe objects to this cmdlet.

Syntax

Get-LXCABackups [-Connection LXCAConnection]
[CommonParameters]

Get-LXCABackups [-Connection LXCAConnection]
-Uuid String
[-Destination String]
[-Overwrite]
[CommonParameter]

Parameters

-Connection LXCAConnection
Specifies the connection to the Lenovo XClarity Administrator server. If no connection is specified, the result from the last Connect-LXCA cmdlet is used.
-Destination String
Specifies the directory and file name where the backup is to be saved on the local system.
  • If you specify a directory but not a file name (in other words, if the string ends with a back slash "\"), the file name that is returned by the XClarity Administrator is used.

  • If you specify a string that does not end with a backslash "\", the name after the last backslash "\" is used as the file name.

  • If the directory does not exist, it is automatically created.

-Overwrite
When specified, if the file already exists in the specified directory, the file is overwritten. The default value is false.

If not specified, and the file already exists in the specified directory, the file is not overwritten, and the System.IO.IOException: The _full_file_path_ file already exists exception is thrown.

-Uuid String
UUID of the backup to be downloaded.
CommonParameters
This cmdlet supports the following common parameters: -Verbose, -Debug, -ErrorAction, -ErrorVariable, -WarningAction, -WarningVariable, -OutBuffer, -PipelineVariable, -OutVariable. For detailed information about each common parameter, see the Microsoft PowerShell Common Parameters webpage.

Results

Examples

The following example retrieves info about all backups existing on the XClarity Administrator server.
$cred = Get-Credential
Connect-LXCA -Host "192.0.2.0" -Credential $Cred -SkipCertificateCheck

# Get information about existing backups
$backups = Get-LXCABackups

# Show all the information about the request, including result value, message (if any), and brief
# description of each backup (if any)
$backups

# Show detailed information about the existing backups.
$backups.BackupInfos

Disconnect-LXCA
The following example exports a specific backup (using the -Uuid parameter) to the local system and returns the fully-qualified path of the file. If a file with same name already exists, the existing file is replaced. The file name used for the exported file is the one that is returned by XClarity Administrator.
$cred = Get-Credential
Connect-LXCA -Host "192.0.2.0" -Credential $Cred -SkipCertificateCheck

# Get information about existing backups
$backups = Get-LXCABackups

# Use the UUID of the first backup in the BackupInfos
$file = Get-LXCABackups -Uuid $backups.BackupInfos[0].Uuid -Destination C:\LXCA\ -Overwrite
$file

Disconnect-LXCA
Connect-LXCA -Host 1.111.11.11 -Credential $cred