Saturday, February 25, 2012

Checkpoint and performance

While profiling our stored procs that write data to the database, we notice
that while the database is checkpointing, the performance of these stored
procs gets worse. What usually will takes 100 ms takes 400 to 700 ms. Once
the checkpoint is done, they are back to their normal runtime
Is this expected behavior?
BTW this is a quad P4 xeon 2.8ghz box with 12 gig of ram running Windows
Server 2003/SQL Server 2000 Enterprise SP3a.With direct attached SCSI I saw the same behavior. Basically, your
checkpoint is saturating the IO bandwidth of your controller card. I saw
this with high-end RAID controllers with 128MB RAM when the checkpoint was
large enough to flood the on-board cache. This went away with a SAN since
FC is full duplex and the SAN has 3GB of write cache, easily enough to hold
a checkpoint.
--
Geoff N. Hiten
Microsoft SQL Server MVP
Senior Database Administrator
Careerbuilder.com
"Kevin Jackson" <kjackson@.powerwayinc.com> wrote in message
news:ONLYmSpuDHA.2304@.TK2MSFTNGP12.phx.gbl...
> While profiling our stored procs that write data to the database, we
notice
> that while the database is checkpointing, the performance of these stored
> procs gets worse. What usually will takes 100 ms takes 400 to 700 ms.
Once
> the checkpoint is done, they are back to their normal runtime
> Is this expected behavior?
> BTW this is a quad P4 xeon 2.8ghz box with 12 gig of ram running Windows
> Server 2003/SQL Server 2000 Enterprise SP3a.
>|||I forgot to add we are using attached to an EMC storage system with 1
terabyte of storage... The controller card is fiber to the EMC system and
the sustained throughput during a checkpoint is 8 MBps and the that is
nothing compared to what we can actually push to that system. During
database restores we can get over 50 MBps!!! So while it may be an I/O
issue, we are not even reaching the saturation point of our attached I/O
system.
"Geoff N. Hiten" <SRDBA@.Careerbuilder.com> wrote in message
news:OCuhqipuDHA.3220@.tk2msftngp13.phx.gbl...
> With direct attached SCSI I saw the same behavior. Basically, your
> checkpoint is saturating the IO bandwidth of your controller card. I saw
> this with high-end RAID controllers with 128MB RAM when the checkpoint was
> large enough to flood the on-board cache. This went away with a SAN since
> FC is full duplex and the SAN has 3GB of write cache, easily enough to
hold
> a checkpoint.
> --
> Geoff N. Hiten
> Microsoft SQL Server MVP
> Senior Database Administrator
> Careerbuilder.com
>
>
> "Kevin Jackson" <kjackson@.powerwayinc.com> wrote in message
> news:ONLYmSpuDHA.2304@.TK2MSFTNGP12.phx.gbl...
> > While profiling our stored procs that write data to the database, we
> notice
> > that while the database is checkpointing, the performance of these
stored
> > procs gets worse. What usually will takes 100 ms takes 400 to 700 ms.
> Once
> > the checkpoint is done, they are back to their normal runtime
> >
> > Is this expected behavior?
> >
> > BTW this is a quad P4 xeon 2.8ghz box with 12 gig of ram running Windows
> > Server 2003/SQL Server 2000 Enterprise SP3a.
> >
> >
>|||I am also using an EMC SAN (CX-600) with 4 fiber cards from each cluster
host to the SAN. The real key is write cache. Mine is set to max at 3GB.
If you overfill your write cache, you go to direct write mode and lose a lot
of the benefits of your high-end IO system.
There may be CPU issues as well. Have you monitored processor time on a
per-CPU basis? Also, do you have Hyperthreading on or off?
Geoff N. Hiten
Microsoft SQL Server MVP
Senior Database Administrator
Careerbuilder.com
"Kevin Jackson" <softwiz@.covad.net> wrote in message
news:u6qIPUquDHA.2308@.TK2MSFTNGP11.phx.gbl...
> I forgot to add we are using attached to an EMC storage system with 1
> terabyte of storage... The controller card is fiber to the EMC system and
> the sustained throughput during a checkpoint is 8 MBps and the that is
> nothing compared to what we can actually push to that system. During
> database restores we can get over 50 MBps!!! So while it may be an I/O
> issue, we are not even reaching the saturation point of our attached I/O
> system.
> "Geoff N. Hiten" <SRDBA@.Careerbuilder.com> wrote in message
> news:OCuhqipuDHA.3220@.tk2msftngp13.phx.gbl...
> > With direct attached SCSI I saw the same behavior. Basically, your
> > checkpoint is saturating the IO bandwidth of your controller card. I
saw
> > this with high-end RAID controllers with 128MB RAM when the checkpoint
was
> > large enough to flood the on-board cache. This went away with a SAN
since
> > FC is full duplex and the SAN has 3GB of write cache, easily enough to
> hold
> > a checkpoint.
> >
> > --
> > Geoff N. Hiten
> > Microsoft SQL Server MVP
> > Senior Database Administrator
> > Careerbuilder.com
> >
> >
> >
> >
> > "Kevin Jackson" <kjackson@.powerwayinc.com> wrote in message
> > news:ONLYmSpuDHA.2304@.TK2MSFTNGP12.phx.gbl...
> > > While profiling our stored procs that write data to the database, we
> > notice
> > > that while the database is checkpointing, the performance of these
> stored
> > > procs gets worse. What usually will takes 100 ms takes 400 to 700 ms.
> > Once
> > > the checkpoint is done, they are back to their normal runtime
> > >
> > > Is this expected behavior?
> > >
> > > BTW this is a quad P4 xeon 2.8ghz box with 12 gig of ram running
Windows
> > > Server 2003/SQL Server 2000 Enterprise SP3a.
> > >
> > >
> >
> >
>|||I have seen minimally configured SAN systems saturate at around 50MB/sec.
are you seeing high disk queue lengths? if so, then how much bandwidth do
you have to the storage subsystem? How many spindles, what raid level, how
much write cache?
--
Kevin Connell, MCDBA
----
The views expressed here are my own
and not of my employer.
----
"Kevin Jackson" <softwiz@.covad.net> wrote in message
news:u6qIPUquDHA.2308@.TK2MSFTNGP11.phx.gbl...
> I forgot to add we are using attached to an EMC storage system with 1
> terabyte of storage... The controller card is fiber to the EMC system and
> the sustained throughput during a checkpoint is 8 MBps and the that is
> nothing compared to what we can actually push to that system. During
> database restores we can get over 50 MBps!!! So while it may be an I/O
> issue, we are not even reaching the saturation point of our attached I/O
> system.
> "Geoff N. Hiten" <SRDBA@.Careerbuilder.com> wrote in message
> news:OCuhqipuDHA.3220@.tk2msftngp13.phx.gbl...
> > With direct attached SCSI I saw the same behavior. Basically, your
> > checkpoint is saturating the IO bandwidth of your controller card. I
saw
> > this with high-end RAID controllers with 128MB RAM when the checkpoint
was
> > large enough to flood the on-board cache. This went away with a SAN
since
> > FC is full duplex and the SAN has 3GB of write cache, easily enough to
> hold
> > a checkpoint.
> >
> > --
> > Geoff N. Hiten
> > Microsoft SQL Server MVP
> > Senior Database Administrator
> > Careerbuilder.com
> >
> >
> >
> >
> > "Kevin Jackson" <kjackson@.powerwayinc.com> wrote in message
> > news:ONLYmSpuDHA.2304@.TK2MSFTNGP12.phx.gbl...
> > > While profiling our stored procs that write data to the database, we
> > notice
> > > that while the database is checkpointing, the performance of these
> stored
> > > procs gets worse. What usually will takes 100 ms takes 400 to 700 ms.
> > Once
> > > the checkpoint is done, they are back to their normal runtime
> > >
> > > Is this expected behavior?
> > >
> > > BTW this is a quad P4 xeon 2.8ghz box with 12 gig of ram running
Windows
> > > Server 2003/SQL Server 2000 Enterprise SP3a.
> > >
> > >
> >
> >
>|||Very short disk queue lengths.
4 ea FC2 HBAs per host computer. Theoretical max 800MB/sec. Box maxes out
at 1100 MB/sec manufacturer's spec. Real limit seems to be aroudn
200MB/sec.
Most RAID sets are 16 spindles RAID 1+0 Some are fewer spindles but all are
1+0.
Total system has 3GB write cache.
Front end is 4-node 3 instance cluster (Windows Server 2003) 8x2.8GHz procs
and 32GB RAM /box. (Unisys ES-7000)
Obviously NOT a minimally configured system. I was able to get 50MB/sec
from direct attached SCSI. Again, the problem I ran into was cache
saturation and half-duplex data pathing.
Then again, there is the flip-side problem where the IO system can be too
fast.
FIX: The Checkpoint Process Can Delay SQL Server Database Activity and Does
Not Yield Scheduler Correctly Causing Error: 17883 to Occur
http://support.microsoft.com/default.aspx?scid=kb;en-us;815056&Product=sql2k
Geoff N. Hiten
Microsoft SQL Server MVP
Senior Database Administrator
Careerbuilder.com
"Kevin" <ReplyTo@.Newsgroups.only> wrote in message
news:u2X1wUsuDHA.1512@.TK2MSFTNGP10.phx.gbl...
> I have seen minimally configured SAN systems saturate at around 50MB/sec.
> are you seeing high disk queue lengths? if so, then how much bandwidth do
> you have to the storage subsystem? How many spindles, what raid level,
how
> much write cache?
> --
> Kevin Connell, MCDBA
> ----
> The views expressed here are my own
> and not of my employer.
> ----
> "Kevin Jackson" <softwiz@.covad.net> wrote in message
> news:u6qIPUquDHA.2308@.TK2MSFTNGP11.phx.gbl...
> > I forgot to add we are using attached to an EMC storage system with 1
> > terabyte of storage... The controller card is fiber to the EMC system
and
> > the sustained throughput during a checkpoint is 8 MBps and the that is
> > nothing compared to what we can actually push to that system. During
> > database restores we can get over 50 MBps!!! So while it may be an I/O
> > issue, we are not even reaching the saturation point of our attached I/O
> > system.
> >
> > "Geoff N. Hiten" <SRDBA@.Careerbuilder.com> wrote in message
> > news:OCuhqipuDHA.3220@.tk2msftngp13.phx.gbl...
> > > With direct attached SCSI I saw the same behavior. Basically, your
> > > checkpoint is saturating the IO bandwidth of your controller card. I
> saw
> > > this with high-end RAID controllers with 128MB RAM when the checkpoint
> was
> > > large enough to flood the on-board cache. This went away with a SAN
> since
> > > FC is full duplex and the SAN has 3GB of write cache, easily enough to
> > hold
> > > a checkpoint.
> > >
> > > --
> > > Geoff N. Hiten
> > > Microsoft SQL Server MVP
> > > Senior Database Administrator
> > > Careerbuilder.com
> > >
> > >
> > >
> > >
> > > "Kevin Jackson" <kjackson@.powerwayinc.com> wrote in message
> > > news:ONLYmSpuDHA.2304@.TK2MSFTNGP12.phx.gbl...
> > > > While profiling our stored procs that write data to the database, we
> > > notice
> > > > that while the database is checkpointing, the performance of these
> > stored
> > > > procs gets worse. What usually will takes 100 ms takes 400 to 700
ms.
> > > Once
> > > > the checkpoint is done, they are back to their normal runtime
> > > >
> > > > Is this expected behavior?
> > > >
> > > > BTW this is a quad P4 xeon 2.8ghz box with 12 gig of ram running
> Windows
> > > > Server 2003/SQL Server 2000 Enterprise SP3a.
> > > >
> > > >
> > >
> > >
> >
> >
>|||16 spindles is not very much - 200MB/sec is actually really quite good for
16 15KRPM spindles.
--
Kevin Connell, MCDBA
----
The views expressed here are my own
and not of my employer.
----
"Geoff N. Hiten" <SRDBA@.Careerbuilder.com> wrote in message
news:Os3suQ1uDHA.2340@.TK2MSFTNGP12.phx.gbl...
> Very short disk queue lengths.
> 4 ea FC2 HBAs per host computer. Theoretical max 800MB/sec. Box maxes
out
> at 1100 MB/sec manufacturer's spec. Real limit seems to be aroudn
> 200MB/sec.
> Most RAID sets are 16 spindles RAID 1+0 Some are fewer spindles but all
are
> 1+0.
> Total system has 3GB write cache.
> Front end is 4-node 3 instance cluster (Windows Server 2003) 8x2.8GHz
procs
> and 32GB RAM /box. (Unisys ES-7000)
> Obviously NOT a minimally configured system. I was able to get 50MB/sec
> from direct attached SCSI. Again, the problem I ran into was cache
> saturation and half-duplex data pathing.
> Then again, there is the flip-side problem where the IO system can be too
> fast.
> FIX: The Checkpoint Process Can Delay SQL Server Database Activity and
Does
> Not Yield Scheduler Correctly Causing Error: 17883 to Occur
>
http://support.microsoft.com/default.aspx?scid=kb;en-us;815056&Product=sql2k
>
> --
> Geoff N. Hiten
> Microsoft SQL Server MVP
> Senior Database Administrator
> Careerbuilder.com
>
>
> "Kevin" <ReplyTo@.Newsgroups.only> wrote in message
> news:u2X1wUsuDHA.1512@.TK2MSFTNGP10.phx.gbl...
> > I have seen minimally configured SAN systems saturate at around
50MB/sec.
> > are you seeing high disk queue lengths? if so, then how much bandwidth
do
> > you have to the storage subsystem? How many spindles, what raid level,
> how
> > much write cache?
> >
> > --
> > Kevin Connell, MCDBA
> > ----
> > The views expressed here are my own
> > and not of my employer.
> > ----
> > "Kevin Jackson" <softwiz@.covad.net> wrote in message
> > news:u6qIPUquDHA.2308@.TK2MSFTNGP11.phx.gbl...
> > > I forgot to add we are using attached to an EMC storage system with 1
> > > terabyte of storage... The controller card is fiber to the EMC system
> and
> > > the sustained throughput during a checkpoint is 8 MBps and the that is
> > > nothing compared to what we can actually push to that system. During
> > > database restores we can get over 50 MBps!!! So while it may be an
I/O
> > > issue, we are not even reaching the saturation point of our attached
I/O
> > > system.
> > >
> > > "Geoff N. Hiten" <SRDBA@.Careerbuilder.com> wrote in message
> > > news:OCuhqipuDHA.3220@.tk2msftngp13.phx.gbl...
> > > > With direct attached SCSI I saw the same behavior. Basically, your
> > > > checkpoint is saturating the IO bandwidth of your controller card.
I
> > saw
> > > > this with high-end RAID controllers with 128MB RAM when the
checkpoint
> > was
> > > > large enough to flood the on-board cache. This went away with a SAN
> > since
> > > > FC is full duplex and the SAN has 3GB of write cache, easily enough
to
> > > hold
> > > > a checkpoint.
> > > >
> > > > --
> > > > Geoff N. Hiten
> > > > Microsoft SQL Server MVP
> > > > Senior Database Administrator
> > > > Careerbuilder.com
> > > >
> > > >
> > > >
> > > >
> > > > "Kevin Jackson" <kjackson@.powerwayinc.com> wrote in message
> > > > news:ONLYmSpuDHA.2304@.TK2MSFTNGP12.phx.gbl...
> > > > > While profiling our stored procs that write data to the database,
we
> > > > notice
> > > > > that while the database is checkpointing, the performance of these
> > > stored
> > > > > procs gets worse. What usually will takes 100 ms takes 400 to 700
> ms.
> > > > Once
> > > > > the checkpoint is done, they are back to their normal runtime
> > > > >
> > > > > Is this expected behavior?
> > > > >
> > > > > BTW this is a quad P4 xeon 2.8ghz box with 12 gig of ram running
> > Windows
> > > > > Server 2003/SQL Server 2000 Enterprise SP3a.
> > > > >
> > > > >
> > > >
> > > >
> > >
> > >
> >
> >
>

