NetApp Community Update
This site will enter Read Only mode on July 23 as we prepare to move to a new platform. You will still be able to view content, but posting and replying will be temporarily disabled.
We're excited to launch our new Community experience on July 30 and more information will follow soon.
Stay connected during the transition - Join our Discord community today.

Microsoft Virtualization Discussions

ERROR whne using CMDLet Add-NcCifsServer to SVM in a particular OU

PADMANTECH
3,484 Views

Hi All,

Wondering if anyone has been able to use the CMDLet Add-NcCifsServer to place a SVM in a particular Active Directory OU? I am getting the error when running the below:

$ADCred = Get-Credential -Message "Enter Active Directory account"

$SVM = "TestSVM"

Add-NcCifsServer -Name $SVM -Domain test.domain -OrganizationalUnit "OU=NetApp,OU=NonWindows,OU=Servers" -AdminCredential $ADCred -VserverContext $SVM

Error Message:

Add-NcCifsServer : Failed to create the Active Directory machine account "TestSVM". Reason: Cmd failed.

At line:1 char:1

+ Add-NcCifsServer -Name $SVM -Domain test.domain -OrganizationalUnit "OU=NetApp ...

+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

    + CategoryInfo          : InvalidOperation: (192.168.x.x:NcController) [Add-NcCifsServer], EAPIERROR

    + FullyQualifiedErrorId : ApiException,DataONTAP.C.PowerShell.SDK.Cmdlets.Cifs.AddNcCifsServer

Any help most welcome.

Kind regards,

Jason

1 REPLY 1

PADMANTECH
3,484 Views

Hi All,

I Have found a work around for this and that is the create the Computer Account in AD first:

$ADCred = Get-Credential -Message "Enter Active Directory account to join SVM to AD"

New-ADComputer -Name $SVM -Description "NetApp SVM" -Path "OU=NetApp,OU=NonWindows,OU=Servers,DC=test,DC=domain" -Credential $ADCred

Add-NcCifsServer -Name $SVM -Domain test.domain -AdminCredential $ADCred -VserverContext $SVM -Force

Kind regards,

Jason

Public