Home > Software design >  Creating child OU inside another child Ou
Creating child OU inside another child Ou

Time:06-22

I'm trying to create a AD structure (non-GUI approach) and I keep getting this error:

Example

The previous commands I used are:

New-ADOrganizationalUnit -Name "Sales Gurus" -Path "DC=wsa, DC=lab"

New-ADOrganizationalUnit -Name "Sofia" -Path "OU=Sales Gurus, DC=wsa, DC=lab"

CodePudding user response:

As pointed out in the comments, you have a path issue. You create these two OUs:

OU=Sales Gurus, DC=wsa, DC=lab
OU=Sofia, OU=Sales Gurus, DC=wsa, DC=lab

Then try to create

OU=Supervisors, OU=Sofia, DC=wsa, DC=lab

That path is missing "OU=Sales Gurus" when compared to the previous paths created. Your command of:

New-ADOrganizationalUnit -Name "Supervisors" -Path "OU=Sofia, DC=wsa, DC=lab"

Should include the Sales Gurus OU as well like this:

New-ADOrganizationalUnit -Name "Supervisors" -Path "OU=Sofia, OU=Sales Gurus, DC=wsa, DC=lab"
  • Related