Checkpoint Activities

Dear Support,
I am trying to find a way to monitor the checkpoint acitivites in our SQL Server 2000 with sp3. The error log file doesn't show. Am I missing something here?
Also, after I ran the a checkpoint statment on a database, I am expecting the database mdf file to be updated. So, I am expecting last modified date of the mdf file to be changed. But, unfortunately,mind is not. I am wondering if this is normal.
The way I run the checkpoint statment is by use of the Job scheduling. The history log shows successful on all checkpoint statments run.
Thank you!
MartinThe modified date on the file will only change if it changes size (or if
autoclose database option is on). SQL keeps the file open when its running
and pages being updated etc in the file will not change the modified date on
the file itself (again unless autoclose is on)
--
HTH
Jasper Smith (SQL Server MVP)
I support PASS - the definitive, global
community for SQL Server professionals -
http://www.sqlpass.org
"Martin" <anonymous@.discussions.microsoft.com> wrote in message
news:9A6D13D7-D9CF-47F5-A5E9-441F087190B9@.microsoft.com...
> Dear Support,
> I am trying to find a way to monitor the checkpoint acitivites in our SQL
Server 2000 with sp3. The error log file doesn't show. Am I missing
something here?
> Also, after I ran the a checkpoint statment on a database, I am expecting
the database mdf file to be updated. So, I am expecting last modified date
of the mdf file to be changed. But, unfortunately,mind is not. I am
wondering if this is normal.
> The way I run the checkpoint statment is by use of the Job scheduling. The
history log shows successful on all checkpoint statments run.
> Thank you!
> Martin|||I think trace flag 3502 still works with SQL2000. The
trace flag instructs SQL to record an entry in the
errorlog when a database is checkpointed. You can use this
trace flag and monitor your errorlog for the checkpoint
entries.
To enable the trace flag, you can run the following:
dbcc traceon(3605, 3502, -1)
If you are only interested in the execution of the
checkpoint statement executed from your job, you can run
the following in your job:
dbcc traceon(3605, 3502)
checkpoint
dbcc traceoff(3605, 3502)
Linchi
>--Original Message--
>Dear Support,
>I am trying to find a way to monitor the checkpoint
acitivites in our SQL Server 2000 with sp3. The error log
file doesn't show. Am I missing something here?
>Also, after I ran the a checkpoint statment on a
database, I am expecting the database mdf file to be
updated. So, I am expecting last modified date of the mdf
file to be changed. But, unfortunately,mind is not. I am
wondering if this is normal.
>The way I run the checkpoint statment is by use of the
Job scheduling. The history log shows successful on all
checkpoint statments run.
>Thank you!
>Martin
>.
>|||Thanks Linchi and Jaspi,
Your information is quite helpful.
Martin|||Martin,
Why do you feel a need to run checkpoint via a scheduled job?. SQL =server will be doing checkpoints at intervals anyway, and about the only =time I have needed a manual checkpoint is when performance testing to =force updates back to disc prior to forcing a cache flush. If you are in =a very strange position you *may* want to adjust the checkpoint =interval, but that is the exception as well.
Mike John
"Martin" <anonymous@.discussions.microsoft.com> wrote in message =news:9A6D13D7-D9CF-47F5-A5E9-441F087190B9@.microsoft.com...
> Dear Support,
> I am trying to find a way to monitor the checkpoint acitivites in our =SQL Server 2000 with sp3. The error log file doesn't show. Am I =missing something here?
> Also, after I ran the a checkpoint statment on a database, I am =expecting the database mdf file to be updated. So, I am expecting last =modified date of the mdf file to be changed. But, unfortunately,mind is =not. I am wondering if this is normal. > The way I run the checkpoint statment is by use of the Job scheduling. =The history log shows successful on all checkpoint statments run.
> Thank you!
> Martin

