Tuesday, July 17, 2012

Remote Desktop and the DBA

Sometime last week, Brent Ozar tweeted the comment below and I sort of took offense (not really):
DBAs who RDP into the SQL Server console, take one step forward. Closer. Closer to the monitor. I need to slap you.
I must admit that I use Remote Desktop sessions into my BI servers rather frequently but I think I have some pretty good reasons. Some might fall into the realm of excuses but I am open to debate on the subject.

Process Analysis Services Databases

I have a laptop, I bet you do to. A DBA, BI Admin, or any other type of system administrator usually has one so they can log in to the company net work from remote location, usually to fix stuff. If I have to process an Analysis Services database I usually remote into the server to do it. This allows me to put my laptop to sleep or shut it down so I can go to meetings or go home on time. Staying at the office late sucks, especially for something that you just have to sit around waiting for. If I run the processing on the server I can disconnect and come back to it later.

In this case I also have the advantage of having a server that is dedicated to processing SSAS databases. That's all it does. Sure, having the SSMS GUI up to process the DB is going to use some more system resources but it's not affecting users and the server rarely uses all the resources it has anyway.

I could have the job to process the database executed on the corporate scheduling system; however, that has the additional side-effect of synchronizing the database to at least one query server. Oftentimes my goal is to process the database so that someone can look at it and make sure that everything is in order before I sync up to the query servers so running the job takes away my check-step.

Copying Database Backups

Remember that laptop I mentioned? It's often on a wireless connection. I have a desktop (actually it's a virtual desktop) but it's not on the same network as the servers. Sometimes I have to copy large backup files from one server to another. Have you ever done that across a slow network connection? Yeah, it sucks.

I like to remote into servers to copy files. It's just plain faster. You have a source and a destination and just one hop between them. If you have another computer in between there is probably going to bottle-neck the transfer somewhere and slow it down.

Deploying SSIS Packages

I used to do this from my one of my workstations but I have kind of hosed myself up in two ways. First of all, we're in the process of switching from SQL Server 2008 to 2012 (yay!) but I have removed some of the third-party 2008 R2 SSIS components

This brings us to the second part of the problem. We use BI xPress to deploy packages and apply their auditing framework for package execution logging. BI xPress opens the package in memory and saves it off to the server (or something like that). BI xPress can't open the package if the components are on there.

Everything I need to deploy packages is on the Production server so I can remote in and copy packages from the QA server to the Production machine. We're working to fix this (as well as the whole deployment process) but, in the meantime, I'm kind of stuck.

Daddy, Please don't make me use the command line!

Sometime back when Windows was really getting popular (version 3.5 or thereabouts) a group of hooded men in grey cloaks dragged me kicking and screaming out of my DOS world. Yeah, I liked DOS and I didn't think those GUI things were worth a damn. Eventually I was brainwashed learned the error of my ways and started using GUIs. I even started liking them. I still use keyboard shortcuts and avoid using the mouse but GUIs offer up some really good ways to avoid errors and find things quickly.

I have picked up a little bit of PowerShell (I was a .NET developer once or twice so it comes pretty naturally) and I expect that it has great ways of handling those cases where I tend to use Remote Desktop. I like PowerShell for its scripting capabilities but I don't see myself typing out the copy command every time I need to move a backup file from one server to another, especially with all the paths that I can never remember.

I suppose I am going to have to learn some more PowerShell and write some scripts to handle the above tasks. Have you ever written a big long blog post and come to the conclusion that the rant you were going to throw out there was just plain wrong? I hate it when I learn stuff. Mr. Ozar, you suck. ;)

No comments:

Post a Comment