SQL Clone
SQLServerCentral is supported by Redgate
 
Log in  ::  Register  ::  Not logged in
 
 
 


Monitoring Disk Space and Sending Alerts with TSQL


Monitoring Disk Space and Sending Alerts with TSQL

Author
Message
gbgykkcci00000-r
gbgykkcci00000-r
SSC Rookie
SSC Rookie (39 reputation)SSC Rookie (39 reputation)SSC Rookie (39 reputation)SSC Rookie (39 reputation)SSC Rookie (39 reputation)SSC Rookie (39 reputation)SSC Rookie (39 reputation)SSC Rookie (39 reputation)

Group: General Forum Members
Points: 39 Visits: 4
I am new to SQL2005. I received the following error when execute the SP



-- Msg 15281, Level 16, State 1, Procedure xp_sendmail, Line 1

-- SQL Server blocked access to procedure 'ys.xp_sendmail' of component 'SQL Mail XPs' because this -

-- component is turned off as part of the security configuration for this server. A system administrator -



I check on the Help inside the SQL2005 and it warn us not to use the SQL_Mail but use the Database Mail instead and I have successfully configurated the SMTP database Mail. However, how can I change the SP to use the Database Mail instead of the SQL sendMail



Thanks
gbgykkcci00000-r
gbgykkcci00000-r
SSC Rookie
SSC Rookie (39 reputation)SSC Rookie (39 reputation)SSC Rookie (39 reputation)SSC Rookie (39 reputation)SSC Rookie (39 reputation)SSC Rookie (39 reputation)SSC Rookie (39 reputation)SSC Rookie (39 reputation)

Group: General Forum Members
Points: 39 Visits: 4
I am new to SQL2005. I received the following error when execute the SP



-- Msg 15281, Level 16, State 1, Procedure !!!!x!!!!p_sendmail, Line 1

-- SQL Server blocked access to procedure '!!!!y!!!!s.xp_sendmail' of component 'SQL Mail XPs' because this -

-- component is turned off as part of the security configuration for this server. A system administrator -



I check on the Help inside the SQL2005 and it warn us not to use the SQL_Mail but use the Database Mail instead and I have successfully configurated the SMTP database Mail. However, how can I change the SP to use the Database Mail instead of the SQL sendMail



Thanks
gbgykkcci00000-r
gbgykkcci00000-r
SSC Rookie
SSC Rookie (39 reputation)SSC Rookie (39 reputation)SSC Rookie (39 reputation)SSC Rookie (39 reputation)SSC Rookie (39 reputation)SSC Rookie (39 reputation)SSC Rookie (39 reputation)SSC Rookie (39 reputation)

Group: General Forum Members
Points: 39 Visits: 4
I am new to SQL2005. I received the following error when execute the SP



I check on the Help inside the SQL2005 and it warn us not to use the SQL_Mail but use the Database Mail instead and I have successfully configurated the SMTP database Mail. However, how can I change the SP to use the Database Mail instead of the SQL sendMail



Thanks
gbgykkcci00000-r
gbgykkcci00000-r
SSC Rookie
SSC Rookie (39 reputation)SSC Rookie (39 reputation)SSC Rookie (39 reputation)SSC Rookie (39 reputation)SSC Rookie (39 reputation)SSC Rookie (39 reputation)SSC Rookie (39 reputation)SSC Rookie (39 reputation)

Group: General Forum Members
Points: 39 Visits: 4
I am new to SQL2005. I received the following error when execute the SP



I check on the Help inside the SQL2005 and it warn us not to use the SQL_Mail but use the Database Mail instead and I have successfully configurated the SMTP database Mail. However, how can I change the SP to use the Database Mail instead of the SQL sendMail



Thanks
gbgykkcci00000-r
gbgykkcci00000-r
SSC Rookie
SSC Rookie (39 reputation)SSC Rookie (39 reputation)SSC Rookie (39 reputation)SSC Rookie (39 reputation)SSC Rookie (39 reputation)SSC Rookie (39 reputation)SSC Rookie (39 reputation)SSC Rookie (39 reputation)

Group: General Forum Members
Points: 39 Visits: 4
I am new to SQL2005. I received the following error when execute the SP