Checkpoint Activities

Dear Support,
I am trying to find a way to monitor the checkpoint acitivites in our SQL Se
rver 2000 with sp3. The error log file doesn't show. Am I missing somethin
g here?
Also, after I ran the a checkpoint statment on a database, I am expecting th
e database mdf file to be updated. So, I am expecting last modified date of
the mdf file to be changed. But, unfortunately,mind is not. I am wondering
if this is normal.
The way I run the checkpoint statment is by use of the Job scheduling. The h
istory log shows successful on all checkpoint statments run.
Thank you!
MartinThe modified date on the file will only change if it changes size (or if
autoclose database option is on). SQL keeps the file open when its running
and pages being updated etc in the file will not change the modified date on
the file itself (again unless autoclose is on)
HTH
Jasper Smith (SQL Server MVP)
I support PASS - the definitive, global
community for SQL Server professionals -
http://www.sqlpass.org
"Martin" <anonymous@.discussions.microsoft.com> wrote in message
news:9A6D13D7-D9CF-47F5-A5E9-441F087190B9@.microsoft.com...
quote:

> Dear Support,
> I am trying to find a way to monitor the checkpoint acitivites in our SQL

Server 2000 with sp3. The error log file doesn't show. Am I missing
something here?
quote:

> Also, after I ran the a checkpoint statment on a database, I am expecting

