Skip to main content

Get-LXC1DiscoveredDevice

This cmdlet returns a list of all discovered devices from Lenovo XClarity One portal.

Note
You cannot pipe objects to this cmdlet.

Syntax

Get-LXC1DiscoveredDevice 
[-ManagementHub String]
[-Name String[]]
[-NameSearchType String]
[-IPAddresses String[]]
[-IPAddressesSearchType String]
[-Product String[]]
[-ProductSearchType String]
[-SerialNumber String[]]
[-SerialNumbeSearchType String]
[-Anywhere String[]]
[-AnywhereSearchType String]
[-Connection LXC1Connection]
[CommonParameter]
Parameters
-ManagementHub String
Specifies the name or IP address of the management hub. All devices that were discovered by any of the specified patterns are returned.
Note
The name or IP address must exactly match the management hub properties.
-Name String[]
Specifies one or more full or partial device names, separated by comma. All discovered devices that match any of the specified patterns based on the operator (-NameSearchType parameter) are returned.

-NameSearchType String
Specifies the operator to use for patterns in the -Name parameter. This can be one of the following values.
  • contains (default)
  • notContains
  • equals
  • notEquals

If -Name is not specified, this parameter is ignored.

-IPAddress String[]
Specifies one or more full or partial device IP addresses, separated by comma. All discovered devices that match any of the specified patterns based on the operator (-IPAddressSearchType parameter) are returned.
-IPAddressSearchType String
Specifies the operator to use for patterns in the -IPAddress parameter. This can be one of the following values.
  • contains (default)
  • notContains
  • equals
  • notEquals

If -IPAddress is not specified, this parameter is ignored.

-Product String[]
Specifies one or more full or partial product names, separated by a comma. All discovered devices that match any of the specified patterns based on the operator (-ProductSearchType parameter) are returned.
-ProductSearchType String
Specifies the operator to use for patterns in the -Product parameter. This can be one of the following values.
  • contains (default)
  • notContains
  • equals
  • notEquals

If -Product is not specified, this parameter is ignored.

-SerialNumber String[]
Specifies one or more full or partial serial numbers, separated by a comma. All discovered devices that match any of the specified patterns based on the operator -SerialNumbeSearchType parameter) are returned.
-SerialNumbeSearchType String
Specifies the operator to use for patterns in the -SerialNumber parameter. This can be one of the following values.
  • contains (default)
  • notContains
  • equals
  • notEquals

If -SerialNumber is not specified, this parameter is ignored.

-Anywhere String[]
Specifies one or more full or partial text found in any discovered-device attributes, separated by a comma. All discovered devices that match any of the specified patterns based on the operator (-AnywhereSearchType parameter) are returned.
-AnywhereSearchType String
Specifies the operator to use for patterns in the -Anywhere parameter. This can be one of the following values.
  • contains (default)
  • notContains
  • equals
  • notEquals

If -Anywhere is not specified, this parameter is ignored.

-Connection LXC1Connection
Specifies the connection to the XClarity One server. If no connection is specified, the result from the last Connect-LXC1 cmdlet is used.
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 returns information about all discovered devices.
param ( 
[Parameter(Mandatory = $true)] [ValidateNotNullOrEmpty()] $ClientID,
[Parameter(Mandatory = $true)] [ValidateNotNullOrEmpty()] $UserSecret
)

$securePassword = ConvertTo-SecureString $UserSecret -AsPlainText -Force
$cred = New-Object System.Management.Automation.PSCredential($ClientID, $securePassword))
$hostOnprem = "192.0.2.0"

$connection = Connect-LXC1 -PortalAddress $hostOnprem `
-Credential $cred `
-PortalType cloud `
-SkipCertificateCheck

$result = Get-LXC1DiscoveredDevice

$result|Format-List
The following example returns information about all discovered devices by the specified management hub and with the specified product type.
param ( 
[Parameter(Mandatory = $true)] [ValidateNotNullOrEmpty()] $ClientID,
[Parameter(Mandatory = $true)] [ValidateNotNullOrEmpty()] $UserSecret
)

$securePassword = ConvertTo-SecureString $UserSecret -AsPlainText -Force
$cred = New-Object System.Management.Automation.PSCredential($ClientID, $securePassword))
$hostOnprem = "192.0.2.0"

$connection = Connect-LXC1 -PortalAddress $hostOnprem `
-Credential $cred `
-PortalType cloud `
-SkipCertificateCheck

$result = Get-LXC1DiscoveredDevice -ManagementHub "hub_o1" `
-Product 7d7a `
-ProductSearchType equals

$result|Format-List