SQL Server Performance

SQL Server counters in perfmon

Discussion in 'Performance Tuning for DBAs' started by timingskey, Mar 17, 2003.

  1. timingskey New Member

    We have 4 development servers and 6 production servers (both environments split evenly between SQL2000 and SQL v.7). Our development servers show the SQL Server counters in perfmon. The production servers do not.

    I have tried to run the follwoing and it doesn't seem to be working:

    Run regsvr32 sqlctr80.dll from DOS command window. sqlctr80.dll is default in folder. C:program FilesMicrosoft SQL ServerMSSQLBinn.

    Or

    Perform the following steps:
    1. Open a command prompt.

    2. Run the following command to unload the SQL Server Performance Monitor counters:
    unlodctr mssqlserver

    3. Close and re-open Performance Monitor; the SQL Server counters should now have been removed from the object list.

    4. Run the following command from the command prompt to load the SQL Server performance Monitor counters again:
    lodctr c:mssql7innsqlctr.ini --- For 7.0
    lodctr C:program FilesMicrosoft SQL ServerMSSQLBinnsqlctr80.ini --- For 2000

    5. Close and re-open Performance Monitor; the SQL Server counters should now appear in the object list.

    6. If the SQL Server counters still do not appear in the object list, close Performance Monitor and stop SQL Server. Then restart SQL Server and open Performance Monitor again.



  2. satya Moderator

    Whatever steps you've defined should reload the counters. Check SQL Error log & event viewer for any information.

    Sometimes it could be permission issue, to resolve this use Regedit.exe to grant READ access to the
    following key of the target machine:

    HKEY_LOCAL_MACHINESOFTWAREMicrosoftMSSQLServerMSSQLServer

    Grant this to those wanting SQL counter access. As when granting any NT access permission, you can grant based on an individual user or a group.



    _________
    Satya SKJ
  3. timingskey New Member

    Thanks Satya.
    I see an error in the application log of the event viewer. It looks like this.

    Installing the performance counter strings for failed. The Error code is DWORD 0 of the Record Data.

    I don't understand what you said about granting permission to the registry key. Can you elaborate?
    Thanks,
    Ben

  4. timingskey New Member

    I found the problem. I was trying to run this:
    lodctr C:program FilesMicrosoft SQL ServerMSSQLBinnsqlctr80.dll

    I really needed to be runningit on the ini file
    lodctr C:program FilesMicrosoft SQL ServerMSSQLBinnsqlctr.ini --- For 2000

    My sqlctr.ini file did not have '80' at the end of the name.

    Thanks again for your help Satya.

Share This Page