the database mdf file to be updated. So, I am expecting last modified date
of the mdf file to be changed. But, unfortunately,mind is not. I am
wondering if this is normal.
quote:

> The way I run the checkpoint statment is by use of the Job scheduling. The

history log shows successful on all checkpoint statments run.
quote:

> Thank you!
> Martin
|||I think trace flag 3502 still works with SQL2000. The
trace flag instructs SQL to record an entry in the
errorlog when a database is checkpointed. You can use this
trace flag and monitor your errorlog for the checkpoint
entries.
To enable the trace flag, you can run the following:
dbcc traceon(3605, 3502, -1)
If you are only interested in the execution of the
checkpoint statement executed from your job, you can run
the following in your job:
dbcc traceon(3605, 3502)
checkpoint
dbcc traceoff(3605, 3502)
Linchi
quote:

>--Original Message--
>Dear Support,
>I am trying to find a way to monitor the checkpoint

acitivites in our SQL Server 2000 with sp3. The error log
file doesn't show. Am I missing something here?
quote:

>Also, after I ran the a checkpoint statment on a

database, I am expecting the database mdf file to be
updated. So, I am expecting last modified date of the mdf
file to be changed. But, unfortunately,mind is not. I am
wondering if this is normal.
quote:

>The way I run the checkpoint statment is by use of the

