Solved

Powershell scripts to document Exchange 2010 Enviroment

Posted on 2010-08-18
7
1,056 Views
Last Modified: 2012-05-10
Looking for a script or scripts that will help document roles, database and log paths, cas array name, owa fqdn, and build numbers.
Database size, mailbox statistics

Thanks,
Mark
0
Comment
Question by:markpalinux
  • 5
  • 2
7 Comments
 
LVL 32

Accepted Solution

by:
endital1097 earned 500 total points
ID: 33463936
Get-ExchangeServer | Select Name,ServerRole,AdminDisplayVersion
Get-MailboxDatabase | Select Name,EdbFilePath,LogFolderPath
Get-ClientAccessArray | Select Name,Site,Fqdn
Get-OwaVirtualDirectory | Select ExternalUrl
0
 
LVL 32

Assisted Solution

by:endital1097
endital1097 earned 500 total points
ID: 33463950
Get-Mailbox -ResultSize unlimited | Get-MailboxStatistics | Select DisplayName,ItemCount,TotalItemSize
0
 
LVL 32

Assisted Solution

by:endital1097
endital1097 earned 500 total points
ID: 33463960
to get database file size
$servers = Get-MailboxServer
foreach($s in $servers)
{	$db = Get-MailboxDatabase -Server $s
	foreach ($objItem in $db)
	{	$edbfilepath = $objItem.edbfilepath
		$path = "`\`\" + $s + "`\" + $objItem.EdbFilePath.DriveName.Remove(1).ToString() + "$"+ $objItem.EdbFilePath.PathName.Remove(0,2)
		$dbsize = Get-ChildItem $path
		$dbsize = "{0:N2}" -f ($dbsize.Length/1024MB)
	    $ReturnedObj = New-Object PSObject
	    $ReturnedObj | Add-Member NoteProperty -Name "Server\StorageGroup\Database" -Value $objItem.Identity
	    $ReturnedObj | Add-Member NoteProperty -Name "Size (GB)" -Value $dbsize
	    Write-Output $ReturnedObj

	}
}

Open in new window

0
Does Powershell have you tied up in knots?

Managing Active Directory does not always have to be complicated.  If you are spending more time trying instead of doing, then it's time to look at something else. For nearly 20 years, AD admins around the world have used one tool for day-to-day AD management: Hyena. Discover why

 
LVL 15

Author Comment

by:markpalinux
ID: 33464988


I guess that was too easy....

how can I document database limits and message size limits?

Thanks
0
 
LVL 32

Assisted Solution

by:endital1097
endital1097 earned 500 total points
ID: 33465019
Database quotas
Get-MailboxDatabase | ft Name,*Quota
0
 
LVL 32

Assisted Solution

by:endital1097
endital1097 earned 500 total points
ID: 33465035
Get-TransportConfig | Select MaxReceiveSize,MaxSendSize
Get-SendConnector | Select Name,MaxMessageSize
Get-ReceiveConnector | Select Name,MaxMessageSize
0
 
LVL 15

Author Closing Comment

by:markpalinux
ID: 33581021
Great! Thanks.
0

Featured Post

Has Powershell sent you back into the Stone Age?

If managing Active Directory using Windows Powershell® is making you feel like you stepped back in time, you are not alone.  For nearly 20 years, AD admins around the world have used one tool for day-to-day AD management: Hyena. Discover why.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Lotus Notes – formerly IBM Notes – is an email client application, while IBM Domino (earlier Lotus Domino) is an email server. The client possesses a set of features that are even more advanced as compared to that of Outlook. Likewise, IBM Domino is…
In-place Upgrading Dirsync to Azure AD Connect
In this video we show how to create an Accepted Domain in Exchange 2013. We show this process by using the Exchange Admin Center. Log into Exchange Admin Center.: First we need to log into the Exchange Admin Center. Navigate to the Mail Flow >> Ac…
The video tutorial explains the basics of the Exchange server Database Availability groups. The components of this video include: 1. Automatic Failover 2. Failover Clustering 3. Active Manager

830 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question