SQL Server Health monitoring tool

  • Hello

    For Oracle we have OEM (Oracle Enterprise Manager). I would appreciate if any of you can let me know the following ( i am new to this SQL Server stuff)

    1. what Tool i can use for Health Checking of the SQL Server database

    2. Does this tool scan the logs for any errors etc

    TIA

    SQL Sever Newbee

  • For db health check have a look at "dbcc checkdb" (not GUI, but T-SQL). http://msdn2.microsoft.com/en-us/library/aa258278(SQL.80).aspx

    it does not go through the error log, but writes there too if there is an error.

    Concerning error logs, you can check them via: Enterprise Manager -> Management->Error Logs (I assume you are using SQL Server 2000)

    Andras


    Andras Belokosztolszki, MCPD, PhD
    GoldenGate Software

  • Thank you Andras. Is there a way to avoid manual checking. Since it will not be possible to keep checking the error log manually frequently, is there any tool which can scan for any errors?

    Would appreciate any feedback.

    Thanks

  • Enerprise Manager is very similar to Oracle's Enterprise Manager.  Look into the Agent.  You can configure all sorts of alerts that look for Errors, performance conditions, etc. 

    Read the Books On Line (BOL) You will find what you need.

  • For SQL Server 2000, I use a windows script to check for errors in the error logs and send an e-mail if errors are found.  I converted an old unix script I had to check Oracle alert logs for ORA- errors, it works the same way.  You can also use Embarcadero's DBArtisan. 

    For SQL Server 2005, Management Studio will work just as well.

  • I also just saw this featured script on the post which may be helpful:

    http://www.sqlservercentral.com/scripts/viewscript.asp?scriptid=1925

  • Hello Ronda

    How do you mail / page the dba. There is no mailx equivalent in windows AFAIK. Would you mind sharing the script you are using?

    Thanks

  • Here's the script that I found on this site:

    Can anyone show me how to generate an error as I'm trying to test this script on a test box?

     

    If exists(select * from dbo.sysobjects where id = object_id(N'Verifyerrorlog') and OBJECTPROPERTY(id, N'IsProcedure') = 1)

    drop procedure Verifyerrorlog

    go

    CREATE proc Verifyerrorlog

    as

    begin

    set nocount on

    set quoted_identifier off

    /* Procedure to scan past one hour errorlog for the keyword "Error"

    --Vidhya Sagar--kvs1983@gmail.com

    --This procedure is for Sqlserver 2000

    */

    --TABLE TO COPY ALL DESCRIPTION FROM CURRENT ERRORLOG FILE

    declare @curdate varchar(25)

    set @curdate = datepart(hh,getdate())

    CREATE TABLE #fullerrlog(Description varchar(500) Not null,contin bit)

    insert #fullerrlog

    exec master..xp_readerrorlog

    set rowcount 7

    delete #fullerrlog

    set rowcount 0

    delete #fullerrlog where substring(description,12,2)<>@curdate-1

    delete #fullerrlog where description not like ('%error%')

    select * from #fullerrlog

    drop TABLE #fullerrlog

    end

Viewing 8 posts - 1 through 7 (of 7 total)

You must be logged in to reply to this topic. Login to reply