Then I have the following script - Go to MailboxStatistics from which I go information export both get-mailbox information, and as I understand They handle different aspects of both mailboxes about which we can export information
gate-mailboxes-server server 01 -use unlimited size. Where {$ _. UseDatabaseQuotaDefaults -q $ false} | Foot DisplayName, IssueWarningQuota, ProhibitSendQuota, @ {label = "TotalItemSize (MB)."; Issue = {(Get-MailboxStatistics $ _) TotalItemSize.Value.ToMB ()}} Issue 1: Does not find any information in the TotalItemSize field when I run the script Problem 2: If I add i export-csv c:!? I get garbage any ideas
You are taking garbage on export-CSV because you are trying to export format-table data that table of the format for the selection-item business will do better
$ MBXs = get -Mailbox -Server Server01 -ResultSize Unlimited | where {. $ _UseDatabaseQuotaDefaults -eq $ false} & amp; {Foreach ($ MBXs in $ MBX) {$ MBX | Select DisplayName, IssueWarningQuota, ProhibitSendQuota, @ {label = "TotalItemSize (MB)", expression = {(Get-MailboxStatistics $ MBX) .otalItemSize.Value.ToMB ()}}}} | Export CSV mbxquotas.csv
No comments:
Post a Comment