Skip to content

Latest commit

 

History

History
161 lines (122 loc) · 3.38 KB

File metadata and controls

161 lines (122 loc) · 3.38 KB
document type external help file HelpUri Locale Module Name ms.date PlatyPS schema version title
cmdlet
linuxtools-Help.xml
en-US
linuxtools
11/09/2025
2024-05-01
Remove-LocalGroup

Remove-LocalGroup

SYNOPSIS

Remove a local security group

SYNTAX

__AllParameterSets

Remove-LocalGroup [-Name] <string> [-Force] [-WhatIf] [-Confirm] [<CommonParameters>]

ALIASES

This cmdlet has the following aliases, {{Insert list of aliases}}

DESCRIPTION

Remove a local security group

EXAMPLES

EXAMPLE 1

Remove-LocalGroup -Name "mygroup" Removes the local security group named "mygroup"

EXAMPLE 2

Remove-LocalGroup -Name "mygroup" -Force Removes the local security group named "mygroup" even if users have it as their primary group

EXAMPLE 3

Remove-LocalGroup -Name "mygroup" -WhatIf This example shows what would happen if the group "mygroup" were to be removed without actually executing the command.

PARAMETERS

-Confirm

Prompts you for confirmation before running the cmdlet.

Type: System.Management.Automation.SwitchParameter
DefaultValue: ''
SupportsWildcards: false
Aliases:
- cf
ParameterSets:
- Name: (All)
  Position: Named
  IsRequired: false
  ValueFromPipeline: false
  ValueFromPipelineByPropertyName: false
  ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''

-Force

Forces the removal of the group even if users have it as their primary group.

Type: System.Management.Automation.SwitchParameter
DefaultValue: False
SupportsWildcards: false
Aliases: []
ParameterSets:
- Name: (All)
  Position: Named
  IsRequired: false
  ValueFromPipeline: false
  ValueFromPipelineByPropertyName: false
  ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''

-Name

Name of the group to remove

Type: System.String
DefaultValue: ''
SupportsWildcards: false
Aliases: []
ParameterSets:
- Name: (All)
  Position: 0
  IsRequired: true
  ValueFromPipeline: false
  ValueFromPipelineByPropertyName: false
  ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''

-WhatIf

Runs the command in a mode that only reports what would happen without performing the actions.

Type: System.Management.Automation.SwitchParameter
DefaultValue: ''
SupportsWildcards: false
Aliases:
- wi
ParameterSets:
- Name: (All)
  Position: Named
  IsRequired: false
  ValueFromPipeline: false
  ValueFromPipelineByPropertyName: false
  ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''

CommonParameters

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

INPUTS

OUTPUTS

NOTES

This function requires superuser privileges to remove a group. Ensure that you have the necessary permissions to run this command. Use with caution, as it will permanently delete the group and its members. Be sure to back up any important data before proceeding.

RELATED LINKS