Microsoft KB Archive/323354

= How To Log System Monitor Data to SQL Server in Windows Server 2003 =

Article ID: 323354

Article Last Modified on 12/3/2007

-

APPLIES TO


 * Microsoft Windows Server 2003, Datacenter Edition (32-bit x86)
 * Microsoft Windows Server 2003, Enterprise Edition (32-bit x86)
 * Microsoft Windows Server 2003, Standard Edition (32-bit x86)
 * Microsoft Windows Server 2003, Web Edition
 * Microsoft Windows Server 2003, 64-Bit Datacenter Edition
 * Microsoft Windows Server 2003, Enterprise x64 Edition
 * Microsoft Windows Small Business Server 2003 Standard Edition
 * Microsoft Windows Small Business Server 2003 Premium Edition

-



This article was previously published under Q323354





For a Microsoft Windows XP version of this article, see 296222.

IN THIS TASK

 * SUMMARY
 * How to Create the Data Source Name (DSN) on the Client
 * How to Configure System Monitor to Log to SQL Server
 * How to Give the Correct Credentials to the Log by Using the &quot;Run As&quot; Option



SUMMARY
In Windows Server 2003, you can log data directly to a Microsoft SQL Server database. This article describes how to prepare a client computer to log data to a SQL Server database. This article does not describe how to set up and configure SQL Server or how to work with the data from SQL Server.

The new functionality in System Monitor permits you to log data to a SQL Server database by using an Open Database Connectivity (ODBC) data connection. However, this functionality is not an open ODBC adapter that you can use to log to any ODBC-compliant database.

back to the top

How to Create the Data Source Name (DSN) on the Client

 * 1) Click Start, point to Settings, click Control Panel, and then double-click Administrative Tools.
 * 2) Double-click Data Sources (ODBC), click the System DSN tab, and then click Add.
 * 3) Double-click SQL Server, type a name for this DSN, and then type a description for this DSN.
 * 4) Click the computer running SQL Server that the database resides on, and then click Next.
 * 5) Click With Windows NT authentication using the Network Login ID, and then click Next.
 * 6) Click to select the Change the Default Database to check box, click the SQL Server database that you created to function as the repository for the System Monitor data, and then click Next.
 * 7) Click OK to accept the defaults, and then click Finish.
 * 8) Click Test Data Source.

You receive a &quot;Tests completed successfully&quot; message.
 * 1) Click OK two times.

back to the top

How to Configure System Monitor to Log to SQL Server

 * 1) Click Start, click Run, type perfmon, and then press ENTER or click OK.
 * 2) Double-click Performance Logs and Alerts.
 * 3) Right-click Counter Logs, and then click New Log Settings.
 * 4) Type a name for this log, and then click OK.
 * 5) Click Add Objects to add the objects that you want to log, and then click Add.
 * 6) Enter the counters that you want to monitor, and then click Close.
 * 7) Click the Log Files tab, click SQL Database in the Log file type list, and then click Configure.
 * 8) In the System DSN box, click the DSN that you want to connect to. If you want to rename the logset, type a new name in the Logset name box.

By default, the logset uses the name of the System log.
 * 1) Click OK, and then click Apply.

back to the top

How to Give the Correct Credentials to the Log by Using the &quot;Run As&quot; Option

 * 1) Click Start, click Run, type perfmon, and then press ENTER or click OK.
 * 2) Double-click Performance Logs and Alerts.
 * 3) Double-click Counter Logs, and then double-click the logset that you created.
 * 4) Click the General tab.
 * 5) In the Run As box, type the credentials of a user who has the following:
 * 6) * The correct rights to run System Monitor
 * 7) * The correct rights to the SQL Server database (create and read)

back to the top

Additional query words: kbmgmtsvc sysmon SQL system monitor

Keywords: kbmgmtservices kbhowto kbhowtomaster KB323354

-

[mailto:TECHNET@MICROSOFT.COM Send feedback to Microsoft]

© Microsoft Corporation. All rights reserved.