交换 powershell :获取默认范围之外的邮箱

发布于 2024-07-11 00:47:58 字数 211 浏览 4 评论 0原文

如何在当前域的当前默认范围之外运行 cmdlet“get-mailbox”?

当我运行 get-mailbox -OrganizationalUnit bob.com/bobsage 时 我收到一条错误消息: 获取邮箱:请求的搜索根“rss.com/rsstoilet”不在当前默认范围“ens.com”中。 无法在当前默认范围之外执行搜索。

提前致谢

how do you run the cmdlet "get-mailbox" outside the current default scope of the current domain?

When I run get-mailbox -OrganizationalUnit bob.com/bobsage
I get an error message saying:
Get-mailbox: The requested search root 'rss.com/rsstoilet' is not in the current default scope 'ens.com'. Cannot perform searches outside the current default scope.

thanks in advance

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(3

来世叙缘 2024-07-18 00:47:58

尝试设置此全局变量:

$AdminSessionADSettings.ViewEntireForest = $True

或使用Set-ADServerSettings -ViewEntireForest $True

或在 cmdlet 级别设置:

Get-邮箱-IgnoreDefaultScope

Try to set this global variable:

$AdminSessionADSettings.ViewEntireForest = $True

Or use Set-ADServerSettings -ViewEntireForest $True

Or set it on a cmdlet level:

Get-Mailbox -IgnoreDefaultScope

天涯沦落人 2024-07-18 00:47:58

我非常确定错误消息是准确的 - 它无法在当前默认范围之外执行搜索。 您需要更改运行命令的范围。

I'm pretty sure the error message is accurate - it cannot perform searches outside the current default scope. You would need to change the scope you're running the command in.

临风闻羌笛 2024-07-18 00:47:58

如果使用第二个选项 (-ignoredefaultscope),请确保将对象的 DN 作为参数传递给 -Identity。

例如: Get-Mailbox -IgnoreDefaultScope -Identity "cn=用户名,ou=ouname,dc=域名,dc=com"

谢谢,
西塔拉姆·帕玛蒂

www.techibee.com

If you use the second option(-ignoredefaultscope), make sure to pass the DN of the object as a parameter to -Identity.

ex: Get-Mailbox -IgnoreDefaultScope -Identity "cn=username,ou=ouname,dc=domainname,dc=com"

Thanks,
Sitaram Pamarthi

www.techibee.com

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文