Question

email notifications

Asked by: EdwardPeter

Hi,

>>
-Create the desired alerts in Enterprise Manager. For each alert, specify the operator(s) you want to be notified.
Run the client (DbMAlerterClient.exe) to create the needed tables in msdb, and also configure the SMTP mail settings.
-Schedule the server (DbMAlerterServer.exe), which will read the eventlog and submit email to the operators as configured. -Recommended scheduling interval is between once per minute to once per 10 minutes. DbMAlerterServer.exe will attempt to login to the SQL Server using Windows logins and it takes one command-line parameter: the name of the SQL Server to connect to, as in
<<

1. does this mean after configuring DbMAlerterClient.exe we do not close it and add it to start up ? does this goes the same for DbMAlerterServer.exe ? Please kindly assist

C:\Program Files\DbMaintSmtpAlerter\DbMAlerterServer MachineName[\InstanceName]

2. what is instanceName ?

This Question has been solved and asker verified All Experts Exchange premium technology solutions are available to subscription members.

Subscribe now for full access to Experts Exchange and get

Instant Access to this Solution

  • Plus...
  • 30 Day FREE access, no risk, no obligation
  • Collaborate with the world's top tech experts
  • Unlimited access to our exclusive solution database
  • Never be left without tech help again

Subscribe Now

Asked On
2005-10-06 at 07:21:02ID21585936
Tags

dbmalerterserver

Topic

MS SQL Server

Participating Experts
2
Points
500
Comments
36

Trusted by hundreds of thousands everyday for fast, accurate and reliable tech support.

  • "The time we save is the biggest benefit of Experts Exchange to Warner Bros. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange." Mike Kapnisakis, Warner Bros.
  • "Our team likes having a resource that is more secure than just using Google and most experts using this service really know their stuff. It's nice to look here first versus using Google." Dayna Sellner, Lockheed Martin
  • "Anytime that I've been stumped with a problem, 9 out of 10 times Experts Exchange has either the accepted solution or an open discussion of the potential solution to the problem." Kenny Red, eBay Inc.

See what Experts Exchange can do for you.

Got a question?

We've got the answer.

Experts Exchange has been collecting answers to technology questions since 1996…3 million and counting! If you have a question, chances are we already have your answer.

Screenshot of Experts Exchange Knowledgebase

Need individual assistance?

Our experts are ready to help.

If you can't find the exact answer you're looking for, ask our exclusive community of 50,000 experts. You’ll get a personalized answer from a trusted professional.

Screenshot of Experts Exchange Knowledgebase

Want to learn from the best?

Read articles from industry experts.

Thousands of free tech tips, tricks, how-to’s and tutorials are available in our peer reviewed articles section. See for yourself how smart our experts are, no login required.

Screenshot of an Article

Working on a long term project?

Store your work and research.

Save solutions to your questions, answers you’ve discovered through searching plus helpful articles in your personal knowledgebase for easy future access.

Screenshot of Experts Exchange Knowledgebase

Access the answers to your technology questions today.

Subscribe Now

30-day free trial. Register in 60 seconds.

What Makes Experts Exchange Unique?

Members of the expert community talk about why the experience at Experts Exchange is different than what you will find anywhere else.

Trusted by the world's most respected brands.

image of each brand's logo

Faithfully serving IT professionals since 1996.

Experts Exchange Logo

Try it out and discover for yourself.

Subscribe Now

30-day free trial. Register in 60 seconds.

Related Solutions

  1. Notify in groupshield
    Is it possible don't notify any virus alert to my recipient?. I have groupshield 5 with sp1 on Exchange 2000. Now when i replace an item i put a file with notification. I don't want this notification for recipients but only for administrator. Thanx
  2. Email notification
    Hi, Is there a way to set up in outlook 2003 so that when the email is in, there will be a pop up notification? thx
  3. email notification services
    Carrying on from another question on this subject posted at http://www.experts-exchange.com/Databases/Microsoft_SQL_Server/Q_21786163.html#16293172 I believe there may be a method of implementing notification services, ie sending of email notifications to subscribers when a...
  4. SQL Job Email notification Error
    Hi Experts, I am getting the following error when setting up a email notification job. The error happens when i press the TEST button. "Error 22022: SQLServerAgent Error: The SQLServerAgent mail session is not running; check the mail profile and/or the SQLServerAgent ...

