Monthly Archives: August 2012

SQLskills Immersion Training – Day 4, Index Analysis and Memory Performance Tuning

An unlimited supply of bacon is a dangerous thing.  I open up the lid on a steel container and bacon is there.  I come back 10 minutes later and the remaining bacon has reproduced. Pork is the paterfamilias of the non-vegetable proteins and bacon that replicates is the consul of pig products.

This was the best day of training for me so far.  SQLOS and memory usage is one of my favorite areas of study and Jonathan’s coverage of the topic was excellent.  I have a pretty good framework to work from having spent a lot of time studying it and the information I got today filled in some holes in my knowledge (and opened some new ones).  On Tuesday I worried that the shotgun approach to the material wasn’t good enough without some support information on how to use that material. The supporting info is what we got today.

I do feel sorry though for anyone who hasn’t taken the time to get a foundation in SQLOS and SQL Server memory management.  That was a lot of information and I don’t know how people absorbed it.  That is one of the problems when talking about a topic that is so broad where to understand A you have to understand B but to understand B you need to also understand A.  You have to start somewhere.

Kimberly completed the module on plan cache analysis and index usage.  It was good but I was distracted by the bacon supply.

Update 8/23/2012 – Here are links to each day:
Day 0
Day 1
Day 2
Day 3
Day 4
Day 5

SQLskills Immersion Training – Day 3, Query Plan Analysis, CPU Performance Tuning, Plan Cache and Index Analysis

This was my favorite day of training so far.  Most of the topics I am already very familiar with.  This isn’t a waste of time though. My learning style works by constructing a large framework of basic information then filling in that framework with more detailed and esoteric info.  I already had a very solid base in these areas and the training today helped fill in some of the blanks.

Yesterday Joe began a module teaching about query plan analysis. He continued that today teaching about the more common operators, the different join types and when they are best used and which operators may indicate you are having performance problems.  He went into depth on hash algorithms, MAX DOP and parallelism, cardinality estimation problems, and much more.  The last slide of the module was his “watch” list of things he looks for when analyzing query plans.  I’m happy to say that a lot of what I looked for is already on the list.  I’m also happy to say that I learned a few more things to look for that I hadn’t considered before or had forgotten.

Getting repetition and reinforcement of things already learned is another reason these classes are good.  Most of what is being taught, 95% at least, I’ve been exposed to before either though training classes, videos or whitepapers. But a lot of it doesn’t get absorbed the first or second time.  The repetition helps to solidify that in memory while getting some new tidbits to add to it.

Joe taught about how to troubleshoot CPU performance and did an introduction to resource governor.  This can tie into the previous module because in many cases the causes of high CPU utilization can be discovered from query plan analysis.

To end the day Kimberly began teaching a module on plan cache and index analysis.  This is a good follow up on the same material from IE1.  I took that class last year and don’t remember exactly what was taught but there appears to be lot of repeat information from IE1. It is hard for me to say what is different since it has been a year.  The info is still very good though. The repetition is obviously good since I have a ton of notes.

Like the previous modules I discovered I was already doing a lot of things they recommend but added to my knowledge and a few new tricks.  That statement appears to be the broken record of the blog this week.

Update 8/23/2012 – Here are links to each day:
Day 0
Day 1
Day 2
Day 3
Day 4
Day 5

SQLskills Immersion Training – Day 2, Waits and Queues, Extended Events and Query Plan Analysis

Jonathan finished his introduction to SQLOS with a fire hose introduction to memory management.  This is a topic I’ve been studying for the past two years. It is not easy and there is a lot to learn.  Using various sources from the interweb I’ve developed a methodology for investigating memory pressures (internal, external, VAS) and was hoping to get some more ammunition. I was initially disappointed because this seemed to simply be a collection disconnected facts and lists of DMVs but with no information about how to detect memory pressure or troubleshoot memory problems.

However, if I peek ahead in the book I see that there is an additional section on troubleshooting memory pressures, specifically internal, external and VAS.  Excellent! This is what I would have expected to see.

Paul taught about the Waits and Queues methodology of performance tuning. This included an introduction to thread scheduling in SQLOS, latches and spinlocks.  He gave some very detailed information about the four most common waits and what those really mean.  I’ve been using the Waits and Queues methodology for a couple of years now so this wasn’t new to me but there was a lot of extra information to help round out how to use this methodology better and how to not chase red herrings.

Following the Waits and Queues section was a section about Extended Events.  In short, it was a good intro.  Given how broad this topic is there is only so much one can get in a single 2 hour session.

Having some pretty good knowledge of SQLOS memory management and Waits and Queues but almost no knowledge of Extended Events I was able to gauge how well the material targets a class with a broad range of experience.  The Waits and Queues module gave me a good bit of info to add to what I already knew but also appeared to be a decent introduction for those who don’t already use the methodology.  The Extended Events module gave me a good introduction to the topic but likely had some advanced information for those in the class who have been using them for a while.  The ability to target this broad range of experience in a class is a sign of a well-developed curriculum, I believe.

The last module of the day was the first this week taught by Joe, Query Plan Analysis.  Once again I’m pleased to see that the methodology I use in analyzing query plans is much like the one Joe presented. We ran out of class time and this topic will continue on Day 3 where Joe will get into some of the more common operators.

For bonus content Glenn Berry gave an hour long presentation about how to choose the right SQL Server hardware. He talked specifically about which processors to choose, and possibly more important, which processors not to choose.

It was a long day but packed with excellent information.

Update 8/23/2012 – Here are links to each day:
Day 0
Day 1
Day 2
Day 3
Day 4
Day 5

