Click here to monitor SSC
SQLServerCentral is supported by Red Gate Software Ltd.
 
Log in  ::  Register  ::  Not logged in
 
 
 
        
Home       Members    Calendar    Who's On


Add to briefcase ««1234»»»

Monitoring Disk Space and Sending Alerts with TSQL Expand / Collapse
Author
Message
Posted Friday, September 14, 2007 8:18 AM
Grasshopper

GrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopper

Group: General Forum Members
Last Login: Wednesday, October 26, 2011 8:44 AM
Points: 11, Visits: 81
I have a number of servers that I need to monitor, both SQL Server 2000 and 2005.  I use similar code with an SSIS package to collect this information from all my servers to one database on one server.  SQL Server magazine had some articles (http://www.sqlmag.com/Articles/ArticleID/95385/95385.html and http://www.sqlmag.com/Articles/ArticleID/95745/95745.html) that had information on how to set this up.  Of course, you need a subscription to the magazine to read the articles.
Post #399324
Posted Friday, September 14, 2007 8:29 AM


SSCrazy

SSCrazySSCrazySSCrazySSCrazySSCrazySSCrazySSCrazySSCrazy

Group: General Forum Members
Last Login: Friday, April 18, 2014 12:38 PM
Points: 2,290, Visits: 2,545

I saw the same problem. You can also click the "Print This!" button at the top of the article, and the print format has the word wrap on.

HTH,
webrunner



-------------------
"Operator! Give me the number for 911!" - Homer Simpson

"A SQL query walks into a bar and sees two tables. He walks up to them and says 'Can I join you?'"
Ref.: http://tkyte.blogspot.com/2009/02/sql-joke.html
Post #399330
Posted Friday, September 14, 2007 9:24 AM
Mr or Mrs. 500

Mr or Mrs. 500Mr or Mrs. 500Mr or Mrs. 500Mr or Mrs. 500Mr or Mrs. 500Mr or Mrs. 500Mr or Mrs. 500Mr or Mrs. 500

Group: General Forum Members
Last Login: Thursday, April 17, 2014 5:28 PM
Points: 564, Visits: 3,414

Hi Bob,

If you are using Windows 2003 you can use WMI to get the mountpoint information that you need. Check out the Win32_Volume Class: 

http://msdn2.microsoft.com/en-us/library/aa394515.aspx

Also you can query any 2003 box remotely using this class.

 

Andy

Post #399358
Posted Friday, September 14, 2007 9:40 AM
Hall of Fame

Hall of FameHall of FameHall of FameHall of FameHall of FameHall of FameHall of FameHall of FameHall of Fame

Group: General Forum Members
Last Login: Thursday, December 26, 2013 9:45 AM
Points: 3,475, Visits: 577

Andy,

with WMI you have to be an admin on the server to use it.




Regards,
Yelena Varshal

Post #399366
Posted Wednesday, September 19, 2007 9:28 AM


Ten Centuries

Ten CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen Centuries

Group: General Forum Members
Last Login: Wednesday, December 11, 2013 10:28 AM
Points: 1,153, Visits: 541

This is a very useful script.  I have been looking for something like this.  However, can you tell me how to use database mail rather than xp_sendmail since "this feature will be removed in a future version of Microsoft SQL Server. Avoid using this feature in new development work, and plan to modify applications that currently use this feature.. To send mail from SQL Server, use Database Mail." (SQL Server 2005 Books Online)

Thanks!

Post #400412
Posted Tuesday, September 25, 2007 9:11 AM
Forum Newbie

Forum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum Newbie

Group: General Forum Members
Last Login: Wednesday, August 21, 2013 9:19 AM
Points: 1, Visits: 128
Bob,
We have a similar requirement to monitor mount points I would like to look at how you have used chkdisk and parsed the results. My email id is jullietl@yahoo.com.

thanks
Post #402623
Posted Monday, October 01, 2007 7:51 PM
Grasshopper

GrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopper

Group: General Forum Members
Last Login: Monday, October 01, 2007 9:22 PM
Points: 11, Visits: 4
I am new to SQL2005. I received the following error when execute the SP

(3 row(s) affected)
Msg 15281, Level 16, State 1, Procedure xp_sendmail, Line 1
SQL Server blocked access to procedure 'sys.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 can enable the use of 'SQL Mail XPs' by using sp_configure. For more information about enabling 'SQL Mail XPs', see "Surface Area Configuration" in SQL Server Books Online.
Msg 15281, Level 16, State 1, Procedure xp_sendmail, Line 1
SQL Server blocked access to procedure 'sys.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 can enable the use of 'SQL Mail XPs' by using sp_configure. For more information about enabling 'SQL Mail XPs', see "Surface Area Configuration" in SQL Server Books Online.

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
Post #405338
Posted Monday, October 01, 2007 7:53 PM
Grasshopper

GrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopper

Group: General Forum Members
Last Login: Monday, October 01, 2007 9:22 PM
Points: 11, Visits: 4
I am new to SQL2005. I received the following error when execute the SP

(3 row(s) affected)
-- Msg 15281, Level 16, State 1, Procedure xp_sendmail, Line 1
-- SQL Server blocked access to procedure 'sys.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 --- can enable the use of 'SQL Mail XPs' by using sp_configure. For more information about --- --
-- enabling 'SQL -- Mail XPs', see "Surface Area Configuration" in SQL Server Books Online.
-- Msg 15281, Level 16, State 1, Procedure xp_sendmail, Line 1
-- SQL Server blocked access to procedure 'sys.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 -
-- can enable the use of 'SQL Mail XPs' by using sp_configure. For more information about --
-- ng 'SQL -- l XPs', see "Surface Area Configuration" in SQL Server Books Online.

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
Post #405339
Posted Monday, October 01, 2007 7:53 PM
Grasshopper

GrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopper

Group: General Forum Members
Last Login: Monday, October 01, 2007 9:22 PM
Points: 11, Visits: 4
I am new to SQL2005. I received the following error when execute the SP

(3 row(s) affected)
-- Msg 15281, Level 16, State 1, Procedure xp_sendmail, Line 1
-- SQL Server blocked access to procedure 'sys.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 --- can enable the use of 'SQL Mail XPs' by using sp_configure. For more information about --- --
-- enabling 'SQL -- Mail XPs', see "Surface Area Configuration" in SQL Server Books Online.
-- Msg 15281, Level 16, State 1, Procedure xp_sendmail, Line 1
-- SQL Server blocked access to procedure 'sys.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 -
-- can enable the use of 'SQL Mail XPs' by using sp_configure. For more information about --
-- ng 'SQL -- l XPs', see "Surface Area Configuration" in SQL Server Books Online
.

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
Post #405340
Posted Monday, October 01, 2007 7:53 PM
Grasshopper

GrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopper

Group: General Forum Members
Last Login: Monday, October 01, 2007 9:22 PM
Points: 11, Visits: 4
I am new to SQL2005. I received the following error when execute the SP

(3 row(s) affected)
-- Msg 15281, Level 16, State 1, Procedure xp_sendmail, Line 1
-- SQL Server blocked access to procedure 'sys.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 --- can enable the use of 'SQL Mail XPs' by using sp_configure. For more information about --- --
-- enabling 'SQL -- Mail XPs', see "Surface Area Configuration" in SQL Server Books Online.
-- Msg 15281, Level 16, State 1, Procedure xp_sendmail, Line 1
-- SQL Server blocked access to procedure 'sys.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 -
-- can enable the use of 'SQL Mail XPs' by using sp_configure. For more information about --
-- ng 'SQL -- l XPs', see "Surface Area Configuration" in SQL Server Books Online
.


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
Post #405341
« Prev Topic | Next Topic »

Add to briefcase ««1234»»»

Permissions Expand / Collapse