Can someone explain what the differences are between the DBCC
CHECKDB(XXXX) WITH PHYSICAL_ONLY verses the DBCC CHECKALLOC()?
If you could run one of these, which one and why?
Our production SAP database is too large and the impact of the DBCC is
too great on a daily basis. So, we are going to run a full CHECKDB
only weekly. However, for "comfort zone", we would at least like to
verify the database structure daily during night hours.
They both appear to be similar by reading the books.
thanks
SteveHi Steve,
DBCC CHECKALLOC checks allocation and page usage in a database, including
indexed views. The NOINDEX option, used only for backward compatibility,
also applies to indexed views.
DBCC CHECKDB performs a physical consistency check on indexed views. The
NOINDEX option, used only for backward compatibility, also applies to any
secondary indexes on indexed views.
CheckdB PHYSICAL_ONLY limits the checking to the integrity of the physical
structure of the page and record headers, and to the consistency between
the pages' object ID and index ID and the allocation structures. Designed
to provide a low overhead check of the physical consistency of the
database, this check also detects torn pages and common hardware failures
that can compromise a user's data.
It is not necessary to execute DBCC CHECKALLOC if DBCC CHECKDB has already
been executed. DBCC CHECKDB is a superset of DBCC CHECKALLOC and includes
allocation checks in addition to checks of index structure and data
integrity.
DBCC CHECKDB is the safest repair statement because it identifies and
repairs the widest possible range of errors. If only allocation errors are
reported for a database, execute DBCC CHECKALLOC with a repair option to
correct them. However, to ensure that all errors (including allocation
errors) are repaired properly, execute DBCC CHECKDB with a repair option.
DBCC CHECKALLOC messages are sorted by object ID, except for those messages
generated from tempdb. DBCC CHECKALLOC validates the allocation of all data
pages in the database while DBCC CHECKDB validates the page information
used in the storage of data in addition to validating the allocation
information.
DBCC CHECKDB validates the integrity of everything in a database. There is
no need to run DBCC CHECKALLOC or DBCC CHECKTABLE if DBCC CHECKDB either is
currently or has been recently executed.
DBCC CHECKDB performs the same checking as if both a DBCC CHECKALLOC
statement and a DBCC CHECKTABLE statement were executed for each table in
the database.
For more information regarding this issue please refer to the following
article on SQL Server Books Online.
Topic: "DBCC CHECKALLOC"
Topic: "DBCC CHECKDB"
Please feel free to post in the group if this solves your problem or if you
would like further assistance.
Regards,
Michael Shao
Microsoft Online Partner Support
Get Secure! - www.microsoft.com/security
This posting is provided "as is" with no warranties and confers no rights.|||Hi Steve,
To greatly simplify what Michael posted, you should run DBCC CHECKDB WITH
PHYSICAL_ONLY. It performs a DBCC CHECKALLOC (which is very fast) and then
page audits of every allocated page in the database. This will catch gross
page corruptions and torn pages (as long as the page has been written since
torn page detection was enabled), but not subtle corruptions that may affect
the finer logical consistency of b-trees and so on.
Let me know if you have any further questions.
Regards,
Paul.
--
Paul Randal
DBCC Technical Lead, Microsoft SQL Server Storage Engine
This posting is provided "AS IS" with no warranties, and confers no rights.
"Steve Myers" <stephencmyers@.hotmail.com> wrote in message
news:3e0c4493.0311051955.140ac3e6@.posting.google.com...
> Can someone explain what the differences are between the DBCC
> CHECKDB(XXXX) WITH PHYSICAL_ONLY verses the DBCC CHECKALLOC()?
> If you could run one of these, which one and why?
> Our production SAP database is too large and the impact of the DBCC is
> too great on a daily basis. So, we are going to run a full CHECKDB
> only weekly. However, for "comfort zone", we would at least like to
> verify the database structure daily during night hours.
> They both appear to be similar by reading the books.
> thanks
> Steve
Showing posts with label checkalloc. Show all posts
Showing posts with label checkalloc. Show all posts
Sunday, February 19, 2012
dbcc checkdb not needed?
"With SQL Server 2000, you're no longer required to run DBCC CHECKDB or DBCC
CHECKALLOC statements. The latest version of SQL Server automatically detects
damaged pages and fixes them. Ninety-nine percent of database corruption with
SQL Server 2000 happens due to hardware failures."
I read that on http://www.informit.com/articles/printerfriendly.asp?p=27784 and
I'm looking for confirmation if it's true or not?
I've searched in BOI for confirmation without success.
Thanks in advance,
Craig.That's not quite true. If you have torn pgedetection turned on (the
default) it can detect torn pages. But there are things DBCC CHECKDB can
detect other than that and should be run on a regular basis for reassurance.
You don't need to run CheckAlloc as it is already included in checkdb but
you should run CheckCatalog.
--
Andrew J. Kelly SQL MVP
"Craig" <spam@.[at]thehurley.[dot]com> wrote in message
news:ecTMYtxAEHA.2480@.TK2MSFTNGP11.phx.gbl...
> "With SQL Server 2000, you're no longer required to run DBCC CHECKDB or
DBCC
> CHECKALLOC statements. The latest version of SQL Server automatically
detects
> damaged pages and fixes them. Ninety-nine percent of database corruption
with
> SQL Server 2000 happens due to hardware failures."
> I read that on
http://www.informit.com/articles/printerfriendly.asp?p=27784 and
> I'm looking for confirmation if it's true or not?
> I've searched in BOI for confirmation without success.
> Thanks in advance,
> Craig.
CHECKALLOC statements. The latest version of SQL Server automatically detects
damaged pages and fixes them. Ninety-nine percent of database corruption with
SQL Server 2000 happens due to hardware failures."
I read that on http://www.informit.com/articles/printerfriendly.asp?p=27784 and
I'm looking for confirmation if it's true or not?
I've searched in BOI for confirmation without success.
Thanks in advance,
Craig.That's not quite true. If you have torn pgedetection turned on (the
default) it can detect torn pages. But there are things DBCC CHECKDB can
detect other than that and should be run on a regular basis for reassurance.
You don't need to run CheckAlloc as it is already included in checkdb but
you should run CheckCatalog.
--
Andrew J. Kelly SQL MVP
"Craig" <spam@.[at]thehurley.[dot]com> wrote in message
news:ecTMYtxAEHA.2480@.TK2MSFTNGP11.phx.gbl...
> "With SQL Server 2000, you're no longer required to run DBCC CHECKDB or
DBCC
> CHECKALLOC statements. The latest version of SQL Server automatically
detects
> damaged pages and fixes them. Ninety-nine percent of database corruption
with
> SQL Server 2000 happens due to hardware failures."
> I read that on
http://www.informit.com/articles/printerfriendly.asp?p=27784 and
> I'm looking for confirmation if it's true or not?
> I've searched in BOI for confirmation without success.
> Thanks in advance,
> Craig.
Tuesday, February 14, 2012
DBCC CheckDB and CheckAlloc
I've recently joined an organization which has no practice of regularly
running DBCC's with the explanation provided that since SQL Server is now
file based and many improvements have been made to the file system, that file
corruption/database corruption including allocation issues are no longer a
threat. That DBCC's are a holdover from Sybases use of raw partitions for
storing it's databases.
Anyone care to comment on that?
I can think of hardware issues that might cause problems that this would
catch.
Any recommendations or whitepapers or links supporting use of DBCC's would
be appreciated.
Running sql 2000 Enterprise on Win Srvr 2003 Enterprise.
thanksI recall recommendations from MS and others when the new architecture (7.0) was released with such
statements. They are absolutely right that improvements were huge.
But as you know, other things can also happen, so we definitely want to run DBCC CHECKDB and
CHECKCATALOG (CHECKCATALOG is included in CHECKDB in 2005). No need for CHECKALLOG if you run
CHECKDB, though. CHECKALLOG is included in CHECKDB as of 7.0.
I'm sure there are good articles. I'd search Google and KB. I've might even listed some here:
http://www.karaszi.com/SQLServer/msarticles.asp. Don't forget Books Online (make sure you have most
recent version). Perhaps other will jump in with specific links.
--
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
Blog: http://solidqualitylearning.com/blogs/tibor/
"Tom Frost" <TomFrost@.discussions.microsoft.com> wrote in message
news:AF1B2648-0D01-44EE-B761-E024A21F443D@.microsoft.com...
> I've recently joined an organization which has no practice of regularly
> running DBCC's with the explanation provided that since SQL Server is now
> file based and many improvements have been made to the file system, that file
> corruption/database corruption including allocation issues are no longer a
> threat. That DBCC's are a holdover from Sybases use of raw partitions for
> storing it's databases.
> Anyone care to comment on that?
> I can think of hardware issues that might cause problems that this would
> catch.
> Any recommendations or whitepapers or links supporting use of DBCC's would
> be appreciated.
> Running sql 2000 Enterprise on Win Srvr 2003 Enterprise.
> thanks
running DBCC's with the explanation provided that since SQL Server is now
file based and many improvements have been made to the file system, that file
corruption/database corruption including allocation issues are no longer a
threat. That DBCC's are a holdover from Sybases use of raw partitions for
storing it's databases.
Anyone care to comment on that?
I can think of hardware issues that might cause problems that this would
catch.
Any recommendations or whitepapers or links supporting use of DBCC's would
be appreciated.
Running sql 2000 Enterprise on Win Srvr 2003 Enterprise.
thanksI recall recommendations from MS and others when the new architecture (7.0) was released with such
statements. They are absolutely right that improvements were huge.
But as you know, other things can also happen, so we definitely want to run DBCC CHECKDB and
CHECKCATALOG (CHECKCATALOG is included in CHECKDB in 2005). No need for CHECKALLOG if you run
CHECKDB, though. CHECKALLOG is included in CHECKDB as of 7.0.
I'm sure there are good articles. I'd search Google and KB. I've might even listed some here:
http://www.karaszi.com/SQLServer/msarticles.asp. Don't forget Books Online (make sure you have most
recent version). Perhaps other will jump in with specific links.
--
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
Blog: http://solidqualitylearning.com/blogs/tibor/
"Tom Frost" <TomFrost@.discussions.microsoft.com> wrote in message
news:AF1B2648-0D01-44EE-B761-E024A21F443D@.microsoft.com...
> I've recently joined an organization which has no practice of regularly
> running DBCC's with the explanation provided that since SQL Server is now
> file based and many improvements have been made to the file system, that file
> corruption/database corruption including allocation issues are no longer a
> threat. That DBCC's are a holdover from Sybases use of raw partitions for
> storing it's databases.
> Anyone care to comment on that?
> I can think of hardware issues that might cause problems that this would
> catch.
> Any recommendations or whitepapers or links supporting use of DBCC's would
> be appreciated.
> Running sql 2000 Enterprise on Win Srvr 2003 Enterprise.
> thanks
Labels:
checkalloc,
checkdb,
database,
dbcc,
explanation,
microsoft,
mysql,
oracle,
organization,
practice,
provided,
regularly,
running,
server,
sql
DBCC CheckDB and CheckAlloc
I've recently joined an organization which has no practice of regularly
running DBCC's with the explanation provided that since SQL Server is now
file based and many improvements have been made to the file system, that fil
e
corruption/database corruption including allocation issues are no longer a
threat. That DBCC's are a holdover from Sybases use of raw partitions for
storing it's databases.
Anyone care to comment on that?
I can think of hardware issues that might cause problems that this would
catch.
Any recommendations or whitepapers or links supporting use of DBCC's would
be appreciated.
Running sql 2000 Enterprise on Win Srvr 2003 Enterprise.
thanksI recall recommendations from MS and others when the new architecture (7.0)
was released with such
statements. They are absolutely right that improvements were huge.
But as you know, other things can also happen, so we definitely want to run
DBCC CHECKDB and
CHECKCATALOG (CHECKCATALOG is included in CHECKDB in 2005). No need for CHEC
KALLOG if you run
CHECKDB, though. CHECKALLOG is included in CHECKDB as of 7.0.
I'm sure there are good articles. I'd search Google and KB. I've might even
listed some here:
http://www.karaszi.com/SQLServer/msarticles.asp. Don't forget Books Online (
make sure you have most
recent version). Perhaps other will jump in with specific links.
--
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
Blog: http://solidqualitylearning.com/blogs/tibor/
"Tom Frost" <TomFrost@.discussions.microsoft.com> wrote in message
news:AF1B2648-0D01-44EE-B761-E024A21F443D@.microsoft.com...
> I've recently joined an organization which has no practice of regularly
> running DBCC's with the explanation provided that since SQL Server is now
> file based and many improvements have been made to the file system, that f
ile
> corruption/database corruption including allocation issues are no longer a
> threat. That DBCC's are a holdover from Sybases use of raw partitions for
> storing it's databases.
> Anyone care to comment on that?
> I can think of hardware issues that might cause problems that this would
> catch.
> Any recommendations or whitepapers or links supporting use of DBCC's would
> be appreciated.
> Running sql 2000 Enterprise on Win Srvr 2003 Enterprise.
> thanks
running DBCC's with the explanation provided that since SQL Server is now
file based and many improvements have been made to the file system, that fil
e
corruption/database corruption including allocation issues are no longer a
threat. That DBCC's are a holdover from Sybases use of raw partitions for
storing it's databases.
Anyone care to comment on that?
I can think of hardware issues that might cause problems that this would
catch.
Any recommendations or whitepapers or links supporting use of DBCC's would
be appreciated.
Running sql 2000 Enterprise on Win Srvr 2003 Enterprise.
thanksI recall recommendations from MS and others when the new architecture (7.0)
was released with such
statements. They are absolutely right that improvements were huge.
But as you know, other things can also happen, so we definitely want to run
DBCC CHECKDB and
CHECKCATALOG (CHECKCATALOG is included in CHECKDB in 2005). No need for CHEC
KALLOG if you run
CHECKDB, though. CHECKALLOG is included in CHECKDB as of 7.0.
I'm sure there are good articles. I'd search Google and KB. I've might even
listed some here:
http://www.karaszi.com/SQLServer/msarticles.asp. Don't forget Books Online (
make sure you have most
recent version). Perhaps other will jump in with specific links.
--
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
Blog: http://solidqualitylearning.com/blogs/tibor/
"Tom Frost" <TomFrost@.discussions.microsoft.com> wrote in message
news:AF1B2648-0D01-44EE-B761-E024A21F443D@.microsoft.com...
> I've recently joined an organization which has no practice of regularly
> running DBCC's with the explanation provided that since SQL Server is now
> file based and many improvements have been made to the file system, that f
ile
> corruption/database corruption including allocation issues are no longer a
> threat. That DBCC's are a holdover from Sybases use of raw partitions for
> storing it's databases.
> Anyone care to comment on that?
> I can think of hardware issues that might cause problems that this would
> catch.
> Any recommendations or whitepapers or links supporting use of DBCC's would
> be appreciated.
> Running sql 2000 Enterprise on Win Srvr 2003 Enterprise.
> thanks
Labels:
checkalloc,
checkdb,
database,
dbcc,
explanation,
microsoft,
mysql,
oracle,
organization,
practice,
provided,
regularlyrunning,
server,
sql
DBCC CheckDB and CheckAlloc
I've recently joined an organization which has no practice of regularly
running DBCC's with the explanation provided that since SQL Server is now
file based and many improvements have been made to the file system, that file
corruption/database corruption including allocation issues are no longer a
threat. That DBCC's are a holdover from Sybases use of raw partitions for
storing it's databases.
Anyone care to comment on that?
I can think of hardware issues that might cause problems that this would
catch.
Any recommendations or whitepapers or links supporting use of DBCC's would
be appreciated.
Running sql 2000 Enterprise on Win Srvr 2003 Enterprise.
thanks
I recall recommendations from MS and others when the new architecture (7.0) was released with such
statements. They are absolutely right that improvements were huge.
But as you know, other things can also happen, so we definitely want to run DBCC CHECKDB and
CHECKCATALOG (CHECKCATALOG is included in CHECKDB in 2005). No need for CHECKALLOG if you run
CHECKDB, though. CHECKALLOG is included in CHECKDB as of 7.0.
I'm sure there are good articles. I'd search Google and KB. I've might even listed some here:
http://www.karaszi.com/SQLServer/msarticles.asp. Don't forget Books Online (make sure you have most
recent version). Perhaps other will jump in with specific links.
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
Blog: http://solidqualitylearning.com/blogs/tibor/
"Tom Frost" <TomFrost@.discussions.microsoft.com> wrote in message
news:AF1B2648-0D01-44EE-B761-E024A21F443D@.microsoft.com...
> I've recently joined an organization which has no practice of regularly
> running DBCC's with the explanation provided that since SQL Server is now
> file based and many improvements have been made to the file system, that file
> corruption/database corruption including allocation issues are no longer a
> threat. That DBCC's are a holdover from Sybases use of raw partitions for
> storing it's databases.
> Anyone care to comment on that?
> I can think of hardware issues that might cause problems that this would
> catch.
> Any recommendations or whitepapers or links supporting use of DBCC's would
> be appreciated.
> Running sql 2000 Enterprise on Win Srvr 2003 Enterprise.
> thanks
running DBCC's with the explanation provided that since SQL Server is now
file based and many improvements have been made to the file system, that file
corruption/database corruption including allocation issues are no longer a
threat. That DBCC's are a holdover from Sybases use of raw partitions for
storing it's databases.
Anyone care to comment on that?
I can think of hardware issues that might cause problems that this would
catch.
Any recommendations or whitepapers or links supporting use of DBCC's would
be appreciated.
Running sql 2000 Enterprise on Win Srvr 2003 Enterprise.
thanks
I recall recommendations from MS and others when the new architecture (7.0) was released with such
statements. They are absolutely right that improvements were huge.
But as you know, other things can also happen, so we definitely want to run DBCC CHECKDB and
CHECKCATALOG (CHECKCATALOG is included in CHECKDB in 2005). No need for CHECKALLOG if you run
CHECKDB, though. CHECKALLOG is included in CHECKDB as of 7.0.
I'm sure there are good articles. I'd search Google and KB. I've might even listed some here:
http://www.karaszi.com/SQLServer/msarticles.asp. Don't forget Books Online (make sure you have most
recent version). Perhaps other will jump in with specific links.
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
Blog: http://solidqualitylearning.com/blogs/tibor/
"Tom Frost" <TomFrost@.discussions.microsoft.com> wrote in message
news:AF1B2648-0D01-44EE-B761-E024A21F443D@.microsoft.com...
> I've recently joined an organization which has no practice of regularly
> running DBCC's with the explanation provided that since SQL Server is now
> file based and many improvements have been made to the file system, that file
> corruption/database corruption including allocation issues are no longer a
> threat. That DBCC's are a holdover from Sybases use of raw partitions for
> storing it's databases.
> Anyone care to comment on that?
> I can think of hardware issues that might cause problems that this would
> catch.
> Any recommendations or whitepapers or links supporting use of DBCC's would
> be appreciated.
> Running sql 2000 Enterprise on Win Srvr 2003 Enterprise.
> thanks
Labels:
checkalloc,
checkdb,
database,
dbcc,
dbccs,
explanation,
ive,
microsoft,
mysql,
oracle,
organization,
practice,
provided,
regularlyrunning,
server,
sql
Subscribe to:
Posts (Atom)