SQLskills Immersion Training – Day 1, SQL I/O and SANs

Quick notes:

  • The food is excellent and more than you can possibly want.
  • The entire crew of SQLskills is here even though only Paul, Kimberly, Jonathan and Joe are teaching.
  • The group knows how to have fun.  I wouldn’t have paid to come here just to watch people have fun. I can go to the comedy club for that.  But if I can get quality instruction with or without fun I’ll choose fun.
  • Paul offered that once you take a class with SQLskills you have lifetime rights to email him about a problem.  Having taking a class with SQLskills I can attest that this is true.  I emailed Paul and Jonathan within the last year about two different problems and both were willing and able to help me.  Naturally, there will be a limit on how much they can do for free but they definitely pointed me in the right direction.
  • The dedication to your education is amazing.  They emphasized that if you have any question then you should definitely ask it.  And if the person you ask doesn’t know it then they will point you to someone on the crew who does.  Once again I have personal knowledge that this is true.  Last year I asked Paul a question about SQL Server memory.  He directed me to email Jonathan and within an hour Jonathan had replied with more information than I expected and 100% answered my question.

Here is the list of topics covered in this week’s training.  We covered modules 1, 2 and 3.

Last year in IE1 Paul did a brief lesson about SQL I/O.  I wanted more info about that and was disappointed I didn’t get it.  By mid-morning today I cried ‘uncle’.  I didn’t get all of the I/O information I wanted but I got more than I could absorb and links to whitepapers to read after my brain cache has been flushed.

Then Jonathan took over to talk about SSDs, RAID, SANS, storage, and related topics.  When I heard that it wasn’t just Paul and Kimberly teaching this year I was initially concerned that I wouldn’t be getting the best instruction.  That concern was misplaced.  Jonathan clearly had the knowledge to teach these topic and the impact of each on SQL Server.  I know now why they hired him.  Quote of the day from Jonathan about SQL Server performance on SANs, “SAN vendors are getting better about how they lie to you.”  It was funny. Maybe you had to be there. Maybe were all a bunch of geeks.

If you are already a SAN guy this would likely be basic info. If not this is a great introduction. An added benefit is getting to hear a bunch of SAN guys talking about SANs.  The class members already experienced with SANs engage Jonathan with questions and discussions. This adds to the education because it puts the information Jonathan is displaying on the screen into a real life scenario.  Very useful.

All-in-all a very good day.

Update 8/23/2012 – Here are links to each day:
Day 0
Day 1
Day 2
Day 3
Day 4
Day 5

SQLskills Immersion Training – Day 0, Getting There

The flight to the west coast was a bit of a drag. They don’t design airplanes for short people.  Since I’m tall it’s even worse.  I’m not afraid to fly but the thought of my body’s dissemination into the atmosphere is, well, disturbing.  Fortunately the captain had a Sullenbergeresque mustache and I was much comforted.

The first leg was fine.  On the second leg the guy in front of me immediately reclined his seat and hunched over his tray table to watch a movie.  I didn’t say a word, naturally.

Seated beside me, for four hours, was an expert on whole body health. I learned how the red dye in my M&Ms was slowly poisoning me, that milk was slowly poisoning me, that my Coca-Cola was, you guessed it, slowly poisoning me.  She whipped out her iPad and watched a new age documentary.  Then Avatar.  When she stretched and yawned it was apparent she wasn’t wearing deodorant.  I didn’t get a lecture about how the chemicals in my deodorant were killing me.  Small mercies and all that.

After landing at Sea-Tac she asked me if the flight was long for me.  Four hours squished into a space that isn’t designed to fit someone 4 inches shorter than me while being lectured about the lethality of candy corn, wishing I had bought that pair of swimmer’s nose clips yesterday.  “Yes”.

“That is why it was long. Life is what you make of it”.

I wish I were kidding. I looked behind me to see if I was on the Tony Robbins version of Candid Camera.

The other person in the row was quiet the entire time.  So, to bring this post back to SQL Server, my stats tell me that 50% of the people I meet are going to tell me that the leather in my shoes is going to make my feet fall off while the other half will ignore me.

Maybe I should increase my sample size.

Update 8/23/2012 – Here are links to each day:
Day 0
Day 1
Day 2
Day 3
Day 4
Day 5

Immersion training with SQLskills

So, next week I go to Seattle for a week of training with Paul Randal, Kimberly Tripp, Jonathan Kehayias and Joe Sack. This will be my second training class with SQLskills. Last year I attended their IE1 class and it was some of the best training I’ve had. I highly recommend their immersion classes to any SQL Server professional.

Admittedly, I haven’t been looking forward to it even though I expect it will be outstanding. First, I’m tall and flying absolutely sucks.

Here is the legroom I didn’t have on my last flight. Notice my right knee actually is longer than the amount of leg room available.

This is before the considerate person in front of me decided she needed a nap.

Second, they are three hours behind me and I get up early anyway. On Seattle time I will be wide awake at 3AM. Training doesn’t start for another 5 hours about the time I’m ready for lunch. At least breakfast will be good. It was last year anyway.

At any rate, this is one of those posts I’m putting up to shame myself into blogging every day about the training. I’m sure I will be tired at the end of each day (the classes are intense and densely packed with information.) Your brain will hurt at the end of the day.

So, assuming my plane doesn’t auger in or that I don’t get diverted into a romantic get-away from an overly tactilian (if that isn’t a word it should be) TSA agent I’ll be putting up some posts about my training experiences next week.

Update 8/23/2012 – Here are links to each day:
Day 0
Day 1
Day 2
Day 3
Day 4
Day 5