Home > Articles > Data > SQL Server

SQL Server Reference Guide

Hosted by

Quest Software's Spotlight on SQL Server

Last updated Mar 28, 2003.

The basic purpose of a DBA position can be summarized in two statements: Keep the database going, and keep it going fast. To be sure, a DBA does a lot more that day-to-day, but these two goals are the most visible parts of what we do.

For a DBA to keep the database up and running with superior performance takes good hardware, good application development, and lots of experience. Quest Software's Spotlight on SQL Server claims to help DBAs by providing lots of information about a SQL Server's performance, as well as the fixes to many problems. In this article, I'll give the tool a test drive to see if the software lives up to these claims.

Spotlight for SQL Server is part of a larger software family, including Spotlight for operating systems such as Linux and Windows servers; application servers such as Microsoft Exchange and Siebel; and Spotlight for Oracle. The purpose is to monitor various objects and counters on your servers and provide useful tuning information and suggestions.

NOTE

When multiple Spotlight packages are installed on the same system they integrate into a single interface. In fact, some of them complement each other, such as Spotlight for Windows and Spotlight for SQL Server. Having both packages installed gives information and recommendations based on all the objects and counters it collects and how they're affecting each other.

You can install the software directly on a server or on a workstation. I usually install monitoring software on a workstation, since I don't like a lot of drivers and DLL's cluttering up my production servers. If you following this mantra as well. just remember that you need a decent network connection to the servers you're going to monitor. Spotlight doesn't send a lot of data back and forth, but you don't want a slow connection skewing the networking results.

Spotlight's installation is a basic "Next...Next...Finish" kind of affair, with nothing of major importance to watch out for. After the installation, you double-click the Spotlight icon, and then double-click "New Connection."

Figure 108Figure 108

Because Spotlight is part of a larger suite, you'll see several server types to monitor. Select the type of server to monitor, and you'll be asked to provide a connection name. This name will show up underneath an icon in the main panel the next time you start the program.

You're then asked if you want to create shortcuts to Spotlight in Enterprise Manager or Query Analyzer. Once you make your choice, type in your connection credentials.

Figure 109Figure 109

There's a very important concept on this panel, and if you're not careful, you can get into trouble here. Notice that I've selected <New Database> in the middle box. This database isn't the database that you want to monitor, as you might think. The database you specify here is one that Spotlight will use to hold its counters. If you select a current database, Spotlight will create lots of tables in it.

Once you've specified <New Database> in the database box, the connection is created. Double-clicking the icon for your connection's name attempts to access the server. If the database you specified is <New Database>, you'll be presented with a panel that creates it for you.

Figure 110Figure 110

Click "OK" and the software automatically create the database and populate it. I point this out because if you're like me, you might be tempted to jump right in to a package and start using it. Doing that without following the steps above could generate a lot of tables, views, and stored procedures in your production database. The important concept here that will keep you out of trouble is to remember that Spotlight monitors a server, not a database.

After you've made it through that process, Spotlight connects to the server and presents you with a panel that specifies your collection options.

Figure 111Figure 111

The defaults shown are best for normal monitoring, since the other options cause a heavier load on the server. There are times when you need them, but be aware that they cause a performance impact.

Once you've made your selections, click "OK" to start the monitoring.

Figure 112Figure 112

In the first few minutes of use (or whatever period you designate) the system begins a calibration phase. This time allows enough information to accumulate in the program's tables to make the statistics useful. (Just to be clear, when I say statistics here, I mean statistical measurements, not SQL statistics.)

And that really defines how this tool works. It collects various measurements and places them in a few tables. The front-end of the tool then presents those measurements to you, along with some helpful information to interpret them.

Figure 113Figure 113

The presentation begins at a high-level at the "home page." Active graphs, lights, and bars are set at various thresholds. When these thresholds are violated, the system turns the objects yellow, then red, then flashing red. You can change these thresholds to reflect what you see as a problem, but the defaults are usually accurate. (You can see I'm having a bad day on this test system!)

This home page is just a high-level view of the server. Right-clicking on almost any graphic brings up a context-sensitive menu that includes two of the most powerful features of Spotlight: the "What's this" and the "Show Details" items.

Figure 114Figure 114

The "What's this" menu item brings up a description of the object you're looking at, and often provides information about where the counter should be. This is a great tool when you're first starting out, or if you don't do much work with SQL's performance counters.

Figure 115Figure 115

The "Show Details" menu item is part of the drill down feature of Spotlight, and allows you to navigate to the details of the object. You can right-click almost anything. The level of detail you can access really shows the power of the software.

You can see here I've drilled into the Paging Activity of my system, and several tabs show more information about this object.

Figure 116Figure 116

Once in this detailed view, right-clicking the graph once again shows the "What's this" and "Show Details" menu items. This allows you do find even more information about the graph's detailed output.

Notice that I've also been switched to the "SoW" (Spotlight on Windows) menu item on the far left. The reason is that the counter I'm interested in isn't a SQL counter at all; it belongs to the operating system. Spotlight demonstrates the platform on which SQL runs has a direct effect on database performance.

There's a ton of information just like this, but to demonstrate the feature I use most often I've jumped over to the "home page" again, selected the "SQL Processes" area, and then right-clicked the "Total" object. Several of my counters were flashing red, so I then right-clicked and selected the "Sessions" menu item, which accesses the panel that shows what the users are doing to my system.

Once inside, I looked for the session with the most CPU and I/O values. As you can see here, someone has created an infinite loop and is tying up the system, and is also creating a few unwanted locks.

Figure 117Figure 117

The text on larger procedures is truncated at times, but it's most often enough to locate the offender.

We've only scratched the surface of this tool, and there's certainly plenty more to it. You can scan the logs on a system; check the drive space; set alarms; and so forth. A suggestions pane provides lots of information about how to configure your server for optimal performance.

Tool Misuse

There are two ways (at least) to misuse this tool. One is to blindly trust the information the program provides. You should always confirm any suspected issues with a thorough investigation, and back up any conclusions you draw with facts. Never make snap corrections, and always have an exit strategy for any changes you implement.

The second way to misuse Spotlight is to misunderstand what it does. The name sort of gives it away; it's a spotlight into your server. You have to be looking at the screen to see any issues, since Spotlight doesn't trend the data. You can save snapshots, but you can't go back in time to see the counters. This tool is not used for long-term analysis of the server.

If you keep the two caveats in mind, you should definitely check out this software. I've used and recommended it for years, and it can really pinpoint issues that are occurring or will occur. You can download an eval copy from the company's Web site.