<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:georss='http://www.georss.org/georss' xmlns:gd='http://schemas.google.com/g/2005' xmlns:thr='http://purl.org/syndication/thread/1.0'><id>tag:blogger.com,1999:blog-18271744</id><updated>2011-08-08T18:51:37.745-07:00</updated><title type='text'>Masood's Blog</title><subtitle type='html'>Oracle, Unix, Solaris -technical blog&lt;br /&gt;
Hey I never said that nothing non-technical</subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://masoodlankar.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/18271744/posts/default?max-results=100'/><link rel='alternate' type='text/html' href='http://masoodlankar.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><author><name>Masood</name><uri>http://www.blogger.com/profile/02247706296101848073</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>4</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>100</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-18271744.post-113267914259531167</id><published>2005-11-22T08:53:00.000-08:00</published><updated>2005-11-22T09:05:42.600-08:00</updated><title type='text'>it is me</title><content type='html'>&lt;a href="http://photos1.blogger.com/blogger/4350/1783/320/DSC00627.jpg"&gt;&lt;img style="CLEAR: all; FLOAT: right; MARGIN: 0px 10px 10px 0px; CURSOR: hand" alt="" src="http://photos1.blogger.com/blogger/4350/1783/160/DSC00627.jpg" border="0" /&gt;&lt;/a&gt;  it is me&amp;nbsp;&lt;a href='http://picasa.google.com/' target='ext'&gt;&lt;img src='http://photos1.blogger.com/pbp.gif' alt='Posted by Picasa' style='border: 0px none ; padding: 0px; background: transparent none repeat scroll 0% 50%; -moz-background-clip: initial; -moz-background-origin: initial; -moz-background-inline-policy: initial;' align='middle' border='0' /&gt;&lt;/a&gt; &lt;div class="blogger-post-footer"&gt;Oracle,Unix,Solaris,scripts,code,database&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/18271744-113267914259531167?l=masoodlankar.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://masoodlankar.blogspot.com/feeds/113267914259531167/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=18271744&amp;postID=113267914259531167' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/18271744/posts/default/113267914259531167'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/18271744/posts/default/113267914259531167'/><link rel='alternate' type='text/html' href='http://masoodlankar.blogspot.com/2005/11/it-is-me.html' title='it is me'/><author><name>Masood</name><uri>http://www.blogger.com/profile/02247706296101848073</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-18271744.post-113232694365613139</id><published>2005-11-18T21:47:00.000-08:00</published><updated>2005-11-19T07:07:40.196-08:00</updated><title type='text'>Redo logs for oracle8i versus checkpoint</title><content type='html'>&lt;p align="justify"&gt;&lt;a name="Redo logs and Checkpoint"&gt;&lt;strong&gt;&lt;span style="font-size:85%;"&gt;Redo logs and Checkpoint&lt;/span&gt;&lt;/strong&gt;&lt;/a&gt;&lt;span style="font-size:85%;"&gt;&lt;br /&gt;A checkpoint occurs at every log switch. If a previous checkpoint is already in progress, the checkpoint forced by the log switch will override the current checkpoint.&lt;br /&gt;This necessiates well-sized redo logs to avoid unnecessary checkpoints as a result of frequent log switches.&lt;/span&gt;&lt;/p&gt;&lt;ol&gt;&lt;li&gt;&lt;div align="justify"&gt;&lt;span style="font-size:85%;"&gt;Experts say u must change redologs every 20 minutes.&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li&gt;&lt;div align="justify"&gt;&lt;span style="font-size:85%;"&gt;We have a well tuned redolog if we change once per hour. &lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;/ol&gt;&lt;p align="justify"&gt;&lt;span style="font-size:85%;"&gt;If we increase the redo files then we can decrease performance by 2 ways: &lt;/span&gt;&lt;/p&gt;&lt;ul&gt;&lt;li&gt;&lt;div align="justify"&gt;&lt;span style="font-size:85%;"&gt;Bigger files are slower &lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li&gt;&lt;div align="justify"&gt;&lt;span style="font-size:85%;"&gt;Copying bigger files to archivelog take more time.&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;/ul&gt;&lt;div align="justify"&gt;&lt;span style="font-size:85%;"&gt;&lt;hr /&gt;&lt;/span&gt;&lt;/div&gt;&lt;p align="justify"&gt;&lt;span style="font-size:85%;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/p&gt;&lt;p align="justify"&gt;&lt;em&gt;&lt;span style="font-size:85%;"&gt;Checkpoint plays a very important role in database activity. So DBAs must have to monitor its efficiency during peak database activities. &lt;span style="color:#ff0000;"&gt;Log switches cause a checkpoint, but checkpoint does not cause a log switch.&lt;/span&gt;&lt;/span&gt;&lt;/em&gt;&lt;/p&gt;&lt;div align="justify"&gt;&lt;span style="font-size:85%;"&gt;&lt;hr /&gt;&lt;/span&gt;&lt;/div&gt;&lt;p align="justify"&gt;&lt;span style="font-size:85%;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/p&gt;&lt;p align="justify"&gt;&lt;span style="font-size:85%;"&gt;A &lt;strong&gt;checkpoint&lt;/strong&gt; is the act of flushing modified, cached database blocks to disk. Normally, when we make a change to a block -- the modifications of that block are made to a memory copy of the block. When we commit -- the block is not written (but the REDO LOG is -- that makes it so we can "replay" the transaction in the event of a failure). Eventually, the system will checkpoint the modified blocks to disk.&lt;/span&gt;&lt;/p&gt;&lt;p align="justify"&gt;&lt;span style="font-size:85%;"&gt;&lt;strong&gt;Checkpoint synchronizes the datablock in memory with the datafiles on disk&lt;/strong&gt;. When a checkpoint occurs:&lt;/span&gt;&lt;/p&gt;&lt;p align="justify"&gt;&lt;span style="font-size:85%;"&gt;&lt;strong&gt;DBWR&lt;/strong&gt; writes all modified database blocks from the buffer cache to datafiles.&lt;br /&gt;&lt;/span&gt;&lt;/p&gt;&lt;div align="justify"&gt;&lt;pre&gt;&lt;span style="font-size:85%;"&gt;                 (DBWR)&lt;/span&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p align="justify"&gt;&lt;span style="font-size:85%;"&gt;BUFFER CACHE-----------------------------&gt; DATAFILES&lt;br /&gt;&lt;br /&gt;&lt;strong&gt;LGWR&lt;/strong&gt; also updates both the controlfile and datafiles to indicate last SCN (checkpoint)&lt;br /&gt;&lt;/span&gt;&lt;/p&gt;&lt;div align="justify"&gt;&lt;pre&gt;&lt;span style="font-size:85%;"&gt;                 (LGWR)&lt;/span&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p align="justify"&gt;&lt;span style="font-size:85%;"&gt;Record SCN Number -------------------------&gt; CONTROLFILE &amp; DATAFILES&lt;br /&gt;&lt;br /&gt;&lt;strong&gt;CKPT&lt;/strong&gt; process performs the operation of LGWR if it is enabled. CKPT is enable as default in version 8.0 &lt;/span&gt;&lt;/p&gt;&lt;p align="justify"&gt;&lt;span style="font-size:85%;"&gt;&lt;/span&gt;&lt;/p&gt;&lt;div align="justify"&gt;&lt;span style="font-size:85%;"&gt;&lt;hr /&gt;&lt;/span&gt;&lt;/div&gt;&lt;p align="justify"&gt;&lt;span style="font-size:85%;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/p&gt;&lt;p align="justify"&gt;&lt;span style="font-size:85%;"&gt;Checkpoint occurs:&lt;/span&gt;&lt;/p&gt;&lt;ul&gt;&lt;li&gt;&lt;div align="justify"&gt;&lt;span style="font-size:85%;"&gt;At redo log switch.&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li&gt;&lt;div align="justify"&gt;&lt;span style="font-size:85%;"&gt;LOG_CHECKPOINT_TIMEOUT has expired.&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li&gt;&lt;div align="justify"&gt;&lt;span style="font-size:85%;"&gt;LOG_CHECKPOINT_INTERVAL has reached. &lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li&gt;&lt;div align="justify"&gt;&lt;span style="font-size:85%;"&gt;Forcefully by DBA.&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;/ul&gt;&lt;p align="justify"&gt;&lt;span style="font-size:85%;"&gt;&lt;/span&gt;&lt;p align="justify"&gt;&lt;span style="font-size:85%;"&gt;&lt;/span&gt;&lt;div align="justify"&gt;&lt;span style="font-size:85%;"&gt;&lt;hr /&gt;&lt;/span&gt;&lt;/div&gt;&lt;p align="justify"&gt;&lt;span style="font-size:85%;"&gt;&lt;strong&gt;Log_checkpoint_interval&lt;/strong&gt; is defined in terms of OS Block size.&lt;br /&gt;Suppose the following setting is defined in database environment :-&lt;br /&gt;&lt;br /&gt;LOG_CHECKPOINT_INTERVAL = 10000&lt;br /&gt;OS block size = 512 bytes&lt;br /&gt;Redo log file Size = 20M&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;strong&gt;Calculation of checkpoint&lt;/strong&gt; = (20 * 1024*1024)/(512*10000) = 4&lt;br /&gt;&lt;br /&gt;Four checkpoints will be raised per redo log file . One checkpoint will be raised when (10000*512) bytes are to be written by the LGWR from cache to redo log files.&lt;br /&gt;&lt;br /&gt;If we will define &lt;strong&gt;log_checkpoint_interval = 0&lt;/strong&gt; (zero), it means we are setting this value to infinity and causes the parameter to be ignored.&lt;br /&gt;If the value of the (log_checkpoint_interval * OS BLOCKSIZE) &gt; redolog file size , checkpoint will occur at the redolog switch.&lt;br /&gt;You can set this parameter dynamically by alter system as&lt;br /&gt;&lt;br /&gt;SQL&gt; ALTER SYSTEM SET LOG_CHECKPOINT_INTERVAL=100000; &lt;/span&gt;&lt;/p&gt;&lt;div align="justify"&gt;&lt;span style="font-size:85%;"&gt;&lt;hr /&gt;&lt;/span&gt;&lt;/div&gt;&lt;p align="justify"&gt;&lt;span style="font-size:85%;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/p&gt;&lt;p align="justify"&gt;&lt;span style="font-size:85%;"&gt;The error &lt;/span&gt;&lt;a name="log_checkpoint_not_vomplete_bk"&gt;&lt;span style="font-size:85%;"&gt;"&lt;strong&gt;&lt;span style="color:#ff0000;"&gt;checkpoint not complete&lt;/span&gt;&lt;/strong&gt; ".What does it indicate ?&lt;/span&gt;&lt;/a&gt;&lt;span style="font-size:85%;"&gt;&lt;br /&gt;&lt;br /&gt;It means Oracle is ready to recycle the redo logs but it can not because the checkpoint in the previous log is still in progress.&lt;br /&gt;We can also query the v$sysstat system view to determine the value of background_checkpoint_completed and background_checkpoint_started as&lt;br /&gt;&lt;br /&gt;SQL &gt; select name,value from sys.v$sysstate where name like 'background checkpoints%';&lt;br /&gt;&lt;br /&gt;If the difference of these two values are grater than 1 you must do :&lt;/span&gt;&lt;/p&gt;&lt;ul&gt;&lt;li&gt;&lt;div align="justify"&gt;&lt;span style="font-size:85%;"&gt;Add more redo log groups or increase the size of redo logs.&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li&gt;&lt;div align="justify"&gt;&lt;span style="font-size:85%;"&gt;Reduce the frequency of checkpoints by increasing LOG_CHECKPOINT_INTERVAL.&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;/ul&gt;&lt;div class="blogger-post-footer"&gt;Oracle,Unix,Solaris,scripts,code,database&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/18271744-113232694365613139?l=masoodlankar.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://masoodlankar.blogspot.com/feeds/113232694365613139/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=18271744&amp;postID=113232694365613139' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/18271744/posts/default/113232694365613139'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/18271744/posts/default/113232694365613139'/><link rel='alternate' type='text/html' href='http://masoodlankar.blogspot.com/2005/11/redo-logs-for-oracle8i-versus.html' title='Redo logs for oracle8i versus checkpoint'/><author><name>Masood</name><uri>http://www.blogger.com/profile/02247706296101848073</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-18271744.post-113232812691834290</id><published>2005-11-18T07:29:00.000-08:00</published><updated>2005-11-18T11:21:48.176-08:00</updated><title type='text'>Multiversion Concurrency Control</title><content type='html'>&lt;div align="justify"&gt;&lt;br /&gt;&lt;span style="font-size:85%;"&gt;Oracle automatically provides read consistency to a query so that all the data that the query sees comes from a single point in time (statement-level read consistency). Oracle can also provide read consistency to all of the queries in a transaction (transaction-level read consistency).&lt;br /&gt;Oracle uses the information maintained in its rollback segments to provide these consistent views. The rollback segments contain the old values of data that have been changed by uncommitted or recently committed transactions. Image below shows how Oracle provides statement-level read consistency using data in rollback segments.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;/div&gt;&lt;/span&gt;&lt;span style="font-size:85%;"&gt;&lt;img style="DISPLAY: block; MARGIN: 0px auto 10px; CURSOR: hand; TEXT-ALIGN: center" alt="" src="http://photos1.blogger.com/blogger/4350/1783/400/txnRdConsistency.0.jpg" border="0" /&gt;&lt;p align="justify"&gt;&lt;br /&gt;As a query enters the execution stage, the current system change number (SCN) is determined; in image, this system change number is &lt;strong&gt;10023&lt;/strong&gt;. As data blocks are read on behalf of the query, only blocks written with the observed SCN are used. Blocks with changed data (more recent SCNs) are reconstructed from data in the rollback segments, and the reconstructed data is returned for the query. Therefore, each query returns all committed data with respect to the SCN recorded at the time that query execution began. Changes of other transactions that occur during a query's execution are not observed, guaranteeing that consistent data is returned for each query.&lt;br /&gt;&lt;br /&gt;&lt;span style="color:#ff0000;"&gt;&lt;strong&gt;In rare situations, Oracle cannot return a consistent set of results&lt;/strong&gt;&lt;/span&gt; (often called a snapshot) for a long-running query. This occurs because not enough information remains in the rollback segments to reconstruct the older data. &lt;em&gt;&lt;strong&gt;Usually, this error is produced when a lot of update activity causes the rollback segment to wrap around and overwrite changes needed to reconstruct data that the long-running query requires&lt;/strong&gt;&lt;/em&gt;.&lt;br /&gt;&lt;/p&gt;&lt;/span&gt;&lt;div align="justify"&gt;&lt;span style="font-size:85%;"&gt;In this event, error 1555 will result: &lt;/span&gt;&lt;a name="2607"&gt;&lt;/a&gt;&lt;/div&gt;&lt;div align="justify"&gt;&lt;span style="font-size:85%;"&gt;&lt;strong&gt;ORA-1555&lt;/strong&gt;: &lt;span style="color:#ff0000;"&gt;&lt;strong&gt;snapshot too old&lt;/strong&gt;&lt;/span&gt; (rollback segment too small) .&lt;br /&gt;We can avoid this error by creating more or larger rollback segments. Alternatively, long-running queries can be issued when there are few concurrent transactions, or you can obtain a shared lock on the table you are querying, thus prohibiting any other exclusive locks during the transaction.&lt;/span&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;Oracle,Unix,Solaris,scripts,code,database&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/18271744-113232812691834290?l=masoodlankar.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://masoodlankar.blogspot.com/feeds/113232812691834290/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=18271744&amp;postID=113232812691834290' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/18271744/posts/default/113232812691834290'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/18271744/posts/default/113232812691834290'/><link rel='alternate' type='text/html' href='http://masoodlankar.blogspot.com/2005/11/multiversion-concurrency-control.html' title='Multiversion Concurrency Control'/><author><name>Masood</name><uri>http://www.blogger.com/profile/02247706296101848073</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-18271744.post-113024629082558770</id><published>2005-10-25T18:48:00.000-07:00</published><updated>2005-10-25T06:20:24.690-07:00</updated><title type='text'>Let's blog</title><content type='html'>Hey Guys.............. I would like it to be a technical blog...............&lt;br /&gt;&lt;strong&gt;I will be comming up with a lot more &lt;/strong&gt;&lt;div class="blogger-post-footer"&gt;Oracle,Unix,Solaris,scripts,code,database&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/18271744-113024629082558770?l=masoodlankar.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://masoodlankar.blogspot.com/feeds/113024629082558770/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=18271744&amp;postID=113024629082558770' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/18271744/posts/default/113024629082558770'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/18271744/posts/default/113024629082558770'/><link rel='alternate' type='text/html' href='http://masoodlankar.blogspot.com/2005/10/lets-blog.html' title='Let&apos;s blog'/><author><name>Masood</name><uri>http://www.blogger.com/profile/02247706296101848073</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry></feed>
