Home All Groups Group Topic Archive Search About

the alert couldn't send an email



Author
10 Dec 2008 5:02 AM
Iter
Hi Guys,
I have a question regarding alert in sql server 2005. I created an alert
which sends an email when the data file exceed the size. The alert didn't
send an email out when the data file exceed the size. In the biginning I got
error from sql server agent log file: [264] An attempt was made to send an
email when no email session has been established. I restart sql server agent,
but I still cannot send email out, but the error in sql server agent log was
disappeared. It is weird that I found it was sent by net send in operator
history. But I didn't setup any place as by net send, all I set are by
e-mail. Why it was said by net send. Could some body give me hint what was
problem? Thanks.

Author
10 Dec 2008 9:01 AM
Uri Dimant
Iter
Antivirus blocks maybe?



Show quoteHide quote
"Iter" <I***@discussions.microsoft.com> wrote in message
news:071539CE-68B3-40EB-AE33-99920F44AFC0@microsoft.com...
> Hi Guys,
> I have a question regarding alert in sql server 2005. I created an alert
> which sends an email when the data file exceed the size. The alert didn't
> send an email out when the data file exceed the size. In the biginning I
> got
> error from sql server agent log file: [264] An attempt was made to send an
> email when no email session has been established. I restart sql server
> agent,
> but I still cannot send email out, but the error in sql server agent log
> was
> disappeared. It is weird that I found it was sent by net send in operator
> history. But I didn't setup any place as by net send, all I set are by
> e-mail. Why it was said by net send. Could some body give me hint what was
> problem? Thanks.
Are all your drivers up to date? click for free checkup

Author
10 Dec 2008 9:39 AM
Tibor Karaszi
What mail subsystem are you using? SQL Mail or Database Mail? Did you
create a mail Profile? Did you configure SQL Agent to use that Mail
Profile?

Show quoteHide quote
"Iter" <I***@discussions.microsoft.com> wrote in message
news:071539CE-68B3-40EB-AE33-99920F44AFC0@microsoft.com...
> Hi Guys,
> I have a question regarding alert in sql server 2005. I created an
> alert
> which sends an email when the data file exceed the size. The alert
> didn't
> send an email out when the data file exceed the size. In the
> biginning I got
> error from sql server agent log file: [264] An attempt was made to
> send an
> email when no email session has been established. I restart sql
> server agent,
> but I still cannot send email out, but the error in sql server agent
> log was
> disappeared. It is weird that I found it was sent by net send in
> operator
> history. But I didn't setup any place as by net send, all I set are
> by
> e-mail. Why it was said by net send. Could some body give me hint
> what was
> problem? Thanks.
Author
10 Dec 2008 3:19 PM
Iter
Thanks you guys.
1. I use database mail and already created a mail Profile? I did configure
SQL Agent to use that Mail Profile and enabled.
2. I can use  msdb.dbo.sp_send_dbmail to send email and successful.

The weird is that it said sent by net send when I checked history info in
mail  operator. But I didn't setup any place as by net send, all I set are by
e-mail. Why was it said by net send.

Thanks.


Show quoteHide quote
"Tibor Karaszi" wrote:

> What mail subsystem are you using? SQL Mail or Database Mail? Did you
> create a mail Profile? Did you configure SQL Agent to use that Mail
> Profile?
>
> --
> Tibor Karaszi, SQL Server MVP
> http://www.karaszi.com/sqlserver/default.asp
> http://sqlblog.com/blogs/tibor_karaszi
>
>
> "Iter" <I***@discussions.microsoft.com> wrote in message
> news:071539CE-68B3-40EB-AE33-99920F44AFC0@microsoft.com...
> > Hi Guys,
> > I have a question regarding alert in sql server 2005. I created an
> > alert
> > which sends an email when the data file exceed the size. The alert
> > didn't
> > send an email out when the data file exceed the size. In the
> > biginning I got
> > error from sql server agent log file: [264] An attempt was made to
> > send an
> > email when no email session has been established. I restart sql
> > server agent,
> > but I still cannot send email out, but the error in sql server agent
> > log was
> > disappeared. It is weird that I found it was sent by net send in
> > operator
> > history. But I didn't setup any place as by net send, all I set are
> > by
> > e-mail. Why it was said by net send. Could some body give me hint
> > what was
> > problem? Thanks.
>
>
>
Author
10 Dec 2008 7:01 PM
jd_nospam
I ran into something like this.  You also have to turn on alerts for
the agent (not just the profile setup).


These are my per server SQL Agent job notification setup steps:

1. setup a database mail profile/account

2. setup an sqlagent operator

3. turn on alerts in the sqlagent properties (http://
msdn.microsoft.com/en-us/library/ms186358(SQL.90).aspx) - see below




http://msdn.microsoft.com/en-us/library/ms186358(SQL.90).aspx
To set up SQL Server Agent Mail to use Database Mail
In Object Explorer, expand a server.

Right-click SQL Server Agent, and then click Properties.

Click Alert System.

Select Enable Mail Profile.

In the Mail system list, select Database Mail.

In the Mail profile list, select a mail profile for Database Mail.

Restart SQL Server Agent.



-jb

Bookmark and Share