November 18, 2015 at 9:47 am
Comments posted to this topic are about the item SQL Jobs on Always On
Thank You.
Regards,
Raghavender Chavva
December 2, 2015 at 6:38 am
Thanks for the script. I'll pass it on to my admin.
December 2, 2015 at 6:55 am
Nice script, however if you have any jobs disabled purposely, when the availability group fails over, it will re-enable those jobs. You'd have to always update this script and hardcode the jobs which are manually disabled (or create a lookup table).
I prefer to put a step 1 in all of my jobs to check if the current node is primary or not. If it's not primary, it just doesn't go to step 2. Much cleaner and I don't have to worry about keeping a script up to date.
December 11, 2015 at 9:26 am
That's a nice script however it really is just simple to put the code where is looks to see if it is primary or not. That's all I did on mine and it works with no issues. Even MS (David Pless) said that's all that is needed when checking Agent jobs. You can get the code from your full backups where it checks to see if it is on primary or not.
https://msdn.microsoft.com/en-us/library/hh710053.aspx
https://msdn.microsoft.com/en-us/library/hh213235.aspx
MCSE SQL Server 2012\2014\2016
April 25, 2016 at 4:46 pm
lkennedy76 (12/11/2015)
https://msdn.microsoft.com/en-us/library/hh710053.aspx
https://msdn.microsoft.com/en-us/library/hh213235.aspx%5B/quote%5DThanks for the extra insight.
Viewing 5 posts - 1 through 4 (of 4 total)
You must be logged in to reply to this topic. Login to reply