I check on the Help inside the SQL2005 and it warn us not to use the SQL_Mail but use the Database Mail instead and I have successfully configurated the SMTP database Mail. However, how can I change the SP to use the Database Mail instead of the SQL sendMail



Thanks
gbgykkcci00000-r
gbgykkcci00000-r
SSC Rookie
SSC Rookie (39 reputation)SSC Rookie (39 reputation)SSC Rookie (39 reputation)SSC Rookie (39 reputation)SSC Rookie (39 reputation)SSC Rookie (39 reputation)SSC Rookie (39 reputation)SSC Rookie (39 reputation)

Group: General Forum Members
Points: 39 Visits: 4
I am new to SQL2005. I received the following error when execute the SP



I check on the Help inside the SQL2005 and it warn us not to use the SQL_Mail but use the Database Mail instead and I have successfully configurated the SMTP database Mail. However, how can I change the SP to use the Database Mail instead of the SQL sendMail



Thanks
dt293
dt293
SSC-Enthusiastic
SSC-Enthusiastic (154 reputation)SSC-Enthusiastic (154 reputation)SSC-Enthusiastic (154 reputation)SSC-Enthusiastic (154 reputation)SSC-Enthusiastic (154 reputation)SSC-Enthusiastic (154 reputation)SSC-Enthusiastic (154 reputation)SSC-Enthusiastic (154 reputation)

Group: General Forum Members
Points: 154 Visits: 698
For anyone else who needs to modify the script to use SQL 2005 dbmail just change (assuming db mail is correctly set up already)....

EXEC master..xp_sendmail @recipients = 'email@domain.com',
@subject = @MailSubject,
@message = @AlertMessage
to
EXEC msdb..sp_send_dbmail @recipients = 'email@domain.com',
@subject = @MailSubject,
@body = @AlertMessage
DBA-640728
DBA-640728
Ten Centuries
Ten Centuries (1.1K reputation)Ten Centuries (1.1K reputation)Ten Centuries (1.1K reputation)Ten Centuries (1.1K reputation)Ten Centuries (1.1K reputation)Ten Centuries (1.1K reputation)Ten Centuries (1.1K reputation)Ten Centuries (1.1K reputation)

Group: General Forum Members
Points: 1129 Visits: 1995
hello, thank you for your script, question how can i run with my other servers?
DBA-640728
DBA-640728
Ten Centuries
Ten Centuries (1.1K reputation)Ten Centuries (1.1K reputation)Ten Centuries (1.1K reputation)Ten Centuries (1.1K reputation)Ten Centuries (1.1K reputation)Ten Centuries (1.1K reputation)Ten Centuries (1.1K reputation)Ten Centuries (1.1K reputation)

Group: General Forum Members
Points: 1129 Visits: 1995
hi how can i edit this sp so i get also the percentage? and modify the alert if i have less than 10%? Crying
daniel-471430
daniel-471430
Grasshopper
Grasshopper (14 reputation)Grasshopper (14 reputation)Grasshopper (14 reputation)Grasshopper (14 reputation)Grasshopper (14 reputation)Grasshopper (14 reputation)Grasshopper (14 reputation)Grasshopper (14 reputation)

Group: General Forum Members
Points: 14 Visits: 13
I've read the helpful comments here.
i am using it in a similar way.
but how can i read the sizes of mount points?
thanks for your help!
cheers
daniel
Go


Permissions

You can't post new topics.
You can't post topic replies.
You can't post new polls.
You can't post replies to polls.
You can't edit your own topics.
You can't delete your own topics.
You can't edit other topics.
You can't delete other topics.
You can't edit your own posts.
You can't edit other posts.
You can't delete your own posts.
You can't delete other posts.
You can't post events.
You can't edit your own events.
You can't edit other events.
You can't delete your own events.
You can't delete other events.
You can't send private messages.
You can't send emails.
You can read topics.
You can't vote in polls.
You can't upload attachments.
You can download attachments.
You can't post HTML code.
You can't edit HTML code.
You can't post IFCode.
You can't post JavaScript.
You can post emoticons.
You can't post or upload images.

Select a forum

































































































































































SQLServerCentral


Search