New-LMDeviceGroup
Syntax
Section titled “Syntax”GroupId
Section titled “GroupId”New-LMDeviceGroup -Name <String> [-Description <String>] [-Properties <Hashtable>] [-Extra <Object>] [-DefaultCollectorId <Int32>] [-DefaultAutoBalancedCollectorGroupId <Int32>] [-DefaultCollectorGroupId <Int32>] [-DisableAlerting <Boolean>] [-EnableNetFlow <Boolean>] -ParentGroupId <Int32> [-AppliesTo <String>] [-ProgressAction <ActionPreference>] [-WhatIf] [-Confirm] [<CommonParameters>]GroupName
Section titled “GroupName”New-LMDeviceGroup -Name <String> [-Description <String>] [-Properties <Hashtable>] [-Extra <Object>] [-DefaultCollectorId <Int32>] [-DefaultAutoBalancedCollectorGroupId <Int32>] [-DefaultCollectorGroupId <Int32>] [-DisableAlerting <Boolean>] [-EnableNetFlow <Boolean>] -ParentGroupName <String> [-AppliesTo <String>] [-ProgressAction <ActionPreference>] [-WhatIf] [-Confirm] [<CommonParameters>]Description
Section titled “Description”The New-LMDeviceGroup function creates a new LogicMonitor device group with the specified parameters.
Examples
Section titled “Examples”Example 1
Section titled “Example 1”New-LMDeviceGroup -Name "MyDeviceGroup" -Description "This is a test device group" -Properties @{ "Location" = "US"; "Environment" = "Production" } -DisableAlerting $trueThis example creates a new LogicMonitor device group named “MyDeviceGroup” with a description and custom properties. Alerting is disabled for this device group.
Example 2
Section titled “Example 2”New-LMDeviceGroup -Name "ChildDeviceGroup" -ParentGroupName "ParentDeviceGroup"This example creates a new LogicMonitor device group named “ChildDeviceGroup” with a specified parent device group.
Parameters
Section titled “Parameters”The name of the device group. This parameter is mandatory.
Type: StringParameter Sets: (All)Aliases:
Required: TruePosition: NamedDefault value: NoneAccept pipeline input: FalseAccept wildcard characters: False-Description
Section titled “-Description”The description of the device group.
Type: StringParameter Sets: (All)Aliases:
Required: FalsePosition: NamedDefault value: NoneAccept pipeline input: FalseAccept wildcard characters: False-Properties
Section titled “-Properties”A hashtable of custom properties for the device group.
Type: HashtableParameter Sets: (All)Aliases:
Required: FalsePosition: NamedDefault value: NoneAccept pipeline input: FalseAccept wildcard characters: False-Extra
Section titled “-Extra”Specifies a object of extra properties for the device group. Used for LM Cloud resource groups
Type: ObjectParameter Sets: (All)Aliases:
Required: FalsePosition: NamedDefault value: NoneAccept pipeline input: FalseAccept wildcard characters: False-DefaultCollectorId
Section titled “-DefaultCollectorId”Specifies the default collector ID for the device group. Default is 0.
Type: Int32Parameter Sets: (All)Aliases:
Required: FalsePosition: NamedDefault value: 0Accept pipeline input: FalseAccept wildcard characters: False-DefaultAutoBalancedCollectorGroupId
Section titled “-DefaultAutoBalancedCollectorGroupId”Specifies the default auto-balanced collector group ID for the device group. Default is 0.
Type: Int32Parameter Sets: (All)Aliases:
Required: FalsePosition: NamedDefault value: 0Accept pipeline input: FalseAccept wildcard characters: False-DefaultCollectorGroupId
Section titled “-DefaultCollectorGroupId”Specifies the default collector group ID for the device group. Default is 0.
Type: Int32Parameter Sets: (All)Aliases:
Required: FalsePosition: NamedDefault value: 0Accept pipeline input: FalseAccept wildcard characters: False-DisableAlerting
Section titled “-DisableAlerting”Specifies whether alerting is disabled for the device group. The default value is $false.
Type: BooleanParameter Sets: (All)Aliases:
Required: FalsePosition: NamedDefault value: FalseAccept pipeline input: FalseAccept wildcard characters: False-EnableNetFlow
Section titled “-EnableNetFlow”Specifies whether NetFlow is enabled for the device group. The default value is $false.
Type: BooleanParameter Sets: (All)Aliases:
Required: FalsePosition: NamedDefault value: FalseAccept pipeline input: FalseAccept wildcard characters: False-ParentGroupId
Section titled “-ParentGroupId”The ID of the parent device group. This parameter is mandatory when using the ‘GroupId’ parameter set.
Type: Int32Parameter Sets: GroupIdAliases:
Required: TruePosition: NamedDefault value: 0Accept pipeline input: FalseAccept wildcard characters: False-ParentGroupName
Section titled “-ParentGroupName”The name of the parent device group. This parameter is mandatory when using the ‘GroupName’ parameter set.
Type: StringParameter Sets: GroupNameAliases:
Required: TruePosition: NamedDefault value: NoneAccept pipeline input: FalseAccept wildcard characters: False-AppliesTo
Section titled “-AppliesTo”The applies to value for the device group.
Type: StringParameter Sets: (All)Aliases:
Required: FalsePosition: NamedDefault value: NoneAccept pipeline input: FalseAccept wildcard characters: False-WhatIf
Section titled “-WhatIf”Shows what would happen if the cmdlet runs. The cmdlet is not run.
Type: SwitchParameterParameter Sets: (All)Aliases: wi
Required: FalsePosition: NamedDefault value: NoneAccept pipeline input: FalseAccept wildcard characters: False-Confirm
Section titled “-Confirm”Prompts you for confirmation before running the cmdlet.
Type: SwitchParameterParameter Sets: (All)Aliases: cf
Required: FalsePosition: NamedDefault value: NoneAccept pipeline input: FalseAccept wildcard characters: False-ProgressAction
Section titled “-ProgressAction”Fill ProgressAction Description
Type: ActionPreferenceParameter Sets: (All)Aliases: proga
Required: FalsePosition: NamedDefault value: NoneAccept pipeline input: FalseAccept wildcard characters: FalseCommonParameters
Section titled “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
Section titled “Inputs”None. You cannot pipe objects to this command.
Section titled “None. You cannot pipe objects to this command.”Outputs
Section titled “Outputs”Returns LogicMonitor.DeviceGroup object.
Section titled “Returns LogicMonitor.DeviceGroup object.”This function requires a valid LogicMonitor API authentication. Use Connect-LMAccount to authenticate before running this command.