Friday, March 30, 2012

Recovery phases

I have seen this message in Windows event log after restarting database.
3450:
Recovery of database 'IMAX_INV_Mgmt' (5) is 0% complete.
(approximately 2152 more seconds) (Phase 2 of 3)
Question is:
What are these three phases.
Thx,
MohThis is a multi-part message in MIME format.
--080209040300000504020608
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit
I'm not entirely certain about all 3 but there are at least 2 steps in a
recovery (whether a restore or a DB startup) and they are the
roll-forward and the roll-back. The roll-forward is "redoing" committed
transactions (they may have been written to the transaction log, as this
always happens first, but not yet written to the data file(s)). If the
server is shutdown properly, then this phase will should be very short,
if not non-existent. The roll-back phase is "undoing" transactions that
had not been committed at the recovery point (so at the point the server
was shut down there may have been some transactions in progress that
hadn't been committed yet). These 2 phases will put the data in a
consistent state as at the recovery point.
I'm guessing the 3rd stage in the startup recovery would be bringing the
database "online" so it will accept user connections (in a RESTORE
process the very 1st phase (before roll-forward and then roll-back) is
the data copy phase but this wouldn't be necessary for a startup
recovery because the data would already be in the data files). There's
a fairly good page about it in BOL: Understanding How Restore and
Recovery of Backups Work
<http://msdn2.microsoft.com/en-us/library/ms191455%28SQL.90%29.aspx>
With SQL 2000 the database is unusable until the end of the roll-back
phase. With SQL 2005 the database is now usable after the end of the
roll-forward phase. From memory they coined this "fast recovery" or
something like that (Database Engine Availability Enhancements
<http://msdn2.microsoft.com/en-us/library/ms171001%28SQL.90%29.aspx>).
Hope this helps.
--
*mike hodgson*
http://sqlnerd.blogspot.com
Moh wrote:
>I have seen this message in Windows event log after restarting database.
>3450:
>Recovery of database 'IMAX_INV_Mgmt' (5) is 0% complete.
>(approximately 2152 more seconds) (Phase 2 of 3)
>Question is:
>What are these three phases.
>Thx,
>Moh
>
--080209040300000504020608
Content-Type: text/html; charset=UTF-8
Content-Transfer-Encoding: 8bit
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta content="text/html;charset=UTF-8" http-equiv="Content-Type">
<title></title>
</head>
<body bgcolor="#ffffff" text="#000000">
<tt>I'm not entirely certain about all 3 but there are at least 2 steps
in a recovery (whether a restore or a DB startup) and they are the
roll-forward and the roll-back. The roll-forward is "redoing"
committed transactions (they may have been written to the transaction
log, as this always happens first, but not yet written to the data
file(s)). If the server is shutdown properly, then this phase will
should be very short, if not non-existent. The roll-back phase is
"undoing" transactions that had not been committed at the recovery
point (so at the point the server was shut down there may have been
some transactions in progress that hadn't been committed yet). These 2
phases will put the data in a consistent state as at the recovery point.<br>
<br>
I'm guessing the 3rd stage in the startup recovery would be bringing
the database "online" so it will accept user connections (in a RESTORE
process the very 1st phase (before roll-forward and then roll-back) is
the data copy phase but this wouldn't be necessary for a startup
recovery because the data would already be in the data files). There's
a fairly good page about it in BOL: <a
href="http://links.10026.com/?link=Understanding">http://msdn2.microsoft.com/en-us/library/ms191455%28SQL.90%29.aspx">Understanding
How Restore and Recovery of Backups Work</a><br>
<br>
With SQL 2000 the database is unusable until the end of the roll-back
phase. With SQL 2005 the database is now usable after the end of the
roll-forward phase. From memory they coined this "fast recovery" or
something like that (<a
href="http://links.10026.com/?link=Database">http://msdn2.microsoft.com/en-us/library/ms171001%28SQL.90%29.aspx">Database
Engine Availability Enhancements</a>).<br>
<br>
Hope this helps.<br>
</tt>
<div class="moz-signature">
<title></title>
<meta http-equiv="Content-Type" content="text/html; ">
<p><span lang="en-au"><font face="Tahoma" size="2">--<br>
</font></span> <b><span lang="en-au"><font face="Tahoma" size="2">mike
hodgson</font></span></b><span lang="en-au"><br>
<font face="Tahoma" size="2"><a href="http://links.10026.com/?link=http://sqlnerd.blogspot.com</a></font></span>">http://sqlnerd.blogspot.com">http://sqlnerd.blogspot.com</a></font></span>
</p>
</div>
<br>
<br>
Moh wrote:
<blockquote cite="mid8C953261-676E-41D5-80E7-4A2064EB9823@.microsoft.com"
type="cite">
<pre wrap="">I have seen this message in Windows event log after restarting database.
3450:
Recovery of database 'IMAX_INV_Mgmt' (5) is 0% complete.
(approximately 2152 more seconds) (Phase 2 of 3)
Question is:
What are these three phases.
Thx,
Moh
</pre>
</blockquote>
</body>
</html>
--080209040300000504020608--|||This is a multi-part message in MIME format.
--=_NextPart_000_00F1_01C662E8.12DAC620
Content-Type: text/plain;
charset="utf-8"
Content-Transfer-Encoding: quoted-printable
Just a note that in SQL 2005 its only Enterprise edition that allows the =database to be accessed before the rol back phase is complete.
-- Simon Sabin
SQL Server MVP
http://sqljunkies.com/weblog/simons
"Mike Hodgson" <e1minst3r@.gmail.com> wrote in message =news:OJ64mwqYGHA.1016@.TK2MSFTNGP03.phx.gbl...
I'm not entirely certain about all 3 but there are at least 2 steps in =a recovery (whether a restore or a DB startup) and they are the =roll-forward and the roll-back. The roll-forward is "redoing" committed =transactions (they may have been written to the transaction log, as this =always happens first, but not yet written to the data file(s)). If the =server is shutdown properly, then this phase will should be very short, =if not non-existent. The roll-back phase is "undoing" transactions that =had not been committed at the recovery point (so at the point the server =was shut down there may have been some transactions in progress that =hadn't been committed yet). These 2 phases will put the data in a =consistent state as at the recovery point.
I'm guessing the 3rd stage in the startup recovery would be bringing =the database "online" so it will accept user connections (in a RESTORE =process the very 1st phase (before roll-forward and then roll-back) is =the data copy phase but this wouldn't be necessary for a startup =recovery because the data would already be in the data files). There's =a fairly good page about it in BOL: Understanding How Restore and =Recovery of Backups Work
With SQL 2000 the database is unusable until the end of the roll-back =phase. With SQL 2005 the database is now usable after the end of the =roll-forward phase. From memory they coined this "fast recovery" or =something like that (Database Engine Availability Enhancements).
Hope this helps.
--
mike hodgson
http://sqlnerd.blogspot.com=20
Moh wrote: I have seen this message in Windows event log after restarting database.
3450:
Recovery of database 'IMAX_INV_Mgmt' (5) is 0% complete.
(approximately 2152 more seconds) (Phase 2 of 3)
Question is:
What are these three phases.
Thx,
Moh
--=_NextPart_000_00F1_01C662E8.12DAC620
Content-Type: text/html;
charset="utf-8"
Content-Transfer-Encoding: quoted-printable
=EF=BB=BF<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
&

Just a note that in SQL 2005 its only =Enterprise edition that allows the database to be accessed before the rol back =phase is complete.
-- Simon SabinSQL Server MVPhttp://sqljunkies.com/weblog/simons">http://sqljunkies.com/weblog=/simons
"Mike Hodgson" wrote =in message news:OJ64mwqYGHA.1016=@.TK2MSFTNGP03.phx.gbl...I'm not entirely certain about all 3 but there are at least 2 steps in a =recovery (whether a restore or a DB startup) and they are the roll-forward and =the roll-back. The roll-forward is "redoing" committed transactions =(they may have been written to the transaction log, as this always happens =first, but not yet written to the data file(s)). If the server is =shutdown properly, then this phase will should be very short, if not non-existent. The roll-back phase is "undoing" transactions that =had not been committed at the recovery point (so at the point the server was =shut down there may have been some transactions in progress that hadn't been =committed yet). These 2 phases will put the data in a consistent state as =at the recovery point.I'm guessing the 3rd stage in the startup =recovery would be bringing the database "online" so it will accept user =connections (in a RESTORE process the very 1st phase (before roll-forward and then =roll-back) is the data copy phase but this wouldn't be necessary for a startup =recovery because the data would already be in the data files). There's a =fairly good page about it in BOL: Understanding How Restore and Recovery of Backups WorkWith SQL 2000 the =database is unusable until the end of the roll-back phase. With SQL 2005 =the database is now usable after the end of the roll-forward phase. =From memory they coined this "fast recovery" or something like that (Database Engine Availability Enhancements).Hope this =helps.
--mike =hodgsonhttp://sqlnerd.blogspot.com Moh wrote: I have seen this message in Windows event =log after restarting database.
3450:
Recovery of database 'IMAX_INV_Mgmt' (5) is 0% complete.
(approximately 2152 more seconds) (Phase 2 of 3)
Question is:
What are these three phases.
Thx,
Moh


--=_NextPart_000_00F1_01C662E8.12DAC620--sql

No comments:

Post a Comment