6 Replies Latest reply on Aug 22, 2018 6:02 AM by rajasekar

    Slack Alerts Integration Issue

    steves2k

      Hello,

       

      Props to chad.every for making these great awesome slack integration alert, everyone should definitely have a look at his scripts

      Slack Alert Integration - Overview

      I am having an issue with one of the scripts though, For some reason, it does not seem to properly send the data over to slack, in particular, the Memory Module

       

      Should like something like (Props to chad.every)

       

      2016-05-05 14_30_05-Slack - LehiSalesEngineering.png

       

      Here is the snippet below of the settings

       

      Here is the snippet of the Alert settings, For some reason it doesn't look like it is not sending the $ORIONTIME? but for all his other scripts, they work excellent, just the "MEMORY POwershel",

       

      I have attached the link of the script https://thwack.solarwinds.com/servlet/JiveServlet/downloadBody/188402-102-4-29570/

      Another pair of eyes would be appreciated

       

       

       

       

       

      Path I used from your snippet

      C:\windows\system32\windowspowershell\v1.0\powershell.exe -ExecutionPolicy unrestricted -command "C:\curl\ps\Slack_Alert_Trigger_Action_Node_Memory.ps1 '${N=SwisEntity;M=DisplayName}' '${N=SwisEntity;M=Stats.PercentMemoryUsed}' '${N=SwisEntity;M=MemoryUsed}' '${N=SwisEntity;M=TotalMemory}' '${N=SwisEntity;M=PercentMemoryUsedThreshold.IsLevel1State}' '${N=SwisEntity;M=PercentMemoryUsedThreshold.IsLevel2State}' '${N=Alerting;M=AlertDetailsUrl}' '${N=SwisEntity;M=DetailsUrl}' '${N=Alerting;M=AcknowledgeUrl}' '${N=Generic;M=DateTime;F=OriginalValue}'"

       

      From the powershell script - I Simply downloaded the link provided by your original post - The only area I have modified was the Token and Channel

          • Re: Slack Alerts Integration Issue
            chad.every

            Sorry for the delay. The script should output to a log file. I checked mine and it was blank...it you're is working then it should include what each alert variable is reporting.  it is found on your Orion server here:
            C:\ProgramData\SolarWinds\Logs

            If yours is blank too then i might need to figure out why and update the script so we can continue troubleshooting.

              • Re: Slack Alerts Integration Issue
                steves2k

                Hello,

                 

                Yes I checked the location as mentioned and is indeed blank, it looks to be outputting fine, sorry, not pushing you in anyways, i am just stumped why its parsing over like this in Slack....

                 

                [03/22/2018 14:53:51] - INFO -

                 

                Thanks

                Steve

                  • Re: Slack Alerts Integration Issue
                    chad.every

                    Looks like there is an extra alert variable in my write up. Drop this variable from the alert action

                    '${N=SwisEntity;M=TotalMemory}'

                     

                     

                    The new path should look like:

                    C:\windows\system32\windowspowershell\v1.0\powershell.exe -ExecutionPolicy unrestricted -command "C:\curl\ps\Slack_Alert_Trigger_Action_Node_Memory.ps1 '${N=SwisEntity;M=DisplayName}' '${N=SwisEntity;M=Stats.PercentMemoryUsed}' '${N=SwisEntity;M=MemoryUsed}' '${N=SwisEntity;M=PercentMemoryUsedThreshold.IsLevel1State}' '${N=SwisEntity;M=PercentMemoryUsedThreshold.IsLevel2State}' '${N=Alerting;M=AlertDetailsUrl}' '${N=SwisEntity;M=DetailsUrl}' '${N=Alerting;M=AcknowledgeUrl}' '${N=Generic;M=DateTime;F=OriginalValue}'"

                     

                     

                    It should display as follows once you do that.

                     

                    I'll update my original post with exclude it.

                    C:\windows\system32\windowspowershell\v1.0\powershell.exe -ExecutionPolicy unrestricted -command "C:\curl\ps\Slack_Alert_Trigger_Action_Node_Memory.ps1 '${N=SwisEntity;M=DisplayName}' '${N=SwisEntity;M=Stats.PercentMemoryUsed}' '${N=SwisEntity;M=MemoryUsed}' '${N=SwisEntity;M=TotalMemory}' '${N=SwisEntity;M=PercentMemoryUsedThreshold.IsLevel1State}' '${N=SwisEntity;M=PercentMemoryUsedThreshold.IsLevel2State}' '${N=Alerting;M=AlertDetailsUrl}' '${N=SwisEntity;M=DetailsUrl}' '${N=Alerting;M=AcknowledgeUrl}' '${N=Generic;M=DateTime;F=OriginalValue}'"

                    1 of 1 people found this helpful