title: SCOM - Using Powershell MP for own scripts
body: <p>I am trying to implement a PowerShell script based on rules in SCOM 2016.
  For that, I am using the PowerShell Authoring MP from <a href="https://www.cookdown.com/scom-essentials/powershell-authoring" rel="nofollow noreferrer">cookdown</a>.</p>
  <p>I did create my own rule based on a &quot;manual&quot; from <a href="https://youtu.be/--wOzKU52JE" rel="nofollow noreferrer">Webinar</a>.</p>
  <p>My configuration (ScreenShots):<a href="https://i.stack.imgur.com/KKONc.png" rel="nofollow noreferrer">General</a>,<a href="https://i.stack.imgur.com/0ksRb.png" rel="nofollow noreferrer">Configuration</a>,<a href="https://i.stack.imgur.com/oVm50.png" rel="nofollow noreferrer">Script</a>, (Nothing special in my script, just the number of processes.)<a href="https://i.stack.imgur.com/fOQge.png" rel="nofollow noreferrer">Performance Mapper</a></p>
  <p>The schedule is set to run every 5 minutes.</p>
  <p>The Rule target is set for a single machine running Windows Server 2019.<a href="https://i.stack.imgur.com/3etLa.png" rel="nofollow noreferrer">Rule target group</a></p>
  <p>Everything is set but I do not seem to find the &quot;Proces&quot; value from a script that should be implemented to a SCOM from a $PropertyBag variable in the Performance View from Monitoring section.</p>
  <p>The SCOM 2016 is running properly, I am using it to monitor a lot of other things, (also from other servers) and everything seems to be good but PowerShell script from CookDown.</p>
  <p>I am not so sure if StackOverflow is the right place for that kind of &quot;Question&quot;, but is there anyone who can help me understand what am i doing wrong? Or maybe someone knows a better management pack for implementing PowerShell into SCOM.</p>