Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

DBCC Check Entire Server 2

Status
Not open for further replies.

Skittle

ISP
Sep 10, 2002
1,528
US
I seem to recall seeing somehere you can issue a DBCC Check command to check all databases on a server. I can only find DBCC commands that refer to a single database or subsets of a database ( DBCC CHECKDB etc. ).

Anybody know this one or is it all in my imagination?

Dazed and confused
 
you can run DBCC CHECKDB for each db.
Code:
Exec sp_MSForEachDB @command1 = 'DBCC CHECKDB'

- Paul
- If at first you don't succeed, find out if the loser gets anything.
 
But it will HAMMER your server and lock each DB in turn - if you have a lot (> 25) DBs on your instance it can take possibly longer than your maintenance window - also beware of using undocumented features as they can be dropped at any time, within any service pack...
Just my 5 penneth worth
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top