Stefan Stranger's Lifestream - tagged with sql-2005 http://www.stranger.nl/feed en-us http://blogs.law.harvard.edu/tech/rss Sweetcron stefan@stranger.nl OpsMgr SQL Full or Differential Backup Check http://www.stranger.nl/items/view/5637

I helped a customer creating a OpsMgr Monitor for checking if the there has been a SQL Full or Differential Backup within a specified number of hours. David Scheltens created the SQL query. Remark: Please read information on System Center Central for more info on this article. This is how you could create this kind of monitor in your own environment. Steps:

Create a Timed Script Two State Monitor. Save Monitor in other MP than Default MP. Give the Monitor a Name, like “Custom – SQL Full or Differential Backup Check”. Target the Monitor to SQL Database. Select a suitable Parent Monitor like Availability. Disable Monitor (enable by an Override later). Configure how often this Monitor should run (default is 15 mins, but you could change this depending on the time your SQL backups run) Copy script from here. The script uses three parameters (or arguments) - Param 0: The SQL connection string for the server - Param 1: The Database to use - Param 2: The threshold (in hours) to use Configure the Parameters.    Configure Unhealthy Expression. Property[@Name='NumHours'] Greater Than 1 (threshold when your backup should have been run)
Configure Healthy Expression Property[@Name='NumHours'] Less than or equal to 1 (threshold when your backup should have been run)
Configure Health.
Configure Alerting I used the Reason, BackupType and Number of Hours in the Alert Description.
Open the MP XML file and change the data type in the xml configuration from string to integer. Since making this change, the alerts and state changes seems to occur when at the correct time.More info here: (thanks to Daniele Grandini)<ErrorExpression>             <SimpleExpression>               <ValueExpression>                 <XPathQuery Type="Integer">Property[@Name='NumHours'] </XPathQuery>               </ValueExpression>               <Operator>Greater</Operator>               <ValueExpression>                 <Value Type="Integer">20</Value>               </ValueExpression>             </SimpleExpression>           </ErrorExpression>           <SuccessExpression>             <SimpleExpression>               <ValueExpression>                 <XPathQuery Type="Integer">Property[@Name='NumHours'] </XPathQuery>               </ValueExpression>               <Operator>LessEqual</Operator>               <ValueExpression>                 <Value Type="Integer">20</Value>               </ValueExpression>             </SimpleExpression>           </SuccessExpression> 15. Enable the Monitor via an Override. Remark: You may need to Use a Run As Account with the right permission for this Monitor. Result:

Some time ago I created a Tutorial How to Associate a Run As Account to a Monitor.  

In Operations Manager 2007, Run As Profiles and Run As Accounts are used to select users with the privileges needed for running rules, tasks, and monitors. Management Pack authors create a rule, task, or monitor, and then associate it with a Run As Profile. The named Run As Profile is imported along with the Management Pack into Operations Manager 2007. The Operations Manager 2007 administrator creates a named Run As Account and specifies users and groups. The administrator then adds the Run As Account to the Run As Profile and specifies the target computers that the account should run on. The goal in this short tutorial is to create a Timed Script Two State Monitor and associate a run as account to this monitor and save it all in a Management Pack. The Timed Script Two State Monitor is a vbscript that uses WMI to check if BizTalk orchestrations are not started. I’ve got some great help from Jakub Oleksy (http://blogs.msdn.com/jakuboleksy/default.aspx) and Steve Wilson (http://www.authormps.com/dnn/) You can download the tutorial here.

]]>
Thu, 21 Jan 2010 23:56:00 +0100 http://www.stranger.nl/items/view/5637
OpsMgr SQL Full or Differential Backup Check http://www.stranger.nl/items/view/1761

I helped a customer creating a OpsMgr Monitor for checking if the there has been a SQL Full or Differential Backup within a specified number of hours. David Scheltens created the SQL query. This is how you could create this kind of monitor in your own environment. Steps:

Create a Timed Script Two State Monitor. Save Monitor in other MP than Default MP. Give the Monitor a Name, like “Custom – SQL Full or Differential Backup Check”. Target the Monitor to SQL Database. Select a suitable Parent Monitor like Availability. Disable Monitor (enable by an Override later). Configure how often this Monitor should run (default is 15 mins, but you could change this depending on the time your SQL backups run) Copy script from here. The script uses three parameters (or arguments) - Param 0: The SQL connection string for the server - Param 1: The Database to use - Param 2: The threshold (in hours) to use Configure the Parameters.    Configure Unhealthy Expression. Property[@Name='NumHours'] Greater Than 1 (threshold when your backup should have been run)
Configure Healthy Expression Property[@Name='NumHours'] Less than or equal to 1 (threshold when your backup should have been run)
Configure Health.
Configure Alerting I used the Reason, BackupType and Number of Hours in the Alert Description.
Enable the Monitor via an Override. Remark: You may need to Use a Run As Account with the right permission for this Monitor. Result:

]]>
Mon, 02 Feb 2009 21:05:00 +0100 http://www.stranger.nl/items/view/1761
Creating a Business Intelligence framework for data collected by OpsMgr 2007 http://www.stranger.nl/items/view/60

Source: Operations Manager Product Team Blog Yesterday the PerformancePoint team released a sample solution that shows how to build cubes from the Operations Manager DW and then build balanced IT scorecards using Office PerformancePoint server from these cubes. Product Requirements: Microsoft SQL Server 2005 (database engine, Analysis Services, Integration Services) – system requirements here Office SharePoint Server 2007 – system requirements here OR Windows SharePoint Services 3.0 SP1 – system requirements here Windows SharePoint Services 3.0 SP1) Office PerformancePoint Server 2007 – system requirements here System Center Operations Manager 2007 – system requirements here Windows Server® 2003 Components of the framework, and the flow of data from source data to the finished dashboards:   System Center Operations Manager managed servers collect monitor state and performance counter data saved in the Operations Manager operational database. The Operations Manager data warehouse (OperationsManagerDW) collects data from the operational database. Data is pre-aggregated and stored in tables architected to support production reporting requirements. Steps one and two are out-of-the box processes for Operations Manager. The Business Intelligence framework begins with the following step, the population of a new Business Intelligence database. Collect the Source Data - A small subset of data in the Operations Manager data warehouse is transformed and loaded into the Business Intelligence framework database (OperationsManagerBusiness Intelligence). This database contains the star schemas for the Analysis Services OLAP cubes. Build OLAP Cubes - Analysis Services OLAP cubes are built and processed from data stored in the OperationsManagerBI database. Put it All Together - Create Office PerformancePoint Server 2007 Dashboards, Scorecards, and Analytic Reports - Data from the OLAP cubes is used to populate PerformancePoint Server scorecards, dashboards, and analytic reports. These components are originally created using the Office PerformancePoint Server 2007 Dashboard Designer. Deploy Dashboards, Scorecards, and Analytic Reports in SharePoint - Scorecards, dashboards, and analytic reports are made available to the user community through SharePoint Server. Once the scorecards, dashboards, and analytic reports are initially created and deployed, they should not need to be deployed again – these components will be refreshed as new data becomes available in the OLAP cubes. The solution can be found on http://www.microsoft.com/BI and http://www.microsoft.com/PerformancePoint

]]>
Thu, 18 Sep 2008 21:14:00 +0200 http://www.stranger.nl/items/view/60