Free Tech Articles

  1. WARNING: 5 Reasons why you should NEVER fix a computer for free.
    It is in our nature to love the puzzle. We are obsessed. The lot of us. We love puzzles. We love the challenge. We thrive on finding the answer. We hate disarray. It bothers us deep in our soul. W...
  2. SCCM OSD Basic troubleshooting
    SCCM 2007 OSD is a fantastic way to deploy operating systems, however, like most things SCCM issues can sometimes be difficult to resolve due to the sheer volume of logs to sift through and the dispe...
  3. Migrate Small Business Server 2003 to Exchange 2010 and Windows 2008 R2
    This guide is intended to provide step by step instructions on how to migrate from Small Business Server 2003 to Windows 2008 R2 with Exchange 2010. For this migration to work you will need the fo...
  4. Create a Win7 Gadget
    This article shows you how to create a simple "Gadget" -- a sort of mini-application supported by Windows 7 and Vista. Gadgets can be dropped anywhere on the desktop to provide instant information, ...
  5. Outlook continually prompting for username and password
    There have been a lot of questions recently regarding Outlook prompting for a username and password whilst using Exchange 2007. There are a few reasons why this would happen and I will try to cover t...
  6. Backup Exchange 2010 Information Store using Windows Backup
    There seems to be quite a lot of confusion around the ability to backup Exchange 2010 using the built in Windows Backup feature. This stems from the omission of this feature prior to Exchange 2007 s...

Cloud Class Webinars

  1. Avoiding Bugs in Microsoft Access
    Alison Balter takes and in-depth look at avoiding bugs in Access. In this webinar you will learn about using the immediate window to debug your applications, invoking the debugger, using breakpoints to troubleshoot, stepping through code, setting the next statement to execute, ...
  2. Top 10 Best New Features in Visio 2010
    Scott Helmers gives live demonstrations of the top 10 new features in Visio 2010. This webinar will teach you how to create compelling diagrams by adding shapes to the page with a single click, linking the shapes in a diagram to data in Excel (or SQL Server, or SharePoint), ...
  3. IT Consultant Business Secrets Revealed
    Michael Munger, Experts Exchange tech pro and IT consultant, pulls back the curtain on his very successful businesses and answers question on every IT consultant and business owner should know about. He shares secrets on what he did to solve the 5 most common problems in IT, ...
  4. Disaster Recovery and Business Continuity
    Quest CTO, Mike Billon, gives an overview of the steps involved in building a dunamic disaster recovery plan. Through case studies and an examination of software/hardware tooles for monitoring and testing, you'll gain a better understandin of where you are, where you want ...
  5. Organize Your Visio Diagrams with Containers and Lists
    Scott Helmers uses cross functional flowcharts, wireframe diagrams, data graphic legends and seating charts to teach you: how to ustilize all three new structured diagram components in Visio 2010, the best practices for organizeing shapes in previous version of Visio, how to organize ...
  6. How to Us Objects, Properties, Events and Methods in Microsoft Access
    Alison Dalter gives an in-depbth look at objects, properties, events and methods in Microsoft Access. In this webinar you will learn about using the object browser, referring to objects, working with properties and methods, working with object variables, understanding the ...

Join the Community

Give a Little. Get a Lot.

Join the community of experts here and help other tech pros by answering question in your area of expertise. You can earn FREE access to all Experts Exchange's premium features and resources.

Join the Community

Answers

 

by: Kevin3NFPosted on 2005-10-06 at 07:24:30ID: 15030741

Instance name is only relevant if you have installed SQL Server as a named instance.  If you chose to install SQL Server as a default, just use the SQL Server name

I have no idea what DbMAlerterClient.exe is...is that a third party application?

 

by: EugeneZPosted on 2005-10-06 at 08:22:41ID: 15031345


it is very simple explanation - step-by-step :

http://www.karaszi.com/sqlserver/util_smtp_alerter.asp
---

instance - sql server 2k name
---
MS DOS command line that can be executed as scheduled task :

run for  your DbMAlerterServer.exe location
below it is example:

\Program Files\DbMaintSmtpAlerter\DbMAlerterServer MachineName[\InstanceName]

 

by: EdwardPeterPosted on 2005-10-06 at 09:27:21ID: 15031988

EugeneZ,

how can we schedule? do we use windows scheduler?

 

by: EdwardPeterPosted on 2005-10-06 at 09:35:28ID: 15032072

Kevin3NF,

Where can we find the SQL server name?

Thanks.

 

by: EugeneZPosted on 2005-10-06 at 09:55:34ID: 15032245

windows scheduler or sql server agent job
>Where can we find the SQL server name?

login in Query analyzer - run select @@servername

 

by: EdwardPeterPosted on 2005-10-06 at 09:59:08ID: 15032282

EugeneZ,

Amazing!!!  would you happen to know how can we scheudle using agent job?

select @@servername <---returned lclSQLserv


do we place this with .exe ? My apology for being lost on this.


C:\Program Files\DbMaintSmtpAlerter\DbMAlerterServer.exe lclSQLserv

 

by: Kevin3NFPosted on 2005-10-06 at 10:34:15ID: 15032558

