Showing posts with label Deadlocks. Show all posts
Showing posts with label Deadlocks. Show all posts

Monday, May 8, 2023

Tales From The Field Weekly Wrap Up for the Week of 05-01-2023 A new house, a reunion, & 15 Years of SQL Saturday Jacksonville

 Hello Dear Reader, what a week!  On Thursday my wife and I closed on a new house.  We are so incredibly excited!  We owned a house for a very short period of time.  When we bought the house we did not look at the school districts.  

When the kiddos came to live with us full time during the pandemic we quickly found out the schools were..... really bad.  Great neighborhood, beautiful house, bad schools.  So we quickly came to the conclusion that we would have to move.

We found and even better neighborhood, AMAZING schools, but the cost was the house.  We hadn't owned long enough to get much equity.  As a matter of fact we lost quite a bit of money.  We sold during the pandemic before the housing market went crazy.  We thought we would save for a year and then buy a new house in this great neighborhood.  What's the old phrase?  "Man plans, God laughs".  Yeah, the housing market went nuts.  One year turned to two, two years turned to three, and three looked like it would turn into four.  With three months left before our lease expired I did a lot of calculations and found we might be able to get a house. AND WE DID!!!

We had just started to really enjoy doing the small things that make a house yours.  The best part is we only one mile away from our old house, so we get to keep the same awesome schools, we stay in the same neighborhood, and I get to keep my same running & walking routes!

That would normally be enough news for a month, but you know me there is no rest.  After closing on the house I hit the road to the 15th Anniversary of SQL Saturday Jacksonville.

Josh Luedeman (Twitter | @JoshLuedeman), Neeraj Jhaveri (Twitter | @Neeraj_Jhaveri), Daniel Taylor (Twitter | @DBABulldog), Andres Padilla (Twitter | @nodestreamio), & myself all decided we should submit to the conference.  The really amazing part, as much time as we've spent with online we've never all gathered together before.  Josh, Neeraj, & I had met pre-covid during work trips, but Andres & Dan had joined our team during the pandemic.  Our good friend Bradley Schacht (Twitter | @BradleySchacht) from the Azure Synapse Product Group joined us!

We started out with a nice dinner on Thursday and the in person preparations began for our pre-con DBA 101: A Full Day of Fundamentals.  We had a great group of gentlemen that joined us for the day.  We covered a lot of basics about SQL Server and the Cloud, specifically Azure, but we made sure people understood how to translate that skill set. 

We did a lot of group exercises, starting with building on premise, hybrid, and cloud architectures. Then applying SLA's, RTO, RPO requirements so we could discuss how to configure backups, high availability, and then disaster recovery.

We reviewed basic security within SQL Server which translates to Azure SQL, as well as some basic Identity topics covering AD & AAD.  Great group of people and a great way to kick off Friday.

Friday night took us to the SQL Saturday Speaker dinner and then a group activity we had planned together watching the Guardians of the Galaxy 3.  No spoilers.  Great movie and a really nice send off to the trilogy.

After that we headed back to the hotel, hung out, had some nice conversations, and then went to sleep so we could start the big event, SQL Saturday.

All of us who have been in the community for a while have seen the ups and downs that happened during the pandemic.  We all had a lot to deal with in that time, and there were some devastating losses for me personally.  Maybe next year I will write about it, but there are some areas that are still to raw for me.  I'm sure there are for a lot of people.  I tried to remind myself during that time that in the middle of something you cannot see the end, nor can you see the recovery.  I held fast to the idea that they would occur.

In the SQL Community I have made so many close deeply personal friendships, that calling people "friends" hardly does justice to what I feel.  Of those people Karla & Rodney Landrum are up there at the top.  The last time I saw them they came to Orlando to visit.  Karla, Rodney, Sue, and myself went to Chef's in the Paris district of Epcot.  We also had them over to the house.  I cooked, Karla mixed the drinks (which I loved still to this day!) and we had a fantastic time.  That was 2019.  There is no way we could have known how long it would be until we saw each other again, what we would have encountered.  It was all I could do not to breakdown crying as I hugged Karla.

I didn't realize she would be there, and the joy I feel even know days removed is palpable. I'm so glad we are having in person events again.  I'm so glad I get to see my friends, donate my time, and teach people.  If you have a SQL Saturday happening near you, you've got to check them out, I cannot recommend getting involved enough.

Ok, over to the recap.

