Showing posts with label explanation. Show all posts
Showing posts with label explanation. Show all posts

Friday, February 17, 2012

DBCC CHECKDB explanation

Hello All,
I ran DBCC CHECKDB('myDatabase'). After
scanning all the tables it finally gave this message:
CHECKDB found 0 allocation errors and 0 consistency errors
in database 'myDatabase'.
DBCC execution completed. If DBCC printed error messages,
contact your system administrator.
Can anyone tell me what does it mean by allocation errors
and consistency errors? Actually I am preparing for MCDBA
exams and I wanted to understand the concepts fully.
Thanks in advance
AnandExample of allocation error:
The allocation structure (IAM page) states that object X uses page Y. SQL Server goes to page Y and
the page header states that page Y is owned by object Z!
Example of consistency error:
SQL Server follows a linked list for an index and when coming to a page it sees that the previous
page in that page header is not the same as the page where it came from.
--
Tibor Karaszi, SQL Server MVP
Archive at: http://groups.google.com/groups?oi=djq&as ugroup=microsoft.public.sqlserver
"Anand" <anand_r@.linuxmail.org> wrote in message news:118201c39237$75ab6810$a101280a@.phx.gbl...
> Hello All,
> I ran DBCC CHECKDB('myDatabase'). After
> scanning all the tables it finally gave this message:
> CHECKDB found 0 allocation errors and 0 consistency errors
> in database 'myDatabase'.
> DBCC execution completed. If DBCC printed error messages,
> contact your system administrator.
>
> Can anyone tell me what does it mean by allocation errors
> and consistency errors? Actually I am preparing for MCDBA
> exams and I wanted to understand the concepts fully.
> Thanks in advance
> Anand
>|||Thanks Tibor,
By the way when does this happen?
Regards
Anand
>--Original Message--
>Example of allocation error:
>The allocation structure (IAM page) states that object X
uses page Y. SQL Server goes to page Y and
>the page header states that page Y is owned by object Z!
>
>Example of consistency error:
>SQL Server follows a linked list for an index and when
coming to a page it sees that the previous
>page in that page header is not the same as the page
where it came from.
>--
>Tibor Karaszi, SQL Server MVP
>Archive at: http://groups.google.com/groups?oi=djq&as
ugroup=microsoft.public.sqlserver
>
>"Anand" <anand_r@.linuxmail.org> wrote in message
news:118201c39237$75ab6810$a101280a@.phx.gbl...
>> Hello All,
>> I ran DBCC CHECKDB('myDatabase'). After
>> scanning all the tables it finally gave this message:
>> CHECKDB found 0 allocation errors and 0 consistency
errors
>> in database 'myDatabase'.
>> DBCC execution completed. If DBCC printed error
messages,
>> contact your system administrator.
>>
>> Can anyone tell me what does it mean by allocation
errors
>> and consistency errors? Actually I am preparing for
MCDBA
>> exams and I wanted to understand the concepts fully.
>> Thanks in advance
>> Anand
>>
>
>.
>|||Theoretically it can be bug in SQL Server, writing the incorrect bits to disk. I don't know if any
such problems has appeared since 6.5. So, in practice, we are talking about HW problems, HW write
caching without battery backup and such things.
--
Tibor Karaszi, SQL Server MVP
Archive at: http://groups.google.com/groups?oi=djq&as ugroup=microsoft.public.sqlserver
"Anand" <anand_r@.linuxmail.org> wrote in message news:2a51e01c3923c$54b99f50$a601280a@.phx.gbl...
> Thanks Tibor,
> By the way when does this happen?
> Regards
> Anand
>
> >--Original Message--
> >Example of allocation error:
> >
> >The allocation structure (IAM page) states that object X
> uses page Y. SQL Server goes to page Y and
> >the page header states that page Y is owned by object Z!
> >
> >
> >Example of consistency error:
> >SQL Server follows a linked list for an index and when
> coming to a page it sees that the previous
> >page in that page header is not the same as the page
> where it came from.
> >
> >--
> >Tibor Karaszi, SQL Server MVP
> >Archive at: http://groups.google.com/groups?oi=djq&as
> ugroup=microsoft.public.sqlserver
> >
> >
> >"Anand" <anand_r@.linuxmail.org> wrote in message
> news:118201c39237$75ab6810$a101280a@.phx.gbl...
> >> Hello All,
> >> I ran DBCC CHECKDB('myDatabase'). After
> >> scanning all the tables it finally gave this message:
> >>
> >> CHECKDB found 0 allocation errors and 0 consistency
> errors
> >> in database 'myDatabase'.
> >> DBCC execution completed. If DBCC printed error
> messages,
> >> contact your system administrator.
> >>
> >>
> >> Can anyone tell me what does it mean by allocation
> errors
> >> and consistency errors? Actually I am preparing for
> MCDBA
> >> exams and I wanted to understand the concepts fully.
> >>
> >> Thanks in advance
> >> Anand
> >>
> >>
> >
> >
> >.
> >|||Thanks Tibor,
Do you have any reference url which can throw more
light on such things.
Regards
Anand
>--Original Message--
>Theoretically it can be bug in SQL Server, writing the
incorrect bits to disk. I don't know if any
>such problems has appeared since 6.5. So, in practice, we
are talking about HW problems, HW write
>caching without battery backup and such things.
>--
>Tibor Karaszi, SQL Server MVP
>Archive at: http://groups.google.com/groups?oi=djq&as
ugroup=microsoft.public.sqlserver
>
>"Anand" <anand_r@.linuxmail.org> wrote in message
news:2a51e01c3923c$54b99f50$a601280a@.phx.gbl...
>> Thanks Tibor,
>> By the way when does this happen?
>> Regards
>> Anand
>>
>> >--Original Message--
>> >Example of allocation error:
>> >
>> >The allocation structure (IAM page) states that object
X
>> uses page Y. SQL Server goes to page Y and
>> >the page header states that page Y is owned by object
Z!
>> >
>> >
>> >Example of consistency error:
>> >SQL Server follows a linked list for an index and when
>> coming to a page it sees that the previous
>> >page in that page header is not the same as the page
>> where it came from.
>> >
>> >--
>> >Tibor Karaszi, SQL Server MVP
>> >Archive at: http://groups.google.com/groups?oi=djq&as
>> ugroup=microsoft.public.sqlserver
>> >
>> >
>> >"Anand" <anand_r@.linuxmail.org> wrote in message
>> news:118201c39237$75ab6810$a101280a@.phx.gbl...
>> >> Hello All,
>> >> I ran DBCC CHECKDB('myDatabase'). After
>> >> scanning all the tables it finally gave this message:
>> >>
>> >> CHECKDB found 0 allocation errors and 0 consistency
>> errors
>> >> in database 'myDatabase'.
>> >> DBCC execution completed. If DBCC printed error
>> messages,
>> >> contact your system administrator.
>> >>
>> >>
>> >> Can anyone tell me what does it mean by allocation
>> errors
>> >> and consistency errors? Actually I am preparing for
>> MCDBA
>> >> exams and I wanted to understand the concepts fully.
>> >>
>> >> Thanks in advance
>> >> Anand
>> >>
>> >>
>> >
>> >
>> >.
>> >
>
>.
>|||I'm sure that there exists web sites with such info, but I haven't searched for such myself. I'm
sure that you find such by doing a bit of web-searching.
--
Tibor Karaszi, SQL Server MVP
Archive at: http://groups.google.com/groups?oi=djq&as ugroup=microsoft.public.sqlserver
"Anand" <anand_r@.linuxmail.org> wrote in message news:0f6301c3923e$aeacbe50$a301280a@.phx.gbl...
> Thanks Tibor,
> Do you have any reference url which can throw more
> light on such things.
> Regards
> Anand
> >--Original Message--
> >Theoretically it can be bug in SQL Server, writing the
> incorrect bits to disk. I don't know if any
> >such problems has appeared since 6.5. So, in practice, we
> are talking about HW problems, HW write
> >caching without battery backup and such things.
> >
> >--
> >Tibor Karaszi, SQL Server MVP
> >Archive at: http://groups.google.com/groups?oi=djq&as
> ugroup=microsoft.public.sqlserver
> >
> >
> >"Anand" <anand_r@.linuxmail.org> wrote in message
> news:2a51e01c3923c$54b99f50$a601280a@.phx.gbl...
> >> Thanks Tibor,
> >> By the way when does this happen?
> >>
> >> Regards
> >> Anand
> >>
> >>
> >> >--Original Message--
> >> >Example of allocation error:
> >> >
> >> >The allocation structure (IAM page) states that object
> X
> >> uses page Y. SQL Server goes to page Y and
> >> >the page header states that page Y is owned by object
> Z!
> >> >
> >> >
> >> >Example of consistency error:
> >> >SQL Server follows a linked list for an index and when
> >> coming to a page it sees that the previous
> >> >page in that page header is not the same as the page
> >> where it came from.
> >> >
> >> >--
> >> >Tibor Karaszi, SQL Server MVP
> >> >Archive at: http://groups.google.com/groups?oi=djq&as
> >> ugroup=microsoft.public.sqlserver
> >> >
> >> >
> >> >"Anand" <anand_r@.linuxmail.org> wrote in message
> >> news:118201c39237$75ab6810$a101280a@.phx.gbl...
> >> >> Hello All,
> >> >> I ran DBCC CHECKDB('myDatabase'). After
> >> >> scanning all the tables it finally gave this message:
> >> >>
> >> >> CHECKDB found 0 allocation errors and 0 consistency
> >> errors
> >> >> in database 'myDatabase'.
> >> >> DBCC execution completed. If DBCC printed error
> >> messages,
> >> >> contact your system administrator.
> >> >>
> >> >>
> >> >> Can anyone tell me what does it mean by allocation
> >> errors
> >> >> and consistency errors? Actually I am preparing for
> >> MCDBA
> >> >> exams and I wanted to understand the concepts fully.
> >> >>
> >> >> Thanks in advance
> >> >> Anand
> >> >>
> >> >>
> >> >
> >> >
> >> >.
> >> >
> >
> >
> >.
> >

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

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

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