"do we place this with .exe ? My apology for being lost on this.


C:\Program Files\DbMaintSmtpAlerter\DbMAlerterServer.exe lclSQLserv"

yes, that looks correct based on the instructions above.

To use a SQL Agent job instead of the Windows task scheduler, you would need to call xp_cmdshell and execute the same application and again provide the sql server name lclSQLsev

 

by: EdwardPeterPosted on 2005-10-07 at 04:09:21ID: 15037392

EugeneZ,

I added an operator, and  on the jobs i have selected the operator and send email notification on job complete.

when I force run the scheduled job it doesn't send...

i tried sending a test mail using the client.exe  is works..

not sure what could be missing..

Thanks.

 

by: EugeneZPosted on 2005-10-07 at 05:27:01ID: 15037863

did you type in operator full email address  - user [AT]somethin [dot] com?

 

by: EdwardPeterPosted on 2005-10-07 at 05:32:29ID: 15037907

EugeneZ,

Yes ofcourse,

1. created the operator
2. added the operator to the existing jobs (db backup etc).
3. set notification on complete.
4. run client.exe created the table as per client, then configured the smtp , to, from. (left open) should we close this?
5. send a test mail, was able to received.
6. sceduled using windows scheduler.

"C:\Program Files\DbMaintSmtpAlerter\DbMAlerterServer.exe lclSQLserv"

run as administrator.

I could be missing something, I've read it's going to fill up a table? or reading the error logs?
maybe we can check if there are any error generated? not sure how to troubleshoot next

Thanks.

 

by: EugeneZPosted on 2005-10-07 at 06:35:13ID: 15038463

>run as administrator.
does 'administrator' has rights in sql server?

 

by: EdwardPeterPosted on 2005-10-07 at 06:40:55ID: 15038514

yes, sql server is running on local administrator account.

is there another way to setup scheduling?

when i double click to execute server.exe, same results.

Thanks.

 

by: EugeneZPosted on 2005-10-07 at 06:48:53ID: 15038591

open in sql server logins and see if there are Bultin\administrators

another way - to run sql server job from sql agent..
BTW: do not forget it is just about logged events in event viewer..

 

by: EugeneZPosted on 2005-10-07 at 07:08:57ID: 15038727

 

by: EugeneZPosted on 2005-10-07 at 07:32:22ID: 15038933

What I did for testing:

added new alert - 15298 - New login created - open it - checked: Always write in Windows eventlog
- checked operator (my self)

Added job: Alerter:

step1 -
selected type:
Operating System command:
paste
command
C:\Program Files\DbMaintSmtpAlerter\DbMAlerterServer.exe  yourservername
--it is my file location

Schedule it for every 15 min

-------------

now:
Create test login- and manually (for test) run the alerter job

 

by: EugeneZPosted on 2005-10-07 at 07:43:42ID: 15039028

>Added job: Alerter:

it is sql server agent job..

 

by: EdwardPeterPosted on 2005-10-08 at 02:32:57ID: 15044214

EugeneZ,

Thanks a million!!! You're simply the best!

 

by: EugeneZPosted on 2005-10-08 at 19:18:22ID: 15046651

you are welcome

 

by: EdwardPeterPosted on 2005-10-11 at 00:07:50ID: 15058139

EugeneZ,

Weird thing is I tired setting up Alert ID for Event 208   (which is for job engine)

sadly it's not trigerring. When I added 208, it's seems to be another ID for Ms Sql,

In BOL
event 208
Message Text
Invalid object name '%.*ls'.    

I'll keep researching...

Thanks

 

by: EugeneZPosted on 2005-10-11 at 04:22:21ID: 15059154

did you check  'Always write in Windows eventlog'?

 

by: EugeneZPosted on 2005-10-11 at 04:25:36ID: 15059167

and do not forget to check in the alert  - email to..

 

by: EdwardPeterPosted on 2005-10-12 at 02:37:49ID: 15067288

EugeneZ,

Yes that is correct, I double check the always write in windos eventlog

maybe you can try and create a bogus job? it will write an event 208 ..

My apology for all the trouble

Thanks.

 

by: EugeneZPosted on 2005-10-12 at 10:22:47ID: 15070878

I did it - it is working ok

I created stored proc -
--in pubs db
create proc dbo.usp_test
as
select * from somenotrealTable

---
create job
as step1:

