Command Shell Examples
Useful SQL Queries
December, 2009 - Jonathan Almquist on Operations Manager - Site Home - TechNet Blogs

December, 2009

  • Agents: remove configured management group or uninstall agent using command line

    I had a question today about uninstalling an agent using the command line.  The options referenced here are great for installing, configuring and modifying an agent and all possible options.  Here are some additional notes that may come in handy...
  • All groups (DW)

    Thanks to Daniel Savage for helping with this one. /* Get all groups from Data Warehouse */ USE OperationsManagerDW SELECT DISTINCT DisplayName FROM  vManagedEntity WHERE (ManagedEntityTypeRowId IN                   ...
  • Monitor the operations database grooming procedure

    UPDATE: Monitoring the operational database grooming procedure is now included in the SCOM management pack since version 6.1.7672.0. I will keep this post up as an example of how to create a monitor based on a script that queries a database. Often...
  • Groups and related information

    Return state of a group foreach($a in get-monitoringobjectgroup){if($a.DisplayName -eq " group name "){$a.HealthState}} Return contained instances of a group and state of each instance foreach ($group in get-monitoringobjectGroup) {if($group...
  • Group members (DW)

    /* Return Health Service instances hosting one or more instances contained in system.group */ USE OperationsManagerDW SELECT vManagedEntity.DisplayName AS Computer FROM  vManagedEntity INNER JOIN               ...
  • Monitor the operations database grooming procedure (v2)

    UPDATE: Monitoring the operational database grooming procedure is now included in the SCOM management pack since version 6.1.7672.0. I will keep this post up as an example of how to create a monitor based on a script that queries a database. Okay,...
  • Command Shell Tab Expansion Delay

    A few months ago, after re-installing my workstation operating system and getting all my applications and tools loaded, I fire up Operations Manager Command Shell.  Since I use the tab expansion function frequently, I noticed immediately that for...
  • Event data, views and grooming

    Every day I have a number of fleeting thoughts that I hope every Operations Manager administrator knows.  With all the emerging blogs about Operations Manager over the past year offering up a wealth of knowledge, sometimes I assume the majority of...
  • Table size and record count

    This was initially published by Kevin , and Steve added row count.  I just changed the column names and posted it here for easy access to customers I work with.  Anytime I engage in a tuning effort or a case where there are database issues,...