locked
MP for SQL-server - incorrect monitoring RRS feed

  • Question

  • Hello,

    We decided to update the System Center Management Pack for SQL Server to version 6.4.0.0. After updating MP, in our SQL-servers (that is monitored according to MP) event viewer, began to emerge many events with EventID 22406

    SCOM 2007R2, powershell v1.0.

    Can anyone help me in solving this problem?

    If anyone can’t please help me to restore this MP for old version (for example 6.3.173.1).

     

    The event ID : 22406

     

    The PowerShell script failed with below exception

     

    System.Management.Automation.ParseException: The 'finally' keyword is not supported in this version of the language.

    At line:55 char:9

    +             finally

     <<<<    {

       at System.Management.Automation.Parser.finallyStatementRule(Tokenizer tok)

       at System.Management.Automation.Parser.statementRule(Tokenizer tok)

       at System.Management.Automation.Parser.statementListRule(Tokenizer tok)

       at System.Management.Automation.Parser.cmdletBodyRule(Tokenizer tok, Token fnName, Boolean isFilter, ParameterDeclarationNode parameters, Boolean scriptMode)

       at System.Management.Automation.Parser.functionDeclarationRule(Tokenizer tok)

       at System.Management.Automation.Parser.statementRule(Tokenizer tok)

       at System.Management.Automation.Parser.statementListRule(Tokenizer tok)

       at System.Management.Automation.Parser.cmdletBodyRule(Tokenizer tok, Token fnName, Boolean isFilter, ParameterDeclarationNode parameters, Boolean scriptMode)

       at System.Management.Automation.Parser.functionDeclarationRule(Tokenizer tok)

       at System.Management.Automation.Parser.statementRule(Tokenizer tok)

       at System.Management.Automation.Parser.statementListRule(Tokenizer tok)

       at System.Management.Automation.Parser.Parse(String input, Int32 cursorPosition)

       at System.Management.Automation.AutomationEngine.Parse(String script, Boolean interactiveCommand)

       at System.Management.Automation.ShellFunctionCommandProcessor..ctor(String script, ExecutionContext context, Boolean isFilter, Boolean useLocalScope, Boolean interactiveCommand)

       at System.Management.Automation.Runspaces.Command.CreateCommandProcessor(ExecutionContext executionContext, CommandFactory commandFactory, Boolean addToHistory)

       at System.Management.Automation.Runspaces.LocalPipeline.CreatePipelineProcessor()

       at System.Management.Automation.Runspaces.LocalPipeline.InvokeHelper()

       at System.Management.Automation.Runspaces.LocalPipeline.InvokeThreadProc()

     

     

     

    Script Name:         ActiveSessionsDataSource.ps1

     

    One or more workflows were affected by this. 

     

    Workflow name: Microsoft.SQLServer.2008.Database.ActiveSessions.Collection

    Instance name: xxx

    Instance ID: {F87EB2F7-F13F-FE4A-8E17-2FFB53FD57DE}

    Management group: xxx

     


    • Edited by Alex Kucher Wednesday, September 18, 2013 1:34 PM
    Wednesday, September 18, 2013 8:36 AM

All replies

  • System Center Operations Manager 2007 R2 and its management pack use a version of Windows PowerShell 2.0 that doesn’t support the "finally" keyword.

    http://support.microsoft.com/kb/2856250

    Please install Windows Management Framework Core package (Windows PowerShell 2.0 and WinRM 2.0)

    http://support.microsoft.com/kb/968930/en-us

    Roger

    Wednesday, September 18, 2013 8:51 AM
  • I must update the powershell only for Scom RMS or on the client machines too. Or only on the client machines that generate these alerts?

    There is some scripts on RMS writing under powershell v1.0. Will they work correctly after upgrading to powershell v.2?


    • Edited by Alex Kucher Wednesday, September 18, 2013 1:29 PM
    Wednesday, September 18, 2013 9:09 AM
  • I was wrong. The powershell v2 installed on my RMS.

    But on the client, that generates these errors, installed windows server 2008 for itanium-based Systems SP2 (powershell v1).

    I must update the powershell to v2 on these clients? If yes, can someone tell me where I can download powershell v2 for windows server 2008 for itanium-based Systems?

    Friday, September 20, 2013 6:45 AM
  • Powershell 2.0 is include n windows server 2008

    Roger

    Friday, September 20, 2013 3:38 PM
  • Please see result of the command $host.version from this client. Windows server 2008 for itanium-based Systems but the powershell version is 1.

    PS C:\Windows\System32\WindowsPowerShell\v1.0> $host.version

     

    Major  Minor  Build  Revision

    -----  -----  -----  --------

    1      0      0      0

    Monday, September 23, 2013 6:33 AM