Configuration: Sending Emails with Database Mail
Database mail helps administrators know when something went terribly awry on a SQL Server, like corruption, a failed restore, or the system’s about to go offline due to a serious issue. It doesn’t catch everything, but if you configure it right, it’ll give you a quick heads-up about most common issues. Let’s cover how to set it up.
In the video, I cover these queries:
|
1 2 3 4 5 6 7 |
SELECT is_broker_enabled FROM sys.databases WHERE name = 'msdb; SELECT * FROM sys.configurations WHERE name = 'Database Mail XPs'; |
And:
|
1 2 3 4 5 6 |
EXEC sp_configure 'show advanced option', '1'; RECONFIGURE GO EXEC sp_configure 'Database Mail XPs', 1; RECONFIGURE GO |