Answered by:
Database mail for invalid login

Question
-
hi all
How to generate alert or database mail for invalid login attempt in sql server 2008. if any body login with wrong username or password i want to generate alert or database mail to admin.
please help me out.
Thanks.
Monday, July 1, 2013 11:36 AM
Answers
-
You probably need to read ERROR.LOG... or
http://www.mssqltips.com/sqlservertip/2595/get-alerts-for-specific-sql-server-login-failed-events/
Best Regards,Uri Dimant SQL Server MVP, http://sqlblog.com/blogs/uri_dimant/
MS SQL optimization: MS SQL Development and Optimization
MS SQL Blog: Large scale of database and data cleansing
Remote DBA Services: Improves MS SQL Database Performance
Monday, July 1, 2013 11:44 AMAnswerer -
First RK on sql server go to properties and then go to security on the page which opens see whether the radio button under login auditing is checked for 'FAILED LOGINS ONLY'
If so any failed login will be recorded in sql server error log.You can see from here also and if u want to be nodified thru mail follow steps in below link.You need to enable database mail feature in SQL server from SP_configure first.
You can also set up trace using extended events for the same.
http://msdn.microsoft.com/en-us/library/bb630282.aspx
Please mark this reply as the answer or vote as helpful, as appropriate, to make it useful for other readers
Monday, July 1, 2013 11:51 AM
All replies
-
You probably need to read ERROR.LOG... or
http://www.mssqltips.com/sqlservertip/2595/get-alerts-for-specific-sql-server-login-failed-events/
Best Regards,Uri Dimant SQL Server MVP, http://sqlblog.com/blogs/uri_dimant/
MS SQL optimization: MS SQL Development and Optimization
MS SQL Blog: Large scale of database and data cleansing
Remote DBA Services: Improves MS SQL Database Performance
Monday, July 1, 2013 11:44 AMAnswerer -
First RK on sql server go to properties and then go to security on the page which opens see whether the radio button under login auditing is checked for 'FAILED LOGINS ONLY'
If so any failed login will be recorded in sql server error log.You can see from here also and if u want to be nodified thru mail follow steps in below link.You need to enable database mail feature in SQL server from SP_configure first.
You can also set up trace using extended events for the same.
http://msdn.microsoft.com/en-us/library/bb630282.aspx
Please mark this reply as the answer or vote as helpful, as appropriate, to make it useful for other readers
Monday, July 1, 2013 11:51 AM