
Photo credit to henrymatt
It seems like every week or so I’ve been getting another request to build out a SQL Server installation for a Development team. Usually these are pretty simple: install database engine, patch to current levels, create a database or two, and grant the developers db_owner / ALTER ANY LOGIN rights (why not securityadmin you might ask? Read
this and you’ll understand why), and off you go. Seems easy enough, right?
Well, yes, but you see there’s a bit of hidden cost associated with all that. For one, there’s the overhead of maintaining the server: patches, taking care of failed maintenance (integrity checks, backups, etc), adding more drive space when needed, etc. While it’s not an overwhelming amount of work, it does increase every time a new server is added to the thirty plus ones I already support. This of course includes folks besides me such as the infrastructure (server admin) and storage management (SAN) teams.
The Urge To Consolidate
As a production DBA I was constantly working on projects to consolidate SQL instances. In this day of shrinking IT budgets, the words “leveraged” and “shared” seem to fly around quite a bit, and rightfully so. With the kind of big, multi-core, 64GB+ RAM setups one can aquire these days, there’s just no excuse for having a server with a handful of databases on it (unless, of course, you have some quantitative numbers to prove that those few databases really will take all the resources on that server).
Why should it be any different in development systems? Sure, it’s pretty doubtful that you could get the budget for any big iron pieces of hardware, but then again you don’t really need that. Development systems in general don’t seem to be used for benchmarking or performance testing (as much as I’d like them to be, but that’s another story), so lightning response times aren’t generally a priority. I would say a more realistic goal would be for the system to be manageable in terms of maintenance (since that’s probably when it’s getting hit the hardest), and have enough juice that one rogue query won’t take it out completely.
<rant>While we’re on that topic, can I just tell you how crazy it makes me when I discover a VM Dev server with 50+ databases (over 3 instances of SQL) on it, with only 2GB of RAM and all iSCSI attached NAS storage (over the same network as other traffic no less)? I mean, I understand that yes, this is development, and we’re going to be getting cheap goods, but come one people… my pocket calculator probably has more horsepower than that. Maintenance takes 12+ hours to complete for s***s sake!</rant>
Oh, sorry, got a little emotional there. Where were we? Oh yes…
The Master Plan… at least for now
So here is my initial take on this: the vast majority of my servers could easily be consolidated down to, let’s say, five total instances.
- DEV SQL 2005 instance 1
- DEV SQL 2005 instance 2
- QA SQL 2005
- DEV SQL 2008
- QA SQL 2008
The idea here is that Dev and QA should not be in the same sandbox. Development is for, well, development. It can be a little dirtier and looser in security, for the sake of convenience (but no, Mr. Developer, you still can’t have sysadmin rights. Do you know what Max DOP is? Didn’t think so, k thx bye!). QA, on the other hand, should be locked down similar to how production is, in the interests of ensuring as close to a real pre-release test as possible.
In terms of setup, I’m picturing a total of 8 VMs: 2 for each instance, configured as either an Active/Passive cluster, or (in the case of the two SQL 2005 DEV instances) and Active/Active cluster. Each would have between 4 and 8GB of RAM depending upon workload. This means that, assuming we don’t want two nodes on the same physical host, I’d need only four physical boxes, with ~12GB of RAM each. Hopefully I can pull these out of the “Free Server” pile, where unused boxes go before being shipped off to the scrap heap. They don’t need to be fancy; just 64 bit capable and compliant with VMWare ESX.
Why clusters, you might say? Well, for one, I’ve never built a cluster before, and I’m always looking for excuses to learn new things. Secondly, because I do want to have some level of HA in my leveraged system. It’s one thing if one Dev team gets hung up for a day because their server went down, quite another if a whole group is up the river.
And yes, there probably will be some cases, just as in production database support, where a leveraged system is not an option. Maybe the software requires some component to be installed on the database server itself (hey vendors, I really hate it when you do that, especially when you can’t justify why). And there will probably be some cases where the Dev teams just don’t want to give up their control, and that’s their right. But they won’t be getting my full support if that’s the route they want to take.
So that’s the plan, in a nutshell. Naturally I’ve got to get both management and the developers to buy in, but hey, that’s what my psychology degree is for, right?
P.S. I’d love to hear from other folks who support (or have supported) development SQL infrastructures on how they handled situations like this. Leave your thoughts in the comments.