More Azure Goodies

Azure
Microsoft keeps sneaking little things under the door for Windows Azure SQL Database. This time it's a couple of new views, a system view and a Dynamic Management View (DMV); sys.resource_stats and sys.dm_operation_stats. But, I also learned another fun fact, not all this stuff rolls out at the same speed. For example, if I run sys.resource_stats on a database on a server located in the North Central US data center, the output looks like this: But, if I run the same query against the same view with a database in a data center in East Asia (I experiment with where I put things), it looks like this (click on it to expand it, probably want to do that into a second tab or window so you can refer to it…
Read More

Monitoring Structure Changes

Azure
Most everyone I know works with environments that are carefully controlled and structured. All changes go through rigorous testing and full documentation. Absolutely nothing happens in a production environment that hasn't been thought through, discussed, planned for and written down. But, there are a few, a very few, who work in a slightly different kind of environment that they refer to as "the real world." In this "real world" changes to a production environment can happen without approval, planning or testing. Scary, right? There's good news for these poor benighted souls. Red Gate is testing out a new piece of software called SQL Lighthouse. It's meant to monitor your systems for changes so that you know what has happened and when in case you don't have a good source control…
Read More

How to Tell Your Windows Azure SQL Database Moved

Azure
The very concept of the Windows Azure SQL Database (WASD) is predicated on the up-time created by having three active copies of your database. Should there be a hardware or software failure that would cause the primary replica to go down, your database gets moved to one of the secondary replicas which has been maintaining a copy of the data from the primary replica. In theory, the worst thing that happens is that you have to retry a query. In fact, building that sort of resilience into your code is a pretty fundamental aspect of working with WASD. I was asked the question, how do you tell if your database has been moved between replicas. I didn't have a complete answer, so I set out to find one. The first, more obvious…
Read More

Guest Blog

SQL Server
I was given the opportunity to put together a guest blog post for the MVP blog. I did a little something on determining whether or not you have high memory use through the use of a DMO. Check it out.
Read More

Deadlock Monitoring

T-SQL
There are four different ways you can get information about deadlocks in your system. These are: traceflag 1204 traceflag 1222 trace events extended events For years I’ve been pushing traceflag 1222 as the best of the lot. Well, that’s over. I’ve been learning more and more about extended events and I’m currently in love with xml_deadlock_report event. Why? Simple, it has everything that traceflag 1222 has, but there are two glorious things about it. First, it’s not going to be filling up my error log with, for the error log, noise. Seriously. As much as I liked the information displayed from traceflag 1222, I didn’t like what it did to the log, but I saw it as a necessary evil. Second, it’s XML baby! That means you can set up…
Read More

Extended Events Data

Uncategorized
I’ve been working quite a bit over the last week or so with extended events in Denali. The sheer magnitude of what you can do with extended events is just becoming clear to me. The interesting thing though is how much the basics are similar to trace. Similar mind you, not the same. For example, the best way to gather trace data is to output it to a file and then read the file into a table for later querying. It’s the same with extended events. There’s even a function that acts as a table: SELECT * FROM sys.fn_xe_file_target_read_file ('C:\APath\Query Performance Tuning*.xel', NULL, NULL, NULL); This can take advantage of roll-over files just like the old function used for traces. You can also provide offsets to read a sub-set of…
Read More

Life/Work Balance

SQL Server, Tools
Technology, especially information technology, is the greatest thing to ever happen to mankind, freeing us from toil and drudgery. Technology, especially information technology, is a pernicious evil taking over our lives forcing us to work harder and longer. Depending on the time of day, the day of the week, my mood, my wife’s mood, or the direction the wind is blowing, either of these statements could be true. The fact is, I love technology and I do have to wrestle with keeping it from taking over my life, but only because I have so much fun with the toys that technology brings. You want to know how much I love toys, ask me about my Droid sometime. Pull up a chair. We’re going to be here a while. The trick…
Read More

Buy vs. Build

PowerShell, Tools
It's the classic question faced by everyone in Information Services. I know how to do this and I could build software to do it, but I'm a lazy b_____d so I'd rather just pick up a piece of software that does it for me. I love working for large companies because I can usually get them to purchase stuff so that I can loll around stuffing my face all day instead of doing actual work. Unfortunately, not everyone can afford to pick up Microsoft's Operations Manager or Idera's Diagnostic Manager. But you still need to monitor your servers. With buy eliminated, that leaves build. Which, is where this excellent blog post by Laerte Junior comes in. He lays out how to build a wrapper around calls to get Performan Counter…
Read More

Confio Ignite: Part II

Tools
I'm continuing to evaluate Confio's Ignite database monitoring tool. I've had it collecting data on a couple of production servers for about a week now. Based on what I've seen so far, it's looking like a pretty good piece of software. Breaking with the usual tradition, I'm going to talk about the things I'm not crazy about with the software, before I start singing its praises. The first thing, that I thought was missing, but is actually just hard to find, is the ability to look at the query information that Ignite collects, broken down by database. It looks like you should be able to get to it by looking at the Databases tab, but instead you have to first drill down into a time-period, then select specific databases within that time period,…
Read More

Confio Ignite: First Impressions

SQL Server
One of the national sponsors for SQL Satuday is Confio Software. Just because they sponsor SQL Saturday, it's worth checking out their product, but they also host the speaker's dinner at these events. So, having eaten off their dime, I felt obligated to take a look. I'm glad I did. Confio Ignite is a monitoring software that keeps real-time and historical track of the performance of your SQL Server (and Oracle and DB2) database servers. It's focus is on wait states and queues, a very common method for troubleshooting performance. You can get a trial download from their web site to run for a couple of weeks yourself. Everyone's first impression of a software, after the web site of course, is when go to do the install. The install routine for Ignite was very…
Read More