MONDAY 5-1-2023
On Monday Josh Luedeman published his first video, way to go JOSH!!  Josh's video Setup Windows with Chocolatey for Data Developers walked us through using the Chocolatey packages to install and configure post-Windows installation tasks easily!


He installed Git, WSL 2, Ubuntu, Spotify, Discord, PowerShell, Azure Data Studio, SQL Server Management Studio, and Signal!  If you find yourself setting up a new Windows computer, this is a fantastic shortcut to the installation process. 

WEDNESDAY 5-3-2023
On Wedneday we released my latest video on creating a Dynamic Pipeline in Azure Synapse & Data Factory!!  This is a process that I've walked many customers through over the years.  The key is we are trying to minimize the number of Source & Sink data sets created to import data in this video.

Dynamic Pipelines are incredibly powerful and can be used in many different ways. This was just one of them, but based on the reaction from you Dear Reader, we will be showing a few additional ways this can be used!

TUESDAY 5-2-2023
We kicked off the Azure Data Community Round Table this past week discussing the weather and how much we were all looking forward to getting together at SQL Saturday Jacksonville.


Of course as we all know the star of the show is the Community.  So without further ado here are the links in order of appearance on the show:

Neeraj
The Plain-English Guide to Data Warehouses [+ Examples]  by Swetha Amaresan  Twitter @swethamaresan

Bradley

Andres
Opening the eyes of the machine: Computer vision with AutoML by Gavita Regunath & Dan Lantos Twitter @gavi_sr

Josh

Neeraj

Bradley
SQL Server Row Count for all Tables in a Database by Dattatrey Sindol Twitter @dattatreysindol via @mssqltips

Andres
Building a startup using Azure Computer Vision by Nikhil Sehgal Twitter @nikhilsehgal_ai

Josh
Chocolate Install Git Config by Gary Ewan Park Twitter @gep13

Neeraj
Best practices for Purview and a federated way of working   by Piethein Strengholt Twitter @phstrengholt

Bradley
EightKB 2023 – Schedule and Registration by Andrew Pruski via SQL Server Central Twitter  @dbafromthecold via @SQLServerCentrl

Andres

Josh
Monitoring Deadlocks in Azure SQL Managed Instance by Bradley Ball Twitter @SQLBalls


WRAP IT UP
What an amazing week we had last week, and it's only going to get better!  This week we have Andres & Neeraj presenting Computer Vision with Azure ML Studio that will be live today at 1 PM EST.

I will have another video this Wednesday, and of course our Tales from the Field Azure Data Community Round table will be this Tuesday Live at 1 PM.

I'm sure we will figure out some adventure to have this weekend, alright Dear Reader.  Time for me to head out, as always Thank You Dear Reader for stopping by.

Thanks,

Brad




Tuesday, May 2, 2023

Monitoring Deadlocks in Azure SQL Managed Instance

 Hello Dear Reader!  My lastest blog on our Azure FastTrack blog for Microsoft is live, Monitoring Deadlocks in Azure SQL Managed Instance. 

Here's a little from the blog:

To paraphrase Annie, Deadlocks ARE JUST AWFUL!  When they occur, it means one transaction was the victim and rolled back, the other succeeded.  You have a couple different ways to monitor them in Azure SQL Managed Instance.  Let's review those together. 

 

What is a deadlock?  To quote our MS Learn Documentation, "Deadlocks occur when two or more processes or transactions block each other from continuing because each has locked a database resource that the other transaction needs".  

In layman's terms a deadlock occurs when two queries are blocking one another and neither could ever complete its transaction.  Pretend two people need to use the same door.  They cannot fit through at the same time.  One must stop and let the other proceeded first.  Now add on top of that they both reached for the door knob and grabbed it at the same time, both pulling the door in an opposite direction.   

 

Instead of simply waiting, one must let go of the door knob.  In this case the door knob is a table, the hands reaching out are attempting to gain a lock.   In SQL Server, all versions of the database engine, this is accomplished by the Lock Manager it uses a process called FIFO, first in first out, to determine who has to let go.

 

In the case of SQL one transaction is a deadlock victim, it is killed and the transaction is rolled back.  So if this is occurring on your system fixing it is very important.  First you have to find out if they are occurring, and that's what we will cover in this blog post today!


To read the rest here is the link: Monitoring Deadlocks in Azure SQL Managed Instance


As always Dear Reader, Thank You for stopping by.


Thanks,


Brad