exec pubs.dbo.usp_test
---
then ran it - job failed but alert was  triggered and sent me email (just do not forget check alll above:

eventviewer, check box to who send notification..

 

by: EdwardPeterPosted on 2005-10-13 at 02:11:50ID: 15075495

When I replace the alert number to 15298 (new user created)

everything is good (i get the email)
SQL Server error text:
======================
Error: 15298, Severity: 0, State: 1
New login created.


but when I place alert no. 208 it doesn't send..

weird, I can see in event viewer that they are being generated...

What alert no did you use?

Thanks.

 

by: EdwardPeterPosted on 2005-10-13 at 02:31:39ID: 15075590

I'm missing something, maybe it's the event id number?

can I know what alert ID number are you using to detect the job fail occurance?



Thanks.

 

by: EugeneZPosted on 2005-10-13 at 15:28:52ID: 15081807

when you typed 208 in small text box of alerts - click ...  --- it will open description etc of the alert - find Edit - click there - there is check box eventviewr - check it and save...

 

by: EdwardPeterPosted on 2005-10-14 at 03:41:43ID: 15084204

I've done it now,

When I add alert 208

and run the email notification job (server.exe hostname)


the following error occurs:
Executed as user: SQLTEST\Administrator. Error from .Net SqlClient Data Provider:  Line 12: Incorrect syntax near 'asdqwe'.  Process Exit Code -1.  The step failed.


but when I remove event ID 208 everything works, even tried create a new alter 208 , seems something is wrong.

Thanks.

 

by: EdwardPeterPosted on 2005-10-14 at 03:54:59ID: 15084249

Where could I have added asdqwe ??

I have backtrack still no luck..

Executed as user: SQLTEST\Administrator. Error from .Net SqlClient Data Provider:  Line 12: Incorrect syntax near 'asdqwe'.  Process Exit Code -1.  The step failed.

 

by: EugeneZPosted on 2005-10-14 at 04:43:03ID: 15084430


does it work for alert 15298?
If 'yes' - did you change 208 message?
Can you see error in EV?
My 208 is working - sql agent job 'Alerter' is running every 15 minutes
with step :
C:\Program Files\DbMaintSmtpAlerter\DbMAlerterServer.exe  servername

 

by: EdwardPeterPosted on 2005-10-14 at 05:48:32ID: 15084793

yes, it does work for 15298, perfectly.

sadly i think i've inputed the value asdqwe somewhere, i could find it again...

when I add 208 sending notification job fails..:

Executed as user: SQLTEST\Administrator. Error from .Net SqlClient Data Provider:  Line 12: Incorrect syntax near 'asdqwe'.  Process Exit Code -1.  The step failed.

 

by: EugeneZPosted on 2005-10-14 at 07:59:37ID: 15086009

can you find this error 208 in EV?

 

by: EdwardPeterPosted on 2005-10-14 at 08:46:17ID: 15086443

EugeneZ,

Yes, it does show up in EV.

Thanks.

 

by: EugeneZPosted on 2005-10-14 at 10:09:48ID: 15087122

what is 'asdqwe'?

 

by: EdwardPeterPosted on 2005-10-14 at 10:54:19ID: 15087495

EugeneZ,

Not sure too, I added it somewhere, I forgot...trying to find out where..

the error only generates when we add alter 208.

i remove everyhting and started from scratch, the "asdqwe" still exists. :(  

Thanks.

 

by: EugeneZPosted on 2005-10-14 at 11:57:32ID: 15088065

try to download - remove old - install new..

 

by: EdwardPeterPosted on 2005-10-18 at 02:37:55ID: 15105808

EugeneZ,

The job (sending email notification) always fails because "asdqwe" was the bogus table. What could I have done wrongly ?  :(


create proc sp_test
as
select count(*) from asdqwe
GO



the following error occurs:
Executed as user: SQLTEST\Administrator. Error from .Net SqlClient Data Provider:  Line 12: Incorrect syntax near 'asdqwe'.  Process Exit Code -1.  The step failed.


Thanks.

20120131-EE-VQP-002

3 Ways to Join

30-Day Free Trial

The Experts

98% positive feedback on 31,087 answers since March 2000. angeliii is a Microsoft Most Valuable Professional for his work with MS SQL Server & Develoment.

He has also proven his knowledge of Visual Basic Programming, PHP Scripting and Oracle Databases.

The Experts

97% positive feedback on 10,752 answers since July 2000. lrmoore has more than 18 years experience in the networking industry.

The six-time Mircosoft MVPs specialties include firewalls, virtual private networking, and network management.

Testimonials

"...and excellent source for support... Kind of like having your very own IT dept." Electriciansnet

Testimonials

"I was apprehensive at signing up at first. However... it has already made my life as an IT administrator much easier." JaCrews

Testimonials

"WOW! You guys have great, active, and knowledgeable people on here." moore50

Business Clients

Business Clients

In the Press

"If you’ve got a question... Experts Exchange can supply an answer.”

In the Press

"...an invaluable aid for both IT professionals and those who require tech support."

In the Press

"where IT professionals provide quick answers on just about any topic"

Business Account Plans

Loading Advertisement...