You Know Him, You Love Him
You trust your database backups and integrity checks to him, and he has been KILLING IT on new features lately.
A while back, Ola decided to Open Source his scripts on GitHub (Soon to be known as Microsoft LiveHub for Business Essentials). As more and more people embrace GitHub and are getting used to how it works, the feature suggestions have been rolling in.
And Ola has been hard at work making your Maintenance Dreams come true.
Eye Spotting
Tokenized Directory Structure
1 2 3 4 5 6 |
EXECUTE dbo.DatabaseBackup @Databases = 'USER_DATABASES', @Directory = 'C:\Backup', @BackupType = 'FULL', @DirectoryStructure = '{DatabaseName}{DirectorySeparator}{BackupType}_{Partial}_{CopyOnly}', @AvailabilityGroupDirectoryStructure = '{DatabaseName}{DirectorySeparator}{BackupType}_{Partial}_{CopyOnly}' |
More Stats Update Control & Incremental Statistics Support
One issue I always ran into was with @OnlyModifiedStatistics: it was just yes or no.
Which isn’t bad, but it meant that if there was a single modification, stats got updated. Most people would wanna wait until a good chunk of modifications happened, and now you can. Just set @StatisticsModificationLevel to a comfy percentage and skip over all those low-modification statistics. This can be a real time saver in large environments.
1 2 3 4 5 6 7 8 |
EXECUTE dbo.IndexOptimize @Databases = 'USER_DATABASES', @FragmentationLow = NULL, @FragmentationMedium = NULL, @FragmentationHigh = NULL, @UpdateStatistics = 'ALL', @PartitionLevel = 'Y', @StatisticsModificationLevel = 10 |
Ordering for Backups and CHECKDB
Got databases you want to backup in a certain order? Now you can! For backups, you can order by database name or size, and for CHECKDB you can also order by the last good check locally or on a replica..
Just like with the stats updates, this is badass for people with limited maintenance windows — which means — you guessed it! They work alongside the @TimeLimit parameter. Let’s say you’ve got 5-10 really big databases on your server, and you can only get a couple of them in. You used to have to jump through some hoops to set up different schedules, or build your own dynamic list. Now you have your jobs pick up where the left off the night before.
This Stuff Is All Free
Remember folks, Ola doesn’t charge a dime for any of this. You can put it on as many servers as you want, for free.
Lord knows I have.
6 Comments. Leave new
Erik, thanks for the post (and to Ola for all his work), but as for your saying that Githib is “Soon to be known as Microsoft LiveHub for Business Essentials”, can you offer any reference that indicates that? I find none in googling for it various ways. If this were April 1 I might think that was a prank comment. 🙂
If the name really is going to be that, I would think there would be an uproar in the wider IT community, not least of which for the fear that its including the term “business essentials” would imply there may be commercial editions, which would seem to fly in the face of the github ethos. Or am I way off base here, everyone? 🙂 I haven’t been following the whole acquisition drama, and I’m sure some have read every word on it.
Sorry to derail the discussion. If you guys might want to tell us not to have the discussion here, I would understand. But if you could offer any answer to my question I (and perhaps others) would appreciate it. Thanks so much for all that you folks do.
Charlie — nope, just a joke!
Thanks!
Ah, ok. Phew. (And glad I acknowledged that it might be.) If you wanted to maybe add a “just kidding” to the statement, it may help avoid others getting exercised. 🙂 In that case, feel free to delete our comments. But if you are leaving it vague for the fun of it, I’ll say “you cheeky monkey” and leave it at that. 🙂
Unfortunately for me, my blood starting boiling before I read the comments!
Ola is nothing short of a legend. Earlier this year I found an issue where his scripts would not allow backup to Azure blob using BLOCKSIZE and MAXTRANSFERSIZE. I informed him and within a month and a half he had tweaked his scripts to allow this. Top man.
Yes, hear, hear to Ola! Been pushing the use of this scripts to ease our DBA workload for years, but unfortunately, I often get resistance from modern day Luddites who prefer to just leave stats and indexes maint to a monthly patching night :/ It is highly doubtful there exists in-house cooked up code that is better than this, so please DBAs adopt this awesome standard, so you can may have the time to do all those lovely BI, Security, et al. projects you’re salivating to do anyway!