Profiling its okay in sql server

529 views
450 views

Published on

Published in: Technology
0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total views
529
On SlideShare
0
From Embeds
0
Number of Embeds
1
Actions
Shares
0
Downloads
11
Comments
0
Likes
0
Embeds 0
No embeds

No notes for slide

Profiling its okay in sql server

  1. 1. Introduction to SQL Server Profiler<br />Jack D. Corbett<br />
  2. 2. About the Speaker <br />SQL Server DeveloperDBA Consultant<br />Worked with SQL Server since 1999<br />Regular SQLSaturday speaker<br />One of the organizers of PASS SQLRally 2011<br />
  3. 3. What is Profiler? <br />Client application on top of SQL Trace<br />SQL Trace is:<br />Method of monitoring events in SQL Server<br />Based on a set a of stored procedures for defining events to monitor, columns to return, and filters. <br />
  4. 4. Why use SQL Server Profiler?<br />It’s FREE with SQL Server!<br />It’s easy to use.<br />To analyze and determine application behaviors<br />To troubleshoot applications<br />To performance tune<br />To audit your SQL Server<br />
  5. 5. How Does Profiler Work?<br />Event Providers produce events<br />Trace Controller handles traces and marks events to be traced<br />Marked events are filtered and queued in buffers.<br />There are 2 trace providers<br />Rowset Provider – used by Profiler<br />File Provider<br />
  6. 6. Trace Architecture (from BOL) <br />
  7. 7. Security Considerations<br />Alter Trace permissions required (new to SQL Server 2005)<br />Hides passwords in Create/Alter Login<br />Encrypted code (SP’s, UDF’s, etc…) hidden.<br />
  8. 8. Accessing Profiler<br />Start –> Programs –> Microsoft SQL Server 2008 –> Performance Tools<br />In SSMS under the Tools menu.<br />
  9. 9. Demo<br />Opening Profiler <br />Connecting to a server<br />Selecting a Template<br />Saving a trace while executing<br />Add/remove events<br />Add/remove columns<br />Add/remove filters<br />
  10. 10. Demo<br />Executing a trace <br />Saving a custom template<br />Saving a completed trace<br />Re-opening a saved trace<br />Saving a trace definition<br />
  11. 11. Integrating with Perfmon Data<br />Need a PerfMon log<br />Need a saved trace with start and end time columns<br />
  12. 12. Demo <br />Integrating trace with PerfMon Data<br />
  13. 13. Performance Considerations<br />Using Profiler is more impactful than a server-side trace<br />More events and columns = more impact<br />Multiple small traces have less impact than one large trace<br />Server-side tracing to a file has minimal impact on performance – see<br />http://tinyurl.com/LinchiShea<br />
  14. 14. Resources<br />Microsoft SQL Server 2005 Unleashed<br />Inside Microsoft® SQL Server(TM) 2005: Query Tuning and Optimization <br />SQL Server 2005 Books On Line<br />http://tinyurl.com/SimpleTalkDeadlocks<br />http://tinyurl.com/DbJProfilerPart1<br />http://tinyurl.com/DbJProfilerPart2<br />http://tinyurl.com/PASSProfiler<br />
  15. 15. Contact Information<br />Blog: www.wisemanorwiseguy.com<br />Twitter: http://twitter.com/unclebiguns<br />LinkedIn: http://www.linkedin.com/in/jackcorbett<br />Email: corbett.jack@gmail.com<br />
  16. 16. Thanks for Coming!<br />Thanks for coming and I hope you learned something useful.<br />Let me know about any comments or suggestions you may have.<br />

×