从PowerShell错误添加一个新的Exchange 2013邮箱

我试图通过Powershell添加一个新的邮箱,我得到以下错误:

#New-ADUser -Name AreallyTest -SamAccountName AreallyTest -AccountPassword (ConvertTo-SecureString Password1234 -AsPlainText -Force) -Enabled:$true -Company land -HomeDrive Z: -ChangePasswordAtLogon:$true -Path 'cn=DC01,DC=internal,DC=land,DC=edu'| Enable-Mailbox -Identity Novell\AreallyTest -Alias Novell\AreallyTest New-ADUser : Directory object not found At line:1 char:1 + New-ADUser -Name AreallyTest -SamAccountName AreallyTest -AccountPassword(Conve ...+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ~~~ + CategoryInfo : ObjectNotFound: (CN=AreallyTest,...=land,DC=edu:String) [New-ADUser], ADIdentityNotFoundException + FullyQualifiedErrorId : ActiveDirectoryCmdlet:Microsoft.ActiveDirectory.Management.ADIdentityNotFoundException,Microsoft.ActiveDirectory.Management.Commands.NewADUser 

如果我试图通过它自己添加邮箱,我得到这个错误(它正在寻找。内部)

 #Enable-Mailbox -Identity Novell\AreallyTest -Alias AreallyTest Enable-Mailbox : The operation couldn't be performed because object'Novell\AreallyTest' couldn't be found on 'DC01.internal.land.edu'.At line:1 char:1+ Enable-Mailbox -Identity Novell\AreallyTest -Alias AreallyTest+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + CategoryInfo :NotSpecified: (:) [Enable-Mailbox], ManagementObjectNotFoundException + FullyQualifiedErrorId : [Server=EXCH01,RequestId=cf8213cd-ea66-4b9a-97e1-fde49f78e5cb,TimeStamp=10/15/2014 8:59:14 PM] [FailureCategory=Cmdlet-ManagementObjectNotFoundException] 3B4E2313,Microsoft.Exchange.Management.Rec ipientTasks.EnableMailbox 

我很确定错误是从我没有添加用户创build.internal,但我不确定如何初始化该字段。 (也可能是其他的东西)

如何在Powershell中正确添加用户邮箱或摆脱此错误?

你在使用PowerShell或Exchange控制台吗? 即使您将交换工具导入到Powershell中,添加邮箱function也不起作用(我从来没有这样做)。 对于“添加邮箱”,您只能使用交换控制台。