Exchange report email [Answered]RSS

1 reply

Last post Jun 28, 2015 10:16 PM by Bharath A.G

  • Exchange report email

    Jun 26, 2015 06:22 AM|saintsdt|LINK


    Not sure if this is the right place to discuss this, but I'm trying to create a report with mount point free space on two servers and DAG whitespace.

    For mount points I have this script:

    $servernames = servername

    Get-WmiObject -computer $servernames win32_volume|where-object {$_.caption -ne $null -and $_.label -ne “System Reserved” -and $_.drivetype -eq 3}|select-object __SERVER,Name,

    @{Name="Capacity(GB)";expression={[math]::round(($_.Capacity/ 1073741824),2)}},

    @{Name="FreeSpace(GB)";expression={[math]::round(($_.FreeSpace / 1073741824),2)}},

    @{Name="Free(%)";expression={[math]::round(((($_.FreeSpace / 1073741824)/($_.Capacity / 1073741824)) * 100),0)}}

    and for exchange dag information I use this

    Get-MailboxDatabase -Status dag01* | select name,@{Name="InUse";Expression={$_.DatabaseSize- $_.AvailableNewMailboxSpace }} | select name,{$_.InUse.toGB()} | sort-object name

    First question is how do I report the mount points script to two servers, I've tried adding two names to $servernames but that doesnt work.

    Second question is how do I add both together so I can email the script out.

    Thanks for looking and sorry again if on the wrong forum!

  • Re: Exchange report email

    Jun 28, 2015 10:16 PM|Bharath A.G|LINK

    Yes. You posted this in wrong forum.I suggest you to post this in powershell forum where you can get better assistance for your problem.
    Power shell forum -

    Mark as answer if this helped you :)