Job scheduling. The history log shows successful on all
checkpoint statments run.
quote:

>Thank you!
>Martin
>.
>
|||Thanks Linchi and Jaspi,
Your information is quite helpful.
Martin|||Martin,
Why do you feel a need to run checkpoint via a scheduled job?. SQL =
server will be doing checkpoints at intervals anyway, and about the only =
time I have needed a manual checkpoint is when performance testing to =
force updates back to disc prior to forcing a cache flush. If you are in =
a very strange position you *may* want to adjust the checkpoint =
interval, but that is the exception as well.
Mike John
"Martin" <anonymous@.discussions.microsoft.com> wrote in message =
news:9A6D13D7-D9CF-47F5-A5E9-441F087190B9@.microsoft.com...
quote:

> Dear Support,
> I am trying to find a way to monitor the checkpoint acitivites in our =

SQL Server 2000 with sp3. The error log file doesn't show. Am I =
missing something here?
quote:

> Also, after I ran the a checkpoint statment on a database, I am =

expecting the database mdf file to be updated. So, I am expecting last =
modified date of the mdf file to be changed. But, unfortunately,mind is =
not. I am wondering if this is normal. =20
quote:

> The way I run the checkpoint statment is by use of the Job scheduling. =

The history log shows successful on all checkpoint statments run.
quote:

> Thank you!
> Martin

Checkpoint - Not running?

Hi folks.
I have a SQL cluster running 2000. My databases are set to simple
recovery. The recovery interval on the server is set to zero.
My logfiles are continually growing on the servers in the cluster -
including the one in tempdb. I do not have long-running transactions,
nor do I have large transactions occurring. The minute I manually do a
checkpoint, the logfiles drop to under 1MB in size. Note that the size
of the logfiles grow to over 70% of the total size allocated in the
file and do cause the logfiles to autogrow.
It was my understanding that a checkpoint will occur if the logfile
size is over 70% of the total allocated size of the file.
Checkpointing is definitely not occurring.
Can anyone offer some suggestions or insight as to why the checkpoint
process seems...Dead?
TIA,
Brian
SP4 Build 8.00.2171 has a fix to this. It sorted the problem for us.
Hot fix/build list
http://www.aspfaq.com/sql2000builds.asp
Paul
<lameduck1000@.hotmail.com> wrote in message
news:1159455084.684715.57620@.m73g2000cwd.googlegro ups.com...
> Hi folks.
> I have a SQL cluster running 2000. My databases are set to simple
> recovery. The recovery interval on the server is set to zero.
> My logfiles are continually growing on the servers in the cluster -
> including the one in tempdb. I do not have long-running transactions,
> nor do I have large transactions occurring. The minute I manually do a
> checkpoint, the logfiles drop to under 1MB in size. Note that the size
> of the logfiles grow to over 70% of the total size allocated in the
> file and do cause the logfiles to autogrow.
> It was my understanding that a checkpoint will occur if the logfile
> size is over 70% of the total allocated size of the file.
> Checkpointing is definitely not occurring.
> Can anyone offer some suggestions or insight as to why the checkpoint
> process seems...Dead?
> TIA,
> Brian
>
|||To verify whether or when a checkpoint is issued, you can turn on trace flag
3502 so that an entry is written to the errorlog when a checkpoint is issued.
Linchi
"lameduck1000@.hotmail.com" wrote:

> Hi folks.
> I have a SQL cluster running 2000. My databases are set to simple
> recovery. The recovery interval on the server is set to zero.
> My logfiles are continually growing on the servers in the cluster -
> including the one in tempdb. I do not have long-running transactions,
> nor do I have large transactions occurring. The minute I manually do a
> checkpoint, the logfiles drop to under 1MB in size. Note that the size
> of the logfiles grow to over 70% of the total size allocated in the
> file and do cause the logfiles to autogrow.
> It was my understanding that a checkpoint will occur if the logfile
> size is over 70% of the total allocated size of the file.
> Checkpointing is definitely not occurring.
> Can anyone offer some suggestions or insight as to why the checkpoint
> process seems...Dead?
> TIA,
> Brian
>

Checkpoint - Not running?

Hi folks.
I have a SQL cluster running 2000. My databases are set to simple
recovery. The recovery interval on the server is set to zero.
My logfiles are continually growing on the servers in the cluster -
including the one in tempdb. I do not have long-running transactions,
nor do I have large transactions occurring. The minute I manually do a
checkpoint, the logfiles drop to under 1MB in size. Note that the size
of the logfiles grow to over 70% of the total size allocated in the
file and do cause the logfiles to autogrow.
It was my understanding that a checkpoint will occur if the logfile
size is over 70% of the total allocated size of the file.
Checkpointing is definitely not occurring.
Can anyone offer some suggestions or insight as to why the checkpoint
process seems...Dead?
TIA,
BrianSP4 Build 8.00.2171 has a fix to this. It sorted the problem for us.
Hot fix/build list
http://www.aspfaq.com/sql2000builds.asp
Paul
<lameduck1000@.hotmail.com> wrote in message
news:1159455084.684715.57620@.m73g2000cwd.googlegroups.com...
> Hi folks.
> I have a SQL cluster running 2000. My databases are set to simple
> recovery. The recovery interval on the server is set to zero.
> My logfiles are continually growing on the servers in the cluster -
> including the one in tempdb. I do not have long-running transactions,
> nor do I have large transactions occurring. The minute I manually do a
> checkpoint, the logfiles drop to under 1MB in size. Note that the size
> of the logfiles grow to over 70% of the total size allocated in the
> file and do cause the logfiles to autogrow.
> It was my understanding that a checkpoint will occur if the logfile
> size is over 70% of the total allocated size of the file.
> Checkpointing is definitely not occurring.
> Can anyone offer some suggestions or insight as to why the checkpoint
> process seems...Dead?
> TIA,
> Brian
>|||To verify whether or when a checkpoint is issued, you can turn on trace flag
3502 so that an entry is written to the errorlog when a checkpoint is issued
.
Linchi
"lameduck1000@.hotmail.com" wrote:

