I have repeatedly re-setup and and tested dbmail with success and repeatedly re-setup sqlagent alerting, but I continue to get the message below when sql agent starts up.
Message
[260] Unable to start mail session (reason: Microsoft.SqlServer.Management.SqlIMail.Server.Common.BaseException: Mail configuration information could not be read from the database. ---> System.InvalidCastException: Unable to cast object of type 'System.DBNull'
to type 'System.Byte[]'.
Alerting does not work.
sp_send_dbmail works fine with this profile and account.
I have set my default mail profile and made it public. I have the exact same configuration on another server. Not sure where to go from here.