我需要我们所有云托管邮箱中的LastLogonTime。谷歌告诉我
Get-Mailbox | Get-MailboxStatisticsGet-邮箱当前返回2172个邮箱,但当返回整个对象以获取-邮箱统计时,它在59个邮箱上出现错误:指定的邮箱"Firstname Lastname“不是唯一的。
对于其中的一些邮箱,我确实可以找到一个带有重复DisplayName的邮箱,但不是所有的邮箱。
因此,有些邮箱没有有效的Get-邮箱统计结果。但是,当我从ExchangeGuid询问时,就会返回记录。也就是说。
Get-MailboxStatistics -Identity 7045326a-5c0f-4a84-aa0c-ceb$$$$c67fe当我修改我的脚本来循环邮箱结果和查询每个邮箱的统计信息时,我会得到(明显的)响应:请求没有在服务器上得到服务。你的请求太频繁了。请等几分钟,然后再试一次。
所以..。我的问题是。如何将每个Get-邮箱记录的ExchangeGuid传输到?
Get-Mailbox -ResultSize 5 | Select-Object ExchangeGuid | Get-MailboxStatistics返回:
The input object cannot be bound to any parameters for the command either because the command does not take pipeline in put or the input and its properties do not match any of the parameters that take pipeline input.
+ CategoryInfo : InvalidArgument: (@{ExchangeGuid=...5-684390d4a758}:PSObject) [Get-MailboxStatistics], P arameterBindingException
+ FullyQualifiedErrorId : InputObjectNotBound,Get-MailboxStatistics
+ PSComputerName : outlook.office365.com发布于 2017-11-15 07:29:29
您可以尝试使用UPN (用户主体名称),它是唯一的:
get-mailbox -ResultSize 5 |select -expand userprincipalname |Get-MailboxStatistics
https://stackoverflow.com/questions/47301342
复制相似问题