All Apps and Add-ons

Error being generated by Exchange App

Brian_Osburn
Builder

I'm getting a bunch of powershell errors with the exchange app (mainly around the Mailbox Store). This is on Exchange 2007 that hosts the public folders - really need to get this resolved as I've got high demand for this information.

get-publicfolderstats.ps1:
Exchange server "PWEXCHPUB01" was not found. Please make sure you have typed it correctly.
At C:\Program Files\SplunkUniversalForwarder\etc\apps\TA-Exchange-2007-MailboxStore\bin\powershell\get-publicfolderstats.ps1:40 char:36
+ $dblist = (Get-PublicFolderDatabase  <<<< -server $env:ComputerName -Status|Where-Object { $_.Mounted -eq "True" })
Get-PublicFolderStatistics : A parameter cannot be found that matches parameter name 'ResultSize'.
At C:\Program Files\SplunkUniversalForwarder\etc\apps\TA-Exchange-2007-MailboxStore\bin\powershell\get-publicfolderstats.ps1:47 char:61
+     Foreach ($folder in (Get-PublicFolderStatistics -ResultSize  <<<< Unlimited | Where-Object { $_.DatabaseName -eq $db.Name })) {


get-hoststats.ps1:
New-Object : Cannot find type [Collections.Generic.List[string]]: make sure the assembly containing this type is loaded.
At C:\Program Files\SplunkUniversalForwarder\etc\apps\TA-Exchange-2007-MailboxStore\bin\powershell\get-hoststats.ps1:31 char:31
+     $ServicesRunning = New-Object  <<<< Collections.Generic.List[string]
New-Object : Cannot find type [Collections.Generic.List[string]]: make sure the assembly containing this type is loaded.
At C:\Program Files\SplunkUniversalForwarder\etc\apps\TA-Exchange-2007-MailboxStore\bin\powershell\get-hoststats.ps1:32 char:34
+     $ServicesNotRunning = New-Object  <<<< Collections.Generic.List[string]

You cannot call a method on a null-valued expression.
At C:\Program Files\SplunkUniversalForwarder\etc\apps\TA-Exchange-2007-MailboxStore\bin\powershell\get-hoststats.ps1:38 char:24
+             $ServicesRunning.Add( <<<< $proc)
You cannot call a method on a null-valued expression.
At C:\Program Files\SplunkUniversalForwarder\etc\apps\TA-Exchange-2007-MailboxStore\bin\powershell\get-hoststats.ps1:38 char:24
+             $ServicesRunning.Add( <<<< $proc)


get-databasestats.ps1
The term 'Get-Counter' is not recognized as a cmdlet, function, operable program, or script file. Verify the term and try again.
At C:\Program Files\SplunkUniversalForwarder\etc\apps\TA-Exchange-2007-MailboxStore\bin\powershell\get-databasestats.ps1:12 char:14
+     (Get-Counter  <<<< "\LogicalDisk($Drive)\% Free Space").CounterSamples[0]
.CookedValue

Brian_Osburn
Builder

Posting this in a new answer box, since I can't seem to get the formatting commands to work in comments..

Upgraded to V2, everything but the get-publicfolderstats.ps1 works now.

When I run the following command, I get this error:

[PS] C:\Program Files\SplunkUniversalForwarder\etc\apps\TA-Exchange-2007-Mailb
Store\bin\powershell>Get-PublicFolderDatabase -server $env:ComputerName

Get-PublicFolderDatabase : Exchange server "PWEXCHPUB01" was not found. Please
make sure you have typed it correctly.
At line:1 char:25
+ Get-PublicFolderDatabase <<<<  -server $env:ComputerName
    + CategoryInfo          : NotSpecified: (0:Int32) [Get-PublicFolderDatabas
   e], ManagementObjectNotFoundException
    + FullyQualifiedErrorId : 5882B319,Microsoft.Exchange.Management.SystemCon
   figurationTasks.GetPublicFolderDatabase

Is there something I"m missing on the configuration side of our public folders?

ahall_splunk
Splunk Employee
Splunk Employee

Hi Brian,

Unfortunately, it looks like you have a problem with Powershell, and those are tricky to diagnose since they depend on who the Splunk instance is running as, what permissions are in effect, if the Powershell KB fixes are in place, and a host of other things that are outside our control. My first step would be to ensure that you are running the latest service pack for Windows 2003, and that your server is allowed to run Powershell local scripts (generally done through GPO). Open up a Powershell prompt (found under Accessories) and make sure you can run basic Powershell commands like Get-Counter (see http://technet.microsoft.com/en-us/library/dd367892.aspx)

You can run each of the Powershell scripts independently of the Splunk instance by running them from within an Exchange Management Shell - just change directory to the bin\powershell directory within the TA and run them. They will produce more debugging output that can potentially identify the error.

Failing all that, contact our Support group (assuming you have a support contract) and they will be happy to assist.

Brian_Osburn
Builder

Looks like we're running powershell version 1 on these boxes. My Admin is going to see about getting it updated..

0 Karma

Brian_Osburn
Builder

We're actually running Windows 2008 SP2.

I'll touch base with my wintel admins and then reach out if necessary..

Unfortunately I'm not so windows server literate 😛

0 Karma
Career Survey
First 500 qualified respondents will receive a $20 gift card! Tell us about your professional Splunk journey.

Can’t make it to .conf25? Join us online!

Get Updates on the Splunk Community!

Can’t Make It to Boston? Stream .conf25 and Learn with Haya Husain

Boston may be buzzing this September with Splunk University and .conf25, but you don’t have to pack a bag to ...

Splunk Lantern’s Guide to The Most Popular .conf25 Sessions

Splunk Lantern is a Splunk customer success center that provides advice from Splunk experts on valuable data ...

Unlock What’s Next: The Splunk Cloud Platform at .conf25

In just a few days, Boston will be buzzing as the Splunk team and thousands of community members come together ...