Killing sessions automatically with SSIS
...or, what to do while you're waiting for Analysis Services to get a proper resource governor (fingers crossed for the next version).
We all know about the query from hell, that one query that the idiot from Finance insists on running to try to pull the entire contents of the cube down into Excel even though you've told him a hundred times not to do it, that one query that brings your server to its knees just at the worst possible moment. What can you do about it? Well, you can set a general timeout on all all queries that are run against Analysis Services using the ServerTimeout property in msmdsrv.ini, but this is something of a blunt instrument - while I don't mind everyone else's queries timing out after two minutes, I certainly don't want mine to do that and I definitely don't want that to happen to the CEO's queries either. On the other hand, you can wait for someone to phone you up and complain that the server's really slow, then take a look at what's running and kill sessions manually using something like the technique described here
Read more...