• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 1644
  • Last Modified:

Monitor POP3 seesions in powershell

Hi,
I have an two exchange servers, one holding Mailbox role and CAS -non secure (no TLS) for POP3 use. The other server has only the CAS role with TLS ebabled for secure  POP3 use.
The problem is that id like to see when and whom is holding a session with each of the exchange servers  -and for how mutch time. how would i do this with powershell?
0
Elad-a
Asked:
Elad-a
  • 3
  • 3
1 Solution
 
Chris DentPowerShell DeveloperCommented:

Hmm you may have to enable protocol logging on the POP3 service. Not aware of any way to show you the current active connections (bear in mind that POP3 connections are relatively short duration anyway).

Not aware of a command you can use to enable the logging either, you have to head to the configuration file here:

C:\Program Files\Microsoft\Exchange Server\ClientAccess\PopImap

If you open Microsoft.Exchange.Pop3.exe.config you should be able to find an entry like this:

            <add key="ProtocolLog" value="false" />

Change false to true, modify the path if you wish. Once done, restart the POP3 service.

With all that you should be able to use PowerShell to parse the log file and return the information you're after. I don't use POP3 here, so I can't tell you much about it, but if you get the log and need help post a sample and a description of what you want from it and we can take it from there.

Chris
0
 
Elad-aAuthor Commented:
Is there a specific place to inject that key into the file?
The Microsoft.Exchange.Pop3.exe.config looks very formatted i would not like to kill it..
Once i enable Protocol logging, where would the log file be created at?
0
 
Chris DentPowerShell DeveloperCommented:

> Is there a specific place to inject that key into the file?

Yes, it's set to false by default and a search should come up with that line. Just change the value to "true".

The path to the log file is directly beneath that one :)

Chris
0
Ultimate Tool Kit for Technology Solution Provider

Broken down into practical pointers and step-by-step instructions, the IT Service Excellence Tool Kit delivers expert advice for technology solution providers. Get your free copy now.

 
Elad-aAuthor Commented:
Is it ok to change the path to the log files ?
I would have a great deal of connections per sec' that id need to follow and i dont want to clutter the C drive of my server....
Thanks for your help Chris.. :-)
0
 
Chris DentPowerShell DeveloperCommented:

> Is it ok to change the path to the log files ?

Sure :)

If the log files are dealt with in the same way as the rest of the protocol logs they will keep themselves within a 250Mb total size limit.

Keep an eye on it for a while, make sure that really is the case. There's little documentation on those which is quite annoying. No idea why they didn't make the logging options available in the command shell.

Chris
0
 
Elad-aAuthor Commented:
Thanks Chris!
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Cloud Class® Course: SQL Server Core 2016

This course will introduce you to SQL Server Core 2016, as well as teach you about SSMS, data tools, installation, server configuration, using Management Studio, and writing and executing queries.

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