DBCC CHECKDB for all databases in a server

  • Can I do DBCC CHECKDB for all the databases in a server at atime? which options can I use for no down time of server and how much time does it take ,if I do for like 10 databases in a server?

    Can I schedule DBCC CHECKDB for regular basis? If so how can I do it?

  • For the scheduling, you can make use Job Scheduler under SQL Server Agent available in SQL Server. Did yoy think about the server resources ?

    Books-online

    DBCC CHECKDB is a CPU- and disk-intensive operation. Each data page that requires checking must first be read from disk into memory. In addition, DBCC CHECKDB uses tempdb to do sorting.

    If actively performing transactions while DBCC CHECKDB is running, the transaction log continues to grow because the DBCC command blocks log truncation until it has finished reading the log.

    It is recommended that DBCC CHECKDB be run during hours when the load is light on the server. If DBCC CHECKDB is run during heavy peak usage time, expect a performance hit on the transaction throughput as well as DBCC CHECKDB completion time.

    What is the purpose of doing DBCC CHECKDB in all databases in the same server ?

  • >> What is the purpose of doing DBCC CHECKDB in all databases in the same server ?

    I didn't get that.

    I want to check whether the Indexes are upto date. If not rebuild them.

  • To achieve this, you may go for DBCC DBREINDEX.

    Please try this command on the target table.

    It is faster and more efficient since you are running for several databases.

     

Viewing 4 posts - 1 through 3 (of 3 total)

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