Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 222
  • Last Modified:

Querying Exchange server with Powershell

I have this command below, that retrieves information about databases on existing Exchange server which are 2 Exchange server, how can I run the same command to retrieve information about just one specific server

Thanks

Get-MailboxDatabase -Status | select ServerName,Name,DatabaseSize,EdbFilePath,LogFolderPath
0
jskfan
Asked:
jskfan
  • 4
  • 3
1 Solution
 
Alan HardistyCo-OwnerCommented:
Use the following:

Get-MailboxDatabase -Server Servername -Status | select ServerName,Name,DatabaseSize,EdbFilePath,LogFolderPath
0
 
jskfanAuthor Commented:
I tried it , it still gives me the output for both servers

Get-MailboxDatabase -Server Servername -Status | select ServerName,Name,DatabaseSize,EdbFilePath,LogFolderPath
0
 
Alan HardistyCo-OwnerCommented:
You are presumably replacing 'servername' with the name of the server you want to query I hope?
0
Simplify Active Directory Administration

Administration of Active Directory does not have to be hard.  Too often what should be a simple task is made more difficult than it needs to be.The solution?  Hyena from SystemTools Software.  With ease-of-use as well as powerful importing and bulk updating capabilities.

 
jskfanAuthor Commented:
yes...
But it displays the output for all mailbox databases server
0
 
Alan HardistyCo-OwnerCommented:
It shouldn't!

What version of Exchange do you have?
0
 
jskfanAuthor Commented:
Get-MailboxDatabase -Server Servername -Status | select ServerName,Name,DatabaseSize,EdbFilePath,LogFolderPath

I found out the only thing I need to change is the ServerName in the Select Statement.

ex:
Get-MailboxDatabase  -Status | select Exchangeserve1 ,DatabaseSize,EdbFilePath,LogFolderPath
0
 
jskfanAuthor Commented:
Thanks
0

Featured Post

Problems using Powershell and Active Directory?

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

  • 4
  • 3
Tackle projects and never again get stuck behind a technical roadblock.
Join Now