What Happens to Pages in the Buffer Pool when your Availablity Group Fails Over?

Recently at SQL Saturday Philadelphia, we started discussing failover  as it relates to mirroring and Always On Availability Groups. Specifically, we were wondering what would happen if you had a relatively busy readable secondary replica (which would have a lot of pages in the buffer pool on the secondary instance) and if those pages would be flushed from cache or anything like that. So I reached out to the product group and Kevin Farlee from Microsoft was extremely helpful:

Pages in the buffer pool are still valid, as they are updated by the redo thread.  By the time the secondary has transitioned to primary, all pending updates will have been applied, so pages in the bufferpool will all have correct contents. Note that the set of pages in bufferpool may be different between primary and secondary so you may have some cache warm up to do.”

So in a nutshell, if you have a busy readable secondary your cache won’t take much time to warmup, since the hot pages are already there.

Server Virtualization–the bottom end of the spectrum

Brent Ozar posted an excellent blog yesterday, on the upper limits of server virtualization. In his post, he discussed the limitations of the upper limits of using VMWare for database servers. I mentioned to Brent on twitter that, I had just been talking about the other side of this–what’s too small to virtualize.

I was in a meeting yesterday, discussing a recent acquisition for our company, and one of our remote manufacturing sites, and the costs involved of converting them to a virtual infrastructure. Each of these sites currently have around 10 physical servers, and no shared storage platform (currently). The leading management argument was that it’s cheaper to replace the servers of a regular cycle, than to make the investment into a virtual infrastructure.

The hardware costs for the project are as low as about $50-60k–using HP 360s and MSA iSCSI storage. That’s 3 servers and 3-4Tb of storage. The real killer is the VMWare licensing–we’re looking at close to $40k a host, which brings the total cost of the project to well over $100k. We’re in an odd spot, because we’re in a large company, but supporting smaller sites, that need some enterprise management features. A smaller shop could get away with VMWare Essentials plus, which is a much more affordable $3k a server (all prices are non-discounted).

However, that brings the total cost of the project to about $70k–which would replace all of the standalone servers on site at least once.

This obviously doesn’t account for reduced management and backup costs, nor does it account for the higher availability of the VMWare environment. High Availability can still be a hard sell in small shops–believe it or not. But that’s where the value in virtualizing their hardware is–outstanding uptime and ease of management. With a little bit higher cost.

I’m a big fan of virtualization, but some times it can be a hard sell to the pointy haired boss.

%d bloggers like this: