What is this?

This knowledgebase contains questions and answers about PRTG Network Monitor and network monitoring in general.

Learn more

PRTG Network Monitor

Intuitive to Use. Easy to manage.
More than 500,000 users rely on Paessler PRTG every day. Find out how you can reduce cost, increase QoS and ease planning, as well.

Free Download

Top Tags


View all Tags

Is there any way to get the quantity (only the amount) of users in an Exchange 2016 database using a

Votes:

0

I have tried to obtain that data using powershell but it is not possible, if it works the powershell custom sensor that tells me the status (assembled or disassembled) and size, but I need the number of users .... any help is very much appreciated. greetings to all

database exchange query wmi

Created on Mar 19, 2019 2:19:13 PM



6 Replies

Votes:

0

How about using Get-Mailbox, as they should reflect the users on the Exchange Server: Get-Mailbox | Group-Object -Property:Database | Select-Object name,count Should return something like this:

Name                                    Count
----                                    -----
MB-BR-01                                   23
MB-HO-01                                  192
MB-HO-02                                  178

PRTGapi | Feature Requests | WMI Issues | SNMP Issues

Kind regards,
Stephan Linke, Tech Support Team

Created on Mar 20, 2019 11:05:08 AM by  Stephan Linke [Paessler Support]



Votes:

0

Sorry, I can not edit the question. The problem is that by remote powershell (for security) I can not execute commands, can I do the same query by WMI?

Created on Mar 20, 2019 12:55:40 PM



Votes:

0

Not that I'm aware of. What are your objections against remote Powershell if I may ask? You could allow PRTG specifically to be the only allowed host :)


PRTGapi | Feature Requests | WMI Issues | SNMP Issues

Kind regards,
Stephan Linke, Tech Support Team

Created on Mar 20, 2019 1:03:01 PM by  Stephan Linke [Paessler Support]

Last change on Mar 20, 2019 1:03:05 PM by  Stephan Linke [Paessler Support]



Votes:

0

is for a business security issue, now I'm seeing that I can do the same with powershell, export to a file and add a sensor "file" in PRTG ...

something like this

Get-MailboxStatistics –Database xxxx | ForEach {$totalItems+=$_.ItemCount} | Out-File C:\filename.txt

Created on Mar 20, 2019 1:10:26 PM



Votes:

0

You could also use the HTTP Push Data Advanced Sensor and push the data to PRTG via Invoke-WebRequest and a scheduled task on the Exchange Server :)


PRTGapi | Feature Requests | WMI Issues | SNMP Issues

Kind regards,
Stephan Linke, Tech Support Team

Created on Mar 20, 2019 1:15:53 PM by  Stephan Linke [Paessler Support]



Votes:

0

Excellent!!! i will try this

Thanks!

Created on Mar 20, 2019 1:17:45 PM




Disclaimer: The information in the Paessler Knowledge Base comes without warranty of any kind. Use at your own risk. Before applying any instructions please exercise proper system administrator housekeeping. You must make sure that a proper backup of all your data is available.