TestimoX

API Reference

Command

New-ADXOrganizationalUnit

Namespace ADPlayground.PowerShell
Outputs
ADPlayground.DirectoryMutationResult

Creates a new Active Directory organizational unit.

Examples

Authored help example

Example 1: Preview a new workload OU beneath the managed servers branch


New-ADXOrganizationalUnit -Name 'SQL-Production' -ParentDistinguishedName 'OU=Servers,OU=Managed,DC=contoso,DC=com' -Description 'Production SQL Server computer objects' -WhatIf
        

Example 2: Create an OU for branch-office workstations


New-ADXOrganizationalUnit -Name 'Workstations-KRK' -ParentDistinguishedName 'OU=Endpoints,DC=contoso,DC=com' -Description 'Krakow office workstation accounts'
        

Common Parameters

This command supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable.

For more information, see about_CommonParameters.

Syntax

New-ADXOrganizationalUnit -Name <string> -ParentDistinguishedName <string> [-Description <string>] [<CommonParameters>]
#

Parameters

Name string requiredposition: 0pipeline: false
Gets or sets the OU name.
ParentDistinguishedName string requiredposition: 1pipeline: falsealiases: OrganizationalUnit
Gets or sets the parent distinguished name where the OU should be created.
Description string optionalposition: namedpipeline: false
Gets or sets the optional OU description.

Outputs

ADPlayground.DirectoryMutationResult