> Hi folks.
> I have a SQL cluster running 2000. My databases are set to simple
> recovery. The recovery interval on the server is set to zero.
> My logfiles are continually growing on the servers in the cluster -
> including the one in tempdb. I do not have long-running transactions,
> nor do I have large transactions occurring. The minute I manually do a
> checkpoint, the logfiles drop to under 1MB in size. Note that the size
> of the logfiles grow to over 70% of the total size allocated in the
> file and do cause the logfiles to autogrow.
> It was my understanding that a checkpoint will occur if the logfile
> size is over 70% of the total allocated size of the file.
> Checkpointing is definitely not occurring.
> Can anyone offer some suggestions or insight as to why the checkpoint
> process seems...Dead?
> TIA,
> Brian
>

Checkpoint - Not running?

Hi folks.
I have a SQL cluster running 2000. My databases are set to simple
recovery. The recovery interval on the server is set to zero.
My logfiles are continually growing on the servers in the cluster -
including the one in tempdb. I do not have long-running transactions,
nor do I have large transactions occurring. The minute I manually do a
checkpoint, the logfiles drop to under 1MB in size. Note that the size
of the logfiles grow to over 70% of the total size allocated in the
file and do cause the logfiles to autogrow.
It was my understanding that a checkpoint will occur if the logfile
size is over 70% of the total allocated size of the file.
Checkpointing is definitely not occurring.
Can anyone offer some suggestions or insight as to why the checkpoint
process seems...Dead?
TIA,
BrianSP4 Build 8.00.2171 has a fix to this. It sorted the problem for us.
Hot fix/build list
http://www.aspfaq.com/sql2000builds.asp
Paul
<lameduck1000@.hotmail.com> wrote in message
news:1159455084.684715.57620@.m73g2000cwd.googlegroups.com...
> Hi folks.
> I have a SQL cluster running 2000. My databases are set to simple
> recovery. The recovery interval on the server is set to zero.
> My logfiles are continually growing on the servers in the cluster -
> including the one in tempdb. I do not have long-running transactions,
> nor do I have large transactions occurring. The minute I manually do a
> checkpoint, the logfiles drop to under 1MB in size. Note that the size
> of the logfiles grow to over 70% of the total size allocated in the
> file and do cause the logfiles to autogrow.
> It was my understanding that a checkpoint will occur if the logfile
> size is over 70% of the total allocated size of the file.
> Checkpointing is definitely not occurring.
> Can anyone offer some suggestions or insight as to why the checkpoint
> process seems...Dead?
> TIA,
> Brian
>|||To verify whether or when a checkpoint is issued, you can turn on trace flag
3502 so that an entry is written to the errorlog when a checkpoint is issued.
Linchi
"lameduck1000@.hotmail.com" wrote:
> Hi folks.
> I have a SQL cluster running 2000. My databases are set to simple
> recovery. The recovery interval on the server is set to zero.
> My logfiles are continually growing on the servers in the cluster -
> including the one in tempdb. I do not have long-running transactions,
> nor do I have large transactions occurring. The minute I manually do a
> checkpoint, the logfiles drop to under 1MB in size. Note that the size
> of the logfiles grow to over 70% of the total size allocated in the
> file and do cause the logfiles to autogrow.
> It was my understanding that a checkpoint will occur if the logfile
> size is over 70% of the total allocated size of the file.
> Checkpointing is definitely not occurring.
> Can anyone offer some suggestions or insight as to why the checkpoint
> process seems...Dead?
> TIA,
> Brian
>

checkpoint

Hi friends,
I came across the recommendation to do checkpoint to flush a buffer pool out
when doing massive modification in small chunks under simple recovery mode.
Can someone elaborate a bit more on it? Is it reasonable? And why?
Thanks a lot in advance.
AlexAlex,
This is my understanding...
When you execute a CHECKPOINT Statement it forces SQL Server to write
all dirty pages to Disk. (Dirty pages being Data/Log Pages that have
been modified but not written to Disk). Once the Checkpoint is issued
the Transaction Log is Truncated. SQL Server marks the transaction log
at the start of the active portion i.e Where there are still active
transactions. The rest of log is discarded as all transactions have
either had commit or rollback statement issued.
To be honest I can't really see the need to do this when you are using
Simple Recovery anyway - unless space is an issue. SQL Server issues
Checkpoint commands automatically, so the Log would return to the
minimum size anyway. I think SQL Server issues Checkpoint commands
every 10 mins - I think!
Hope this helps
Barry|||thanks Barry,
That was my understanding too, I just thought maybe I was missing
something,- such recommendation couldn't emerge out of nowhere, right?
Alex
"Barry" <barry.oconnor@.singers.co.im> wrote in message
news:1138908677.612627.55190@.g43g2000cwa.googlegroups.com...
> Alex,
> This is my understanding...
> When you execute a CHECKPOINT Statement it forces SQL Server to write
> all dirty pages to Disk. (Dirty pages being Data/Log Pages that have
> been modified but not written to Disk). Once the Checkpoint is issued
> the Transaction Log is Truncated. SQL Server marks the transaction log
> at the start of the active portion i.e Where there are still active
> transactions. The rest of log is discarded as all transactions have
> either had commit or rollback statement issued.
> To be honest I can't really see the need to do this when you are using
> Simple Recovery anyway - unless space is an issue. SQL Server issues
> Checkpoint commands automatically, so the Log would return to the
> minimum size anyway. I think SQL Server issues Checkpoint commands
> every 10 mins - I think!
> Hope this helps
> Barry
>|||Well, there's no harm in forcing checkpoints in between batches. I
think the recommendation comes from the problems around long running
transactions and large data modifications.
Even in SIMPLE recovery mode the transaction log can grow very large
when there is some long running transaction (thereby preventing the
checkpoint from occurring, because the server can't flush an open
transaction) and it's making lots of changes (thereby producing many log
records). By breaking up the single big transaction into many smaller
batches, that gives the server a chance to checkpoint in between batches
thereby keeping the transaction log under control (and not locking out
other users for long periods of time).
The server will do automatic checkpoints based on a formula (it's not
just every x seconds). It's different depending on the recovery mode.
In simple recovery mode the server will do an automatic checkpoint when
the log becomes 70% full or the number of log records is more than what
SQL Server estimates it can get through in the recovery interval period
(which ever comes sooner). So it's possible that the log is not quite
full enough to do an auto checkpoint at the time you start the next
batch. In which case the log will then continue to be filled and quite
possibly have to do an autogrow operation (at which time the 70% full
mark is even bigger). So there's no harm in doing a manual checkpoint
in between batches and possible benefit.
Personally, when I have to do this kind of stuff I always do manual
checkpoints between batches (although I do it mostly on DBs in full
recovery mode that have their logs backed up pretty regularly - like
every 15 minutes for example - so it's slightly different, but the same
concept).
*mike hodgson*
http://sqlnerd.blogspot.com
AlexM wrote:

>thanks Barry,
>That was my understanding too, I just thought maybe I was missing
>something,- such recommendation couldn't emerge out of nowhere, right?
>Alex
>
>"Barry" <barry.oconnor@.singers.co.im> wrote in message
>news:1138908677.612627.55190@.g43g2000cwa.googlegroups.com...
>
>
>|||I've had some discussions with Storage engine people at MS about this. I've
had cases where forcing
a checkpoint in simple recovery with *not* long running transaction seemed t
o increate re-use of the
log. But this shouldn't happen, and the person I spoke to would consider suc
h cases a bug. The way I
interpreted it: If we can provide a repro, and provide them with that, they
will have a look at it
and "fix" it.
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
Blog: http://solidqualitylearning.com/blogs/tibor/
"Mike Hodgson" <e1minst3r@.gmail.com> wrote in message news:%23NPOQWGKGHA.668@.TK2MSFTNGP11.p
hx.gbl...
> Well, there's no harm in forcing checkpoints in between batches. I
> think the recommendation comes from the problems around long running
> transactions and large data modifications.
> Even in SIMPLE recovery mode the transaction log can grow very large
> when there is some long running transaction (thereby preventing the
> checkpoint from occurring, because the server can't flush an open
> transaction) and it's making lots of changes (thereby producing many log
> records). By breaking up the single big transaction into many smaller
> batches, that gives the server a chance to checkpoint in between batches
> thereby keeping the transaction log under control (and not locking out
> other users for long periods of time).
> The server will do automatic checkpoints based on a formula (it's not
> just every x seconds). It's different depending on the recovery mode.
> In simple recovery mode the server will do an automatic checkpoint when
> the log becomes 70% full or the number of log records is more than what
> SQL Server estimates it can get through in the recovery interval period
> (which ever comes sooner). So it's possible that the log is not quite
> full enough to do an auto checkpoint at the time you start the next
> batch. In which case the log will then continue to be filled and quite
> possibly have to do an autogrow operation (at which time the 70% full
> mark is even bigger). So there's no harm in doing a manual checkpoint
> in between batches and possible benefit.
> Personally, when I have to do this kind of stuff I always do manual
> checkpoints between batches (although I do it mostly on DBs in full
> recovery mode that have their logs backed up pretty regularly - like
> every 15 minutes for example - so it's slightly different, but the same
> concept).
> --
> *mike hodgson*
> http://sqlnerd.blogspot.com
>
> AlexM wrote:
>
>|||TIbor, Mike - Thanks for additional comments - further info is always
helpful.
Barry|||>> Even in SIMPLE recovery mode the transaction log can grow very large when
there is some long running transaction (thereby preventing the checkpoint f
rom occurring, because the server can't flush an open transaction)<<
I'm not sure exactly what you mean saying SQL Server can't flush an open tra
nsaction. It's true that the log space can't be reused, but that has nothing
to do with checkpoint. Checkpoint happens at regular intervals, as you sugg
est, but it will write ALL dirty pages to disk, even those that are part of
an uncommitted transaction.
The log space can't be reused, so the log can grow quite large, but the chec
kpoints DO occur.
--
HTH
Kalen Delaney, SQL Server MVP
www.solidqualitylearning.com
"Mike Hodgson" <e1minst3r@.gmail.com> wrote in message news:%23NPOQWGKGHA.668
@.TK2MSFTNGP11.phx.gbl...
Well, there's no harm in forcing checkpoints in between batches. I think th
e recommendation comes from the problems around long running transactions an
d large data modifications.
Even in SIMPLE recovery mode the transaction log can grow very large when th
ere is some long running transaction (thereby preventing the checkpoint from
occurring, because the server can't flush an open transaction) and it's mak
ing lots of changes (thereby producing many log records). By breaking up th
e single big transaction into many smaller batches, that gives the server a
chance to checkpoint in between batches thereby keeping the transaction log
under control (and not locking out other users for long periods of time).
The server will do automatic checkpoints based on a formula (it's not just e
very x seconds). It's different depending on the recovery mode. In simple
recovery mode the server will do an automatic checkpoint when the log become
s 70% full or the number of log records is more than what SQL Server estimat
es it can get through in the recovery interval period (which ever comes soon
er). So it's possible that the log is not quite full enough to do an auto c
heckpoint at the time you start the next batch. In which case the log will
then continue to be filled and quite possibly have to do an autogrow operati
on (at which time the 70% full mark is even bigger). So there's no harm in
doing a manual checkpoint in between batches and possible benefit.
Personally, when I have to do this kind of stuff I always do manual checkpoi
nts between batches (although I do it mostly on DBs in full recovery mode th
at have their logs backed up pretty regularly - like every 15 minutes for ex
ample - so it's slightly different, but the same concept).
mike hodgson
http://sqlnerd.blogspot.com
AlexM wrote:
thanks Barry,
That was my understanding too, I just thought maybe I was missing
something,- such recommendation couldn't emerge out of nowhere, right?
Alex
"Barry" <barry.oconnor@.singers.co.im> wrote in message
news:1138908677.612627.55190@.g43g2000cwa.googlegroups.com...
Alex,
This is my understanding...
When you execute a CHECKPOINT Statement it forces SQL Server to write
all dirty pages to Disk. (Dirty pages being Data/Log Pages that have
been modified but not written to Disk). Once the Checkpoint is issued
the Transaction Log is Truncated. SQL Server marks the transaction log
at the start of the active portion i.e Where there are still active
transactions. The rest of log is discarded as all transactions have
either had commit or rollback statement issued.
To be honest I can't really see the need to do this when you are using
Simple Recovery anyway - unless space is an issue. SQL Server issues
Checkpoint commands automatically, so the Log would return to the
minimum size anyway. I think SQL Server issues Checkpoint commands
every 10 mins - I think!
Hope this helps
Barry|||Sorry, I shouldn't have used the term "flush". My bad - mixing terminology.
I guess where I was coming from was, and it may since have changed so
I'm prepared to admit I'm wrong, in the old days (with SQL 6.5 and
earlier from memory) the simple recovery model was implemented with the
"trunc. log on checkpoint" dboption (and also depended on the value of
the "bcp/bulk insert" option too). So I was thinking that in simple
recovery mode with SQL 2000 the checkpoint truncates up to the minimum
recovery LSN, but in this case the earliest open transaction represents
the minimum recovery LSN and hence the log cannot be truncated past that
point until those open transactions are complete. (In fact, I just
found the BOL page
<http://msdn.microsoft.com/library/e...ar_da2_8y3y.asp>
that confirms the checkpoint process is responsible for truncating log
records before the MinLSN when the DB is in SIMPLE recovery mode and it
also confirms what I'm trying to say in the "Long-Running Transaction"
section.) And so, while the checkpoint still occurs and flushes all
dirty pages from memory to disk, as far as the size of the physical log
goes, the checkpoint effectively does nothing. I wasn't focused on
memory to disk operations but rather on log truncation operations.
I stand corrected in saying the checkpoint doesn't occur. My point was
that the open transaction would prevent the log from getting truncated
and therefore increased the likelihood of the log needing an autogrow
operation, but you're right (as always) - the checkpoint still occurs.
(I guess I really should have said "thereby preventing the checkpoint
from /truncating the physical log/, because the server can't /truncate
the log record associated with/ an open transaction".)
*mike hodgson*
http://sqlnerd.blogspot.com
Kalen Delaney wrote:
> large when there is some long running transaction (thereby preventing
> the checkpoint from occurring, because the server can't flush an open
> transaction)<<
> I'm not sure exactly what you mean saying SQL Server can't flush an
> open transaction. It's true that the log space can't be reused, but
> that has nothing to do with checkpoint. Checkpoint happens at regular
> intervals, as you suggest, but it will write ALL dirty pages to disk,
> even those that are part of an uncommitted transaction.
> The log space can't be reused, so the log can grow quite large, but
> the checkpoints DO occur.
> --
> HTH
> Kalen Delaney, SQL Server MVP
> www.solidqualitylearning.com <http://www.solidqualitylearning.com>
>
> "Mike Hodgson" <e1minst3r@.gmail.com <mailto:e1minst3r@.gmail.com>>
> wrote in message news:%23NPOQWGKGHA.668@.TK2MSFTNGP11.phx.gbl...
> Well, there's no harm in forcing checkpoints in between batches.
> I think the recommendation comes from the problems around long
> running transactions and large data modifications.
> Even in SIMPLE recovery mode the transaction log can grow very
> large when there is some long running transaction (thereby
> preventing the checkpoint from occurring, because the server can't
> flush an open transaction) and it's making lots of changes
> (thereby producing many log records). By breaking up the single
> big transaction into many smaller batches, that gives the server a
> chance to checkpoint in between batches thereby keeping the
> transaction log under control (and not locking out other users for
> long periods of time).
> The server will do automatic checkpoints based on a formula (it's
> not just every x seconds). It's different depending on the
> recovery mode. In simple recovery mode the server will do an
> automatic checkpoint when the log becomes 70% full or the number
> of log records is more than what SQL Server estimates it can get
> through in the recovery interval period (which ever comes
> sooner). So it's possible that the log is not quite full enough
> to do an auto checkpoint at the time you start the next batch. In
> which case the log will then continue to be filled and quite
> possibly have to do an autogrow operation (at which time the 70%
> full mark is even bigger). So there's no harm in doing a manual
> checkpoint in between batches and possible benefit.
> Personally, when I have to do this kind of stuff I always do
> manual checkpoints between batches (although I do it mostly on DBs
> in full recovery mode that have their logs backed up pretty
> regularly - like every 15 minutes for example - so it's slightly
> different, but the same concept).
> --
> *mike hodgson*
> http://sqlnerd.blogspot.com
>
> AlexM wrote:
>