<?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-2493681572457119266</id><updated>2011-07-08T08:20:59.470+05:30</updated><title type='text'>DBA</title><subtitle type='html'>Database Administrator
"One machine can do the work of fifty ordinary men. No machine can do the work of one extraordinary man."</subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://azardba.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default?max-results=100'/><link rel='alternate' type='text/html' href='http://azardba.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><author><name>Azar Mohamed Shaj</name><uri>http://www.blogger.com/profile/04251444414118162294</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://4.bp.blogspot.com/_M42FHtL_R7c/Stmn7gOmPCI/AAAAAAAAAGs/ff_HAJp76GI/S220/untitled.bmp'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>38</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>100</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-2493681572457119266.post-1235345189312426345</id><published>2009-10-24T17:25:00.003+05:30</published><updated>2009-10-24T17:33:34.951+05:30</updated><title type='text'>Export and import user level data</title><content type='html'>Export :&lt;br /&gt;&lt;br /&gt;exp user/user@orcl file=d:\backup\test.dmp log=d:\backup\test.log direct=y consistent=y "statistics="none"&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Import :&lt;br /&gt;&lt;br /&gt;imp system/manager@test fromuser=user touser=user  file=d:\backup\test.dmp log=d:\backup\test_imp.log ignore=y&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2493681572457119266-1235345189312426345?l=azardba.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://azardba.blogspot.com/feeds/1235345189312426345/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2493681572457119266&amp;postID=1235345189312426345' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/1235345189312426345'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/1235345189312426345'/><link rel='alternate' type='text/html' href='http://azardba.blogspot.com/2009/10/export-and-import-user-level-data.html' title='&lt;marquee behavior=&quot;alternate&quot;&gt;&lt;h2 style=&apos;color:red&apos;&gt;Export and import user level data&lt;/h2&gt;&lt;/marquee&gt;'/><author><name>Azar Mohamed Shaj</name><uri>http://www.blogger.com/profile/04251444414118162294</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://4.bp.blogspot.com/_M42FHtL_R7c/Stmn7gOmPCI/AAAAAAAAAGs/ff_HAJp76GI/S220/untitled.bmp'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2493681572457119266.post-5711093665353718651</id><published>2009-08-16T14:21:00.002+05:30</published><updated>2009-10-24T17:34:10.109+05:30</updated><title type='text'>Disk Driver Full</title><content type='html'>Disk Driver Full&lt;br /&gt;&lt;br /&gt;My disk driver fulled so that i did follow steps..&lt;br /&gt;&lt;br /&gt;Connected to:&lt;br /&gt;Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Production&lt;br /&gt;With the Partitioning, OLAP and Data Mining options&lt;br /&gt; &lt;br /&gt;SQL&gt; create tablespace ts datafile 'c:\ts.dbf' size 1m;&lt;br /&gt; &lt;br /&gt;Tablespace created.&lt;br /&gt; &lt;br /&gt;SQL&gt; select * from v$tablespace;&lt;br /&gt; &lt;br /&gt;       TS# NAME                           INC BIG FLA ENC&lt;br /&gt;---------- ------------------------------ --- --- --- ---&lt;br /&gt;         0 SYSTEM                         YES NO  YES&lt;br /&gt;         1 UNDOTBS1                       YES NO  YES&lt;br /&gt;         2 SYSAUX                         YES NO  YES&lt;br /&gt;         4 USERS                          YES NO  YES&lt;br /&gt;         3 TEMP                           NO  NO  YES&lt;br /&gt;         6 TS                             YES NO  YES&lt;br /&gt; &lt;br /&gt;6 rows selected.&lt;br /&gt; &lt;br /&gt;SQL&gt; select name from v$datafile;&lt;br /&gt; &lt;br /&gt;NAME&lt;br /&gt;--------------------------------------------------------------------------------&lt;br /&gt; &lt;br /&gt;C:\ORACLE\PRODUCT\10.2.0\ORADATA\DADA\SYSTEM01.DBF&lt;br /&gt;C:\ORACLE\PRODUCT\10.2.0\ORADATA\DADA\UNDOTBS01.DBF&lt;br /&gt;C:\ORACLE\PRODUCT\10.2.0\ORADATA\DADA\SYSAUX01.DBF&lt;br /&gt;C:\ORACLE\PRODUCT\10.2.0\ORADATA\DADA\USERS01.DBF&lt;br /&gt;C:\TS.DBF&lt;br /&gt; &lt;br /&gt;SQL&gt; alter tablespace ts offline;&lt;br /&gt; &lt;br /&gt;Tablespace altered.&lt;br /&gt; &lt;br /&gt; &lt;br /&gt;SQL&gt; host&lt;br /&gt;Microsoft Windows XP [Version 5.1.2600]&lt;br /&gt;(C) Copyright 1985-2001 Microsoft Corp.&lt;br /&gt; &lt;br /&gt;C:\Documents and Settings\Administrator&gt;move c:\TS.DBF c:\TS1.dbf&lt;br /&gt; &lt;br /&gt;C:\Documents and Settings\Administrator&gt;exit&lt;br /&gt; &lt;br /&gt;SQL&gt; alter tablespace ts rename datafile 'c:\ts.dbf' to 'c:\ts1.dbf';&lt;br /&gt; &lt;br /&gt;Tablespace altered.&lt;br /&gt; &lt;br /&gt;SQL&gt; alter tablespace ts online;&lt;br /&gt; &lt;br /&gt;Tablespace altered.&lt;br /&gt; &lt;br /&gt;SQL&gt; select name from v$datafile;&lt;br /&gt; &lt;br /&gt;NAME&lt;br /&gt;--------------------------------------------------------------------------------&lt;br /&gt; &lt;br /&gt;C:\ORACLE\PRODUCT\10.2.0\ORADATA\DADA\SYSTEM01.DBF&lt;br /&gt;C:\ORACLE\PRODUCT\10.2.0\ORADATA\DADA\UNDOTBS01.DBF&lt;br /&gt;C:\ORACLE\PRODUCT\10.2.0\ORADATA\DADA\SYSAUX01.DBF&lt;br /&gt;C:\ORACLE\PRODUCT\10.2.0\ORADATA\DADA\USERS01.DBF&lt;br /&gt;C:\TS1.DBF&lt;br /&gt; &lt;br /&gt;SQL&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2493681572457119266-5711093665353718651?l=azardba.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://azardba.blogspot.com/feeds/5711093665353718651/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2493681572457119266&amp;postID=5711093665353718651' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/5711093665353718651'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/5711093665353718651'/><link rel='alternate' type='text/html' href='http://azardba.blogspot.com/2009/08/disk-driver-full.html' title='&lt;marquee behavior=&quot;alternate&quot;&gt;&lt;h2 style=&apos;color:red&apos;&gt;Disk Driver Full&lt;/h2&gt;&lt;/marquee&gt;'/><author><name>Azar Mohamed Shaj</name><uri>http://www.blogger.com/profile/04251444414118162294</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://4.bp.blogspot.com/_M42FHtL_R7c/Stmn7gOmPCI/AAAAAAAAAGs/ff_HAJp76GI/S220/untitled.bmp'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2493681572457119266.post-3939565194887154583</id><published>2009-08-16T13:40:00.003+05:30</published><updated>2009-10-24T17:34:40.759+05:30</updated><title type='text'>ORA-32004: obsolete and/or deprecated parameter(s) specified</title><content type='html'>ORA-32004: obsolete and/or deprecated parameter(s) specified &lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Whenever i change mode from noarchive to archive log mode, i got above error.i am looking why this errors occured finally i realized and resolved that problem&lt;br /&gt;&lt;br /&gt;The problem occur due to this below reason&lt;br /&gt;&lt;br /&gt;sql&gt; archive log start&lt;br /&gt;&lt;br /&gt;the above commands not need to run for oracle 10g version.bcz parameter LOG_ARCHIVE_START is obsolete in 10g.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2493681572457119266-3939565194887154583?l=azardba.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://azardba.blogspot.com/feeds/3939565194887154583/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2493681572457119266&amp;postID=3939565194887154583' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/3939565194887154583'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/3939565194887154583'/><link rel='alternate' type='text/html' href='http://azardba.blogspot.com/2009/08/ora-32004-obsolete-andor-deprecated.html' title='&lt;marquee behavior=&quot;alternate&quot;&gt;&lt;h2 style=&apos;color:red&apos;&gt;ORA-32004: obsolete and/or deprecated parameter(s) specified&lt;/h2&gt;&lt;/marquee&gt;'/><author><name>Azar Mohamed Shaj</name><uri>http://www.blogger.com/profile/04251444414118162294</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://4.bp.blogspot.com/_M42FHtL_R7c/Stmn7gOmPCI/AAAAAAAAAGs/ff_HAJp76GI/S220/untitled.bmp'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2493681572457119266.post-5302628336630102043</id><published>2009-07-05T13:06:00.000+05:30</published><updated>2009-07-05T13:07:07.896+05:30</updated><title type='text'>Tuning Oracle's Buffer Cache </title><content type='html'>Tuning Oracle's Buffer Cache&lt;br /&gt;Roger Schrag, Database Specialists, Inc.&lt;br /&gt;http://www.dbspecialists.com&lt;br /&gt;&lt;br /&gt;Introduction&lt;br /&gt;&lt;br /&gt;Oracle maintains its own buffer cache inside the system global area (SGA) for each instance. A properly sized buffer cache can usually yield a cache hit ratio over 90%, meaning that nine requests out of ten are satisfied without going to disk.&lt;br /&gt;&lt;br /&gt;If a buffer cache is too small, the cache hit ratio will be small and more physical disk I/O will result. If a buffer cache is too big, then parts of the buffer cache will be under-utilized and memory resources will be wasted.&lt;br /&gt;&lt;br /&gt;Checking The Cache Hit Ratio&lt;br /&gt;&lt;br /&gt;Oracle maintains statistics of buffer cache hits and misses. The following query will show you the overall buffer cache hit ratio for the entire instance since it was started:&lt;br /&gt;&lt;br /&gt;SELECT (P1.value + P2.value - P3.value) / (P1.value + P2.value)&lt;br /&gt;FROM v$sysstat P1, v$sysstat P2, v$sysstat P3&lt;br /&gt;WHERE P1.name = 'db block gets'&lt;br /&gt;AND P2.name = 'consistent gets'&lt;br /&gt;AND P3.name = 'physical reads'&lt;br /&gt;&lt;br /&gt;You can also see the buffer cache hit ratio for one specific session since that session started:&lt;br /&gt;&lt;br /&gt;SELECT (P1.value + P2.value - P3.value) / (P1.value + P2.value)&lt;br /&gt;FROM v$sesstat P1, v$statname N1, v$sesstat P2, v$statname N2,&lt;br /&gt;v$sesstat P3, v$statname N3&lt;br /&gt;WHERE N1.name = 'db block gets'&lt;br /&gt;AND P1.statistic# = N1.statistic#&lt;br /&gt;AND P1.sid = &lt;enter&gt;&lt;br /&gt;AND N2.name = 'consistent gets'&lt;br /&gt;AND P2.statistic# = N2.statistic#&lt;br /&gt;AND P2.sid = P1.sid&lt;br /&gt;AND N3.name = 'physical reads'&lt;br /&gt;AND P3.statistic# = N3.statistic#&lt;br /&gt;AND P3.sid = P1.sid&lt;br /&gt;&lt;br /&gt;You can also measure the buffer cache hit ratio between time X and time Y by collecting statistics at times X and Y and computing the deltas.&lt;br /&gt;&lt;br /&gt;Adjusting The Size Of The Buffer Cache&lt;br /&gt;&lt;br /&gt;The db_block_buffers parameter in the parameter file determines the size of the buffer cache for the instance. The size of the buffer cache (in bytes) is equal to the value of the db_block_buffers parameter multiplied by the data block size.&lt;br /&gt;&lt;br /&gt;You can change the size of the buffer cache by editing the db_block_buffers parameter in the parameter file and restarting the instance.&lt;br /&gt;&lt;br /&gt;Determining If The Buffer Cache Should Be Enlarged&lt;br /&gt;&lt;br /&gt;If you set the db_block_lru_extended_statistics parameter to a positive number in the parameter file for an instance and restart the instance, Oracle will populate a dynamic performance view called v$recent_bucket. This view will contain the same number of rows as the setting of the db_block_lru_extended_statistics parameter. Each row will indicate how many additional buffer cache hits there might have been if the buffer cache were that much bigger.&lt;br /&gt;&lt;br /&gt;For example, if you set db_block_lru_extended_statistics to 1000 and restart the instance, you can see how the buffer cache hit ratio would have improved if the buffer cache were one buffer bigger, two buffers bigger, and so on up to 1000 buffers bigger than its current size. Following is a query you can use, along with a sample result:&lt;br /&gt;&lt;br /&gt;SELECT 250 * TRUNC (rownum / 250) + 1  ' to ' &lt;br /&gt;250 * (TRUNC (rownum / 250) + 1) "Interval",&lt;br /&gt;SUM (count) "Buffer Cache Hits"&lt;br /&gt;FROM v$recent_bucket&lt;br /&gt;GROUP BY TRUNC (rownum / 250)&lt;br /&gt;&lt;br /&gt;Interval Buffer Cache Hits&lt;br /&gt;--------------- --------------------&lt;br /&gt;1 to 250 16083&lt;br /&gt;251 to 500 11422&lt;br /&gt;501 to 750 683&lt;br /&gt;751 to 1000 177&lt;br /&gt;&lt;br /&gt;This result set shows that enlarging the buffer cache by 250 buffers would have resulted in 16,083 more hits. If there were about 30,000 hits in the buffer cache at the time this query was performed, then it would appear that adding 500 buffers to the buffer cache might be worthwhile. Adding more than 500 buffers might lead to under-utilized buffers and therefore wasted memory.&lt;br /&gt;&lt;br /&gt;There is overhead involved in collecting extended LRU statistics. Therefore you should set the db_block_lru_extended_ statistics parameter back to zero as soon as your analysis is complete.&lt;br /&gt;&lt;br /&gt;In Oracle7, the v$recent_bucket view was named X$KCBRBH. Only the SYS user can query X$KCBRBH. Also note that in X$KCBRBH the columns are called indx and count, instead of rownum and count.&lt;br /&gt;&lt;br /&gt;Determining If The Buffer Cache Is Bigger Than Necessary&lt;br /&gt;&lt;br /&gt;If you set the db_block_lru_statistics parameter to true in the parameter file for an instance and restart the instance, Oracle will populate a dynamic performance view called v$current_bucket. This view will contain one row for each buffer in the buffer cache, and each row will indicate how many of the overall cache hits have been attributable to that particular buffer.&lt;br /&gt;&lt;br /&gt;By querying v$current_bucket with a GROUP BY clause, you can get an idea of how well the buffer cache would perform if it were smaller. Following is a query you can use, along with a sample result:&lt;br /&gt;&lt;br /&gt;SELECT 1000 * TRUNC (rownum / 1000) + 1  ' to ' &lt;br /&gt;1000 * (TRUNC (rownum / 1000) + 1) "Interval",&lt;br /&gt;SUM (count) "Buffer Cache Hits"&lt;br /&gt;FROM v$current_bucket&lt;br /&gt;WHERE rownum &gt; 0&lt;br /&gt;GROUP BY TRUNC (rownum / 1000)&lt;br /&gt;&lt;br /&gt;Interval Buffer Cache Hits&lt;br /&gt;------------ -----------------&lt;br /&gt;1 to 1000 668415&lt;br /&gt;1001 to 2000 281760&lt;br /&gt;2001 to 3000 166940&lt;br /&gt;3001 to 4000 14770&lt;br /&gt;4001 to 5000 7030&lt;br /&gt;5001 to 6000 959&lt;br /&gt;&lt;br /&gt;This result set shows that the first 3000 buffers are responsible for over 98% of the hits in the buffer cache. This suggests that the buffer cache would be almost as effective if it were half the size; memory is being wasted on an oversized buffer cache.&lt;br /&gt;&lt;br /&gt;There is overhead involved in collecting LRU statistics. Therefore you should set the db_block_lru_statistics parameter back to false as soon as your analysis is complete.&lt;br /&gt;&lt;br /&gt;In Oracle7, the v$current_bucket view was named X$KCBCBH. Only the SYS user can query X$KCBCBH. Also note that in X$KCBCBH the columns are called indx and count, instead of rownum and count.&lt;br /&gt;&lt;br /&gt;Full Table Scans&lt;br /&gt;&lt;br /&gt;When Oracle performs a full table scan of a large table, the blocks are read into the buffer cache but placed at the least recently used end of the LRU list. This causes the blocks to be aged out quickly, and prevents one large full table scan from wiping out the entire buffer cache.&lt;br /&gt;&lt;br /&gt;Full table scans of large tables usually result in physical disk reads and a lower buffer cache hit ratio. You can get an idea of full table scan activity at the data file level by querying v$filestat and joining to SYS.dba_data_files. Following is a query you can use and sample results:&lt;br /&gt;&lt;br /&gt;SELECT A.file_name, B.phyrds, B.phyblkrd&lt;br /&gt;FROM SYS.dba_data_files A, v$filestat B&lt;br /&gt;WHERE B.file# = A.file_id&lt;br /&gt;ORDER BY A.file_id&lt;br /&gt;&lt;br /&gt;FILE_NAME PHYRDS PHYBLKRD&lt;br /&gt;-------------------------------- ---------- ----------&lt;br /&gt;/u01/oradata/PROD/system01.dbf 92832 130721&lt;br /&gt;/u02/oradata/PROD/temp01.dbf 1136 7825&lt;br /&gt;/u01/oradata/PROD/tools01.dbf 7994 8002&lt;br /&gt;/u01/oradata/PROD/users01.dbf 214 214&lt;br /&gt;/u03/oradata/PROD/rbs01.dbf 20518 20518&lt;br /&gt;/u04/oradata/PROD/data01.dbf 593336 9441037&lt;br /&gt;/u05/oradata/PROD/data02.dbf 4638037 4703454&lt;br /&gt;/u06/oradata/PROD/index01.dbf 1007638 1007638&lt;br /&gt;/u07/oradata/PROD/index02.dbf 1408270 1408270&lt;br /&gt;&lt;br /&gt;PHYRDS shows the number of reads from the data file since the instance was started. PHYBLKRD shows the actual number of data blocks read. Usually blocks are requested one at a time. However, Oracle requests blocks in batches when performing full table scans. (The db_file_multiblock_read_count parameter controls this batch size.)&lt;br /&gt;&lt;br /&gt;In the sample result set above, there appears to be quite a bit of full table scan activity in the data01.dbf data file, since 593,336 read requests have resulted in 9,441,037 actual blocks read.&lt;br /&gt;&lt;br /&gt;Spotting I/O Intensive SQL Statements&lt;br /&gt;&lt;br /&gt;The v$sqlarea dynamic performance view contains one row for each SQL statement currently in the shared SQL area of the SGA for the instance. v$sqlarea shows the first 1000 bytes of each SQL statement, along with various statistics. Following is a query you can use:&lt;br /&gt;&lt;br /&gt;SELECT executions, buffer_gets, disk_reads,&lt;br /&gt;first_load_time, sql_text&lt;br /&gt;FROM v$sqlarea&lt;br /&gt;ORDER BY disk_reads&lt;br /&gt;&lt;br /&gt;EXECUTIONS indicates the number of times the SQL statement has been executed since it entered the shared SQL area. BUFFER_GETS indicates the collective number of logical reads issued by all executions of the statement. DISK_READS shows the collective number of physical reads issued by all executions of the statement. (A logical read is a read that resulted in a cache hit or a physical disk read. A physical read is a read that resulted in a physical disk read.)&lt;br /&gt;&lt;br /&gt;You can review the results of this query to find SQL statements that perform lots of reads, both logical and physical. Consider how many times a SQL statement has been executed when evaluating the number of reads.&lt;br /&gt;&lt;br /&gt;Conclusion&lt;br /&gt;&lt;br /&gt;This brief document gives you the basic information you need in order to optimize the buffer cache size for your Oracle database. Also, you can zero in on SQL statements that cause a lot of I/O, and data files that experience a lot of full table scans.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2493681572457119266-5302628336630102043?l=azardba.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://azardba.blogspot.com/feeds/5302628336630102043/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2493681572457119266&amp;postID=5302628336630102043' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/5302628336630102043'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/5302628336630102043'/><link rel='alternate' type='text/html' href='http://azardba.blogspot.com/2009/07/tuning-oracles-buffer-cache.html' title='&lt;marquee behavior=&quot;alternate&quot;&gt;&lt;h2 style=&apos;color:red&apos;&gt;Tuning Oracle&apos;s Buffer Cache &lt;/h2&gt;&lt;/marquee&gt;'/><author><name>Azar Mohamed Shaj</name><uri>http://www.blogger.com/profile/04251444414118162294</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://4.bp.blogspot.com/_M42FHtL_R7c/Stmn7gOmPCI/AAAAAAAAAGs/ff_HAJp76GI/S220/untitled.bmp'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2493681572457119266.post-8664745702676421087</id><published>2009-07-05T12:59:00.003+05:30</published><updated>2009-07-05T13:21:51.786+05:30</updated><title type='text'>Transaction Internals </title><content type='html'>Here i hope this ppt document useful for know about oracle transaction&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;marquee&gt;&lt;h2 style='color:blue'&gt; &lt;a href="http://www.juliandyke.com/Presentations/TransactionInternals.ppt"&gt; http://www.juliandyke.com/Presentations/TransactionInternals.ppt&lt;/a&gt;&lt;/h2&gt;&lt;/marquee&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2493681572457119266-8664745702676421087?l=azardba.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://azardba.blogspot.com/feeds/8664745702676421087/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2493681572457119266&amp;postID=8664745702676421087' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/8664745702676421087'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/8664745702676421087'/><link rel='alternate' type='text/html' href='http://azardba.blogspot.com/2009/07/transaction-internals.html' title='&lt;marquee behavior=&quot;alternate&quot;&gt;&lt;h2 style=&apos;color:red&apos;&gt;Transaction Internals &lt;/h2&gt;&lt;/marquee&gt;'/><author><name>Azar Mohamed Shaj</name><uri>http://www.blogger.com/profile/04251444414118162294</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://4.bp.blogspot.com/_M42FHtL_R7c/Stmn7gOmPCI/AAAAAAAAAGs/ff_HAJp76GI/S220/untitled.bmp'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2493681572457119266.post-1900482724218776730</id><published>2009-07-01T17:54:00.002+05:30</published><updated>2009-07-01T17:57:57.929+05:30</updated><title type='text'>Super fast Database Copying/Cloning </title><content type='html'>Super fast Database Copying/Cloning&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;A database cloning procedure is especially useful for the DBA who wants to give his developers a full-sized TEST and DEV instance by cloning the PROD instance into the development server areas.&lt;br /&gt;&lt;br /&gt;This Oracle clone procedure can be use to quickly migrate a system from one UNIX server to another. It clones the Oracle database and this Oracle cloning procedures is often the fastest way to copy a Oracle database.&lt;br /&gt;&lt;br /&gt;STEP 1: On the old system, go into SQL*Plus, sign on as SYSDBA and issue: “alter database backup controlfile to trace”. This will put the create database syntax in the trace file directory. The trace keyword tells oracle to generate a script containing a create controlfile command and store it in the trace directory identified in the user_dump_dest parameter of the init.ora file. It will look something like this:&lt;br /&gt;&lt;br /&gt;STARTUP NOMOUNT&lt;br /&gt;CREATE CONTROLFILE REUSE DATABASE "OLDLSQ" NORESETLOGS&lt;br /&gt;NOARCHIVELOG&lt;br /&gt;MAXLOGFILES 16&lt;br /&gt;MAXLOGMEMBERS 2&lt;br /&gt;MAXDATAFILES 240&lt;br /&gt;MAXINSTANCES 1&lt;br /&gt;MAXLOGHISTORY 113&lt;br /&gt;LOGFILE&lt;br /&gt;GROUP 1 ('/u03/oradata/oldlsq/log1a.dbf',&lt;br /&gt;'/u03/oradata/olslsq/log1b.dbf') SIZE 30M,&lt;br /&gt;GROUP 2 ('/u04/oradata/oldlsq/log2a.dbf',&lt;br /&gt;'/u04/oradata/oldlsq/log2b.dbf') SIZE 30M&lt;br /&gt;DATAFILE&lt;br /&gt;'/u01/oradata/oldlsq/system01.dbf',&lt;br /&gt;'/u01/oradata/oldlsq/mydatabase.dbf'&lt;br /&gt;;&lt;br /&gt;# Recovery is required if any of the datafiles are restored&lt;br /&gt;# backups, or if the last shutdown was not normal or immediate.&lt;br /&gt;RECOVER DATABASE&lt;br /&gt;# Database can now be opened normally.&lt;br /&gt;ALTER DATABASE OPEN;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;STEP 2: Shutdown the old database&lt;br /&gt;&lt;br /&gt;STEP 3: Copy all data files into the new directories on the new server. You may change the file names if you want, but you must edit the controlfile to reflect the new data files names on the new server.&lt;br /&gt;&lt;br /&gt;rcp /u01/oradata/oldlsq/* newhost:/u01/oradata/newlsq&lt;br /&gt;rcp /u01/oradata/oldlsq/* newhost:/u01/oradata/newlsq&lt;br /&gt;rcp /u03/oradata/oldlsq/* newhost:/u03/oradata/newlsq&lt;br /&gt;rcp /u04/oradata/oldlsq/* newhost:/u04/oradata/newlsq&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;STEP 4: Copy and Edit the Control file – Using the output syntax from STEP 1, modify the controlfile creation script by changing the following:&lt;br /&gt;&lt;br /&gt;Old:&lt;br /&gt;&lt;br /&gt;CREATE CONTROLFILE REUSE DATABASE "OLDLSQ" NORESETLOGS&lt;br /&gt;&lt;br /&gt;New:&lt;br /&gt;&lt;br /&gt;CREATE CONTROLFILE SET DATABASE "NEWLSQ" RESETLOGS&lt;br /&gt;&lt;br /&gt;STEP 5: Remove the “recover database” and “alter database open” syntax&lt;br /&gt;&lt;br /&gt;# Recovery is required if any of the datafiles are restored&lt;br /&gt;# backups, or if the last shutdown was not normal or immediate.&lt;br /&gt;RECOVER DATABASE&lt;br /&gt;# Database can now be opened normally.&lt;br /&gt;ALTER DATABASE OPEN;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;STEP 6: Re-names of the data files names that have changed.&lt;br /&gt;&lt;br /&gt;Save as db_create_controlfile.sql.&lt;br /&gt;&lt;br /&gt;Old:&lt;br /&gt;&lt;br /&gt;DATAFILE&lt;br /&gt;'/u01/oradata/oldlsq/system01.dbf',&lt;br /&gt;'/u01/oradata/oldlsq/mydatabase.dbf'&lt;br /&gt;&lt;br /&gt;New:&lt;br /&gt;&lt;br /&gt;DATAFILE&lt;br /&gt;'/u01/oradata/newlsq/system01.dbf',&lt;br /&gt;'/u01/oradata/newlsq/mydatabase.dbf'&lt;br /&gt;&lt;br /&gt;STEP 7: Create the bdump, udump and cdump directories&lt;br /&gt;&lt;br /&gt;cd $DBA/admin&lt;br /&gt;mkdir newlsq&lt;br /&gt;cd newlsq&lt;br /&gt;mkdir bdump&lt;br /&gt;mkdir udump&lt;br /&gt;mkdir cdump&lt;br /&gt;mkdir pfile&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;STEP 8: Copy-over the old init.ora file&lt;br /&gt;&lt;br /&gt;rcp $DBA/admin/olslsq/pfile/*.ora newhost:/u01/oracle/admin/newlsq/pfile&lt;br /&gt;&lt;br /&gt;STEP 9: Start the new database&lt;br /&gt;&lt;br /&gt;@db_create_controlfile.sql&lt;br /&gt;&lt;br /&gt;STEP 10: Place the new database in archivelog mode&lt;br /&gt;&lt;br /&gt;&lt;marquee&gt;&lt;h2 style="'color:red'"&gt; &lt;a href="http://www.dba-oracle.com/oracle_tips_db_copy.htm"&gt;Super fast Database Copying/Cloning tips by burleson consulting&lt;/a&gt;&lt;/h2&gt;&lt;/marquee&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2493681572457119266-1900482724218776730?l=azardba.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://azardba.blogspot.com/feeds/1900482724218776730/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2493681572457119266&amp;postID=1900482724218776730' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/1900482724218776730'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/1900482724218776730'/><link rel='alternate' type='text/html' href='http://azardba.blogspot.com/2009/07/super-fast-database-copyingcloning.html' title='&lt;marquee behavior=&quot;alternate&quot;&gt;&lt;h2 style=&apos;color:red&apos;&gt;Super fast Database Copying/Cloning &lt;/h2&gt;&lt;/marquee&gt;'/><author><name>Azar Mohamed Shaj</name><uri>http://www.blogger.com/profile/04251444414118162294</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://4.bp.blogspot.com/_M42FHtL_R7c/Stmn7gOmPCI/AAAAAAAAAGs/ff_HAJp76GI/S220/untitled.bmp'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2493681572457119266.post-7622132705134265976</id><published>2009-07-01T16:51:00.001+05:30</published><updated>2009-07-01T16:53:55.160+05:30</updated><title type='text'>Full Database Export</title><content type='html'>&lt;strong&gt;When and why to perform a full database export&lt;/strong&gt;.&lt;br /&gt;&lt;br /&gt;* Export/import is only the possible way to construct a similar database on remote servers regardless of Operating System compatibility i.e. cross platform (Export on Linux and Import on Windows Systems).&lt;br /&gt;&lt;br /&gt;* To migrate the database from one Operating System to another i.e. (Linux/Unix to Windows), and to upgrade the database from one version to another i.e. 8i-9i or 9i-10g, but not vice versa.&lt;br /&gt;&lt;br /&gt;* If you are on Oracle 10g, above two points can be possible, using RMAN Convert Commands i.e. to construct or move a database from one OS to another OS i.e. Cross platform.&lt;br /&gt;&lt;br /&gt;* When there is a requirement to clone a database on another test or development server, then take a full database mode export dump and create a database with the similar settings of target database, and import the dump in source database.&lt;br /&gt;&lt;br /&gt;Simple Steps: &lt;strong&gt;how to perform a full database export using export utility&lt;/strong&gt;.&lt;br /&gt;&lt;br /&gt;* Use either system user or any other database user who has the EXP_FULL_DATABASE privilege.&lt;br /&gt;* Set the NLS_LANG environment variable according the database character set and language details.&lt;br /&gt;&lt;strong&gt;SQL&gt; select * from nls_database_parameters&lt;br /&gt;2 where parameter in ('NLS_LANGUAGE','NLS_TERRITORY','NLS_CHARACTERSET');&lt;br /&gt;&lt;br /&gt;&lt;/strong&gt;PARAMETER VALUE&lt;br /&gt;------------------------------ ----------------------------&lt;br /&gt;NLS_LANGUAGE AMERICAN&lt;br /&gt;NLS_TERRITORY AMERICA&lt;br /&gt;NLS_CHARACTERSET WE8ISO8859P1&lt;br /&gt;&lt;br /&gt;Windows (Dos Prompt):&lt;br /&gt;&lt;strong&gt;C:\&gt; set NLS_LANG=AMERICAN_AMERICA.WE8ISO8859P1&lt;br /&gt;&lt;br /&gt;&lt;/strong&gt;Unix/Linux:&lt;br /&gt;$ export NLS_LANG=AMERICAN_AMERICA.WE8ISO8859P1&lt;br /&gt;&lt;br /&gt;* Start the export with following command and options.&lt;br /&gt;&lt;br /&gt;&lt;strong&gt;exp system/password@mydb file=c:\exportdmp\exp_fulldb_MYDB_27Aug08.dmp&lt;br /&gt;full=y log= c:\exportdmp\exp_fulldb_MYDB_27Aug08.log&lt;br /&gt;&lt;br /&gt;&lt;/strong&gt;Note: This is just a simple export command to perform the full database export. I would request and suggest you to refer Oracle Documentations on export/import and their options. Check the references.&lt;br /&gt;&lt;br /&gt;Help on Export and Import:&lt;br /&gt;&lt;br /&gt;Windows:&lt;br /&gt;&lt;strong&gt;C:\&gt; exp help=y&lt;br /&gt;C:\&gt; imp help=y &lt;/strong&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2493681572457119266-7622132705134265976?l=azardba.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://azardba.blogspot.com/feeds/7622132705134265976/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2493681572457119266&amp;postID=7622132705134265976' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/7622132705134265976'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/7622132705134265976'/><link rel='alternate' type='text/html' href='http://azardba.blogspot.com/2009/07/full-database-export.html' title='&lt;marquee behavior=&quot;alternate&quot;&gt;&lt;h2 style=&apos;color:red&apos;&gt;Full Database Export&lt;/h2&gt;&lt;/marquee&gt;'/><author><name>Azar Mohamed Shaj</name><uri>http://www.blogger.com/profile/04251444414118162294</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://4.bp.blogspot.com/_M42FHtL_R7c/Stmn7gOmPCI/AAAAAAAAAGs/ff_HAJp76GI/S220/untitled.bmp'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2493681572457119266.post-5429425395033366571</id><published>2009-06-30T13:49:00.008+05:30</published><updated>2009-06-30T19:58:40.592+05:30</updated><title type='text'>Change Oracle password</title><content type='html'>Location of Oracle Password hashes&lt;br /&gt;&lt;br /&gt;* Database -sys.user$ -password&lt;br /&gt;*Oracle Password File&lt;br /&gt;*Data File of the system Tablespace&lt;br /&gt;*(full) Export Files&lt;br /&gt;*archive logs&lt;br /&gt;&lt;br /&gt;Show oracle password hashkey&lt;br /&gt;&lt;br /&gt;&lt;strong&gt;sql&gt;select username,password from dba_users;&lt;br /&gt;&lt;br /&gt;sql&gt;select name,password from sys.user$ where password is notnull.&lt;br /&gt;&lt;/strong&gt;&lt;br /&gt;How to change an Oracle Password?&lt;br /&gt;&lt;br /&gt;You should always use the pasword because the password is sent unencrypted over the net If you use the alter user syntax.&lt;br /&gt;&lt;br /&gt;&lt;strong&gt;* alter user myuser identified bu my!supersecretpassword;&lt;br /&gt;&lt;br /&gt;*grant connect to myuser identified by my!supersecretpassword&lt;br /&gt;&lt;br /&gt;*update sys.user$ set password='F894844C34402B67' WHERE name='SCOTT';restart the database necessary&lt;br /&gt;&lt;br /&gt;&lt;/strong&gt;*sql*plus command:password or password username.&lt;br /&gt;&lt;br /&gt;How to change an Oracle password temporarily?&lt;br /&gt;&lt;br /&gt;In Oracle it is possible to change a password temporarily. This can be useful for DBA which act as a different user.&lt;br /&gt;&lt;br /&gt;&lt;strong&gt;SQL&gt; select username,password from dba_users where username='SCOTT';&lt;br /&gt;&lt;br /&gt;USERNAME PASSWORD-------- ----------------SCOTT F894844C34402B67&lt;br /&gt;&lt;br /&gt;SQL&gt; alter user scott identified by mypassword;&lt;br /&gt;&lt;/strong&gt;&lt;br /&gt;Now login with the following credentials: scott/tigerAfter doing your work you can change the password back by using an undocumented feature called "by values"&lt;br /&gt;&lt;br /&gt;&lt;strong&gt;SQL&gt; alter user scott identified by values 'F894844C34402B67';&lt;/strong&gt;&lt;br /&gt;&lt;strong&gt;&lt;/strong&gt;&lt;br /&gt;&lt;marquee&gt;&lt;a href="http://www.red-database-security.com/whitepaper/oracle_passwords.html"&gt;http://www.red-database-security.com/whitepaper/oracle_passwords.html&lt;/a&gt;&lt;/marquee&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2493681572457119266-5429425395033366571?l=azardba.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://azardba.blogspot.com/feeds/5429425395033366571/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2493681572457119266&amp;postID=5429425395033366571' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/5429425395033366571'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/5429425395033366571'/><link rel='alternate' type='text/html' href='http://azardba.blogspot.com/2009/06/change-oracle-password.html' title='&lt;marquee behavior=&quot;alternate&quot;&gt;&lt;h2 style=&quot;color:red&quot;&gt;Change Oracle password&lt;/h2&gt;&lt;/marquee&gt;'/><author><name>Azar Mohamed Shaj</name><uri>http://www.blogger.com/profile/04251444414118162294</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://4.bp.blogspot.com/_M42FHtL_R7c/Stmn7gOmPCI/AAAAAAAAAGs/ff_HAJp76GI/S220/untitled.bmp'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2493681572457119266.post-5590186449633294197</id><published>2009-06-29T19:33:00.003+05:30</published><updated>2009-07-01T12:05:10.579+05:30</updated><title type='text'>Oracle Database created as 32bit or 64bit</title><content type='html'>We can check the Database Created as 32bit Or 64bit Platform through below sql query&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;SQL&gt; select metadata from sys.kopm$ ;METADATA&lt;br /&gt;-----------------------------------------------------------0000006001240F050B0C030C0C0504050D0609070805050505050F05050505050A050505050504050607080823472323081123081141B023008300B207D00300000000000000000000000000000000000000000000000000000000000000000000000000&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;If above Colored Character Is "B023" means 32bit&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Or&lt;br /&gt;If it is "B047" means 64bit.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2493681572457119266-5590186449633294197?l=azardba.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://azardba.blogspot.com/feeds/5590186449633294197/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2493681572457119266&amp;postID=5590186449633294197' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/5590186449633294197'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/5590186449633294197'/><link rel='alternate' type='text/html' href='http://azardba.blogspot.com/2009/06/oracle-database-created-as-32bit-or.html' title='&lt;marquee behavior=&quot;alternate&quot;&gt;&lt;h2 style=&quot;color:red&quot;&gt;Oracle Database created as 32bit or 64bit&lt;/h2&gt;&lt;/marquee&gt;'/><author><name>Azar Mohamed Shaj</name><uri>http://www.blogger.com/profile/04251444414118162294</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://4.bp.blogspot.com/_M42FHtL_R7c/Stmn7gOmPCI/AAAAAAAAAGs/ff_HAJp76GI/S220/untitled.bmp'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2493681572457119266.post-718106911888039121</id><published>2009-06-29T19:19:00.002+05:30</published><updated>2009-07-01T12:07:35.055+05:30</updated><title type='text'>HWM -High Water Mark</title><content type='html'>Oracle, stores data in segments. Segments has free and used space. The mark(a logical mark) between free and used space can be called as high water mark(HWM). When new data filled, the mark moves. On deleting records, oracle does not move back HWM. That is, you have unused data but, HWM sees as if it were filled data. When you shrink table such as alter table move command, this HWM refreshes itself.&lt;br /&gt;&lt;br /&gt;When you delete from a table, a DML operation, oracle undos the changing. That is you can move back, with some additional works. But when you truncate a table, a DDL operation, oracle moves back the HWM. So this is faster than normal delete clause. With delete, you will fire existing triggers whereas truncate does not.&lt;br /&gt;&lt;br /&gt;Truncate is especially is used instead of dropping and recreating tables. with truncate, no objects will become invalid and grants are remains the same&lt;br /&gt;&lt;br /&gt;What Is Bottleneck ?&lt;br /&gt;&lt;br /&gt;Bottleneck is the slowest operations of the set of operations. It is important to identify in the bottleneck in the system to know what needs to be turned to be better Performance and scalabilty.&lt;br /&gt;&lt;br /&gt;Some Examples :-&lt;br /&gt;&lt;br /&gt;The I/O system may become a bottleneck on large database system.&lt;br /&gt;&lt;br /&gt;If a database used more memory than what’s available,paging and swapping will become a bottleneck.&lt;br /&gt;&lt;br /&gt;In a RAC system the interconnect may be overloaded (cannot handle all data transfers&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2493681572457119266-718106911888039121?l=azardba.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://azardba.blogspot.com/feeds/718106911888039121/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2493681572457119266&amp;postID=718106911888039121' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/718106911888039121'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/718106911888039121'/><link rel='alternate' type='text/html' href='http://azardba.blogspot.com/2009/06/hwm-high-water-mark.html' title='&lt;marquee behavior=&quot;alternate&quot;&gt;&lt;h2 style=&quot;color:red&quot;&gt;HWM -High Water Mark&lt;/h2&gt;&lt;/marquee&gt;'/><author><name>Azar Mohamed Shaj</name><uri>http://www.blogger.com/profile/04251444414118162294</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://4.bp.blogspot.com/_M42FHtL_R7c/Stmn7gOmPCI/AAAAAAAAAGs/ff_HAJp76GI/S220/untitled.bmp'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2493681572457119266.post-3857594036693753880</id><published>2009-06-29T19:09:00.003+05:30</published><updated>2009-07-01T12:41:40.927+05:30</updated><title type='text'>Connect sysdba</title><content type='html'>There is two method to connect sysdba user :-&lt;br /&gt;&lt;br /&gt;with password&lt;br /&gt;&lt;br /&gt;without password&lt;br /&gt;&lt;br /&gt;sql&gt; conn / as sysdba ------ without password&lt;br /&gt;&lt;br /&gt;* Oracle database user must have sysdba privileges.&lt;br /&gt;* Os user must add in dba group.&lt;br /&gt;* In sqlnet.ora file must content "NTS" in below line&lt;br /&gt;&lt;br /&gt;sqlnet.authentication_services = (NTS)&lt;br /&gt;****************************************************&lt;br /&gt;with password&lt;br /&gt;&lt;br /&gt;sql&gt;conn sys/pwd as sysdba ------- with password&lt;br /&gt;&lt;br /&gt;prevent to connect without password.&lt;br /&gt;* remove os user from dba group.&lt;br /&gt;* edit sqlnet.ora file and change "none" to "nts" in below line.&lt;br /&gt;sqlnet.authentication_services =(none)&lt;br /&gt;Default value is nts when sqlnet.ora file created.&lt;br /&gt;***************************** DBA ******************&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2493681572457119266-3857594036693753880?l=azardba.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://azardba.blogspot.com/feeds/3857594036693753880/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2493681572457119266&amp;postID=3857594036693753880' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/3857594036693753880'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/3857594036693753880'/><link rel='alternate' type='text/html' href='http://azardba.blogspot.com/2009/06/connect-sysdba.html' title='&lt;marquee behavior=&quot;alternate&quot;&gt;&lt;h2 style=&quot;color:red&quot;&gt;Connect sysdba&lt;/h2&gt;&lt;/marquee&gt;'/><author><name>Azar Mohamed Shaj</name><uri>http://www.blogger.com/profile/04251444414118162294</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://4.bp.blogspot.com/_M42FHtL_R7c/Stmn7gOmPCI/AAAAAAAAAGs/ff_HAJp76GI/S220/untitled.bmp'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2493681572457119266.post-5091084405593363162</id><published>2009-06-29T18:45:00.003+05:30</published><updated>2009-07-01T12:42:07.431+05:30</updated><title type='text'>IMPORT DUMPFILE WITHOUT KNOW EXPORT USER NAME</title><content type='html'>cmd&gt;imp file=&lt;dumpfile&gt; log=&lt;log&gt;  full=y show=y indexfile=&lt;&gt; userid=system/password&lt;br /&gt;&lt;br /&gt;for example&lt;br /&gt;&lt;br /&gt;cmd&gt;imp file=d:\test.dmp log=d:\tb\test.log full=y show=y indexfile=d:\tb\test.sql system/manager&lt;br /&gt;&lt;br /&gt;after execute this commands,you should go to check indexfile and logfile.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2493681572457119266-5091084405593363162?l=azardba.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://azardba.blogspot.com/feeds/5091084405593363162/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2493681572457119266&amp;postID=5091084405593363162' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/5091084405593363162'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/5091084405593363162'/><link rel='alternate' type='text/html' href='http://azardba.blogspot.com/2009/06/import-dumpfile-without-know-export.html' title='&lt;marquee behavior=&quot;alternate&quot;&gt;&lt;h2 style=&quot;color:red&quot;&gt;IMPORT DUMPFILE WITHOUT KNOW EXPORT USER NAME&lt;/h2&gt;&lt;/marquee&gt;'/><author><name>Azar Mohamed Shaj</name><uri>http://www.blogger.com/profile/04251444414118162294</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://4.bp.blogspot.com/_M42FHtL_R7c/Stmn7gOmPCI/AAAAAAAAAGs/ff_HAJp76GI/S220/untitled.bmp'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2493681572457119266.post-2093762151539026194</id><published>2008-12-05T21:11:00.004+05:30</published><updated>2009-07-01T12:42:35.463+05:30</updated><title type='text'>Remove Linux Partition</title><content type='html'>Hi..You would like to uninstall linux ... Do the follow steps&lt;br /&gt;&lt;br /&gt;&lt;ol&gt;&lt;li&gt;Before removing a partition, boot rescue mode &lt;/li&gt;&lt;li&gt;Start &lt;strong&gt;parted &lt;/strong&gt;,where /dev/hda is the device on which to remove the partition&lt;/li&gt;&lt;li&gt;In command mode&lt;/li&gt;&lt;li&gt;&gt;list hard-drives&lt;/li&gt;&lt;li&gt;&gt;parted /dev/hda or /dev/sda&lt;/li&gt;&lt;li&gt;&gt;print&lt;/li&gt;&lt;li&gt;&gt;rm 2&lt;/li&gt;&lt;li&gt;exit and then you can install another OS on your system like windows xp or any.&lt;/li&gt;&lt;/ol&gt;&lt;p&gt;&lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2493681572457119266-2093762151539026194?l=azardba.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://azardba.blogspot.com/feeds/2093762151539026194/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2493681572457119266&amp;postID=2093762151539026194' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/2093762151539026194'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/2093762151539026194'/><link rel='alternate' type='text/html' href='http://azardba.blogspot.com/2008/12/remove-linux-partition.html' title='&lt;marquee behavior=&quot;alternate&quot;&gt;&lt;h2 style=&quot;color:red&quot;&gt;Remove Linux Partition&lt;/h2&gt;&lt;/marquee&gt;'/><author><name>Azar Mohamed Shaj</name><uri>http://www.blogger.com/profile/04251444414118162294</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://4.bp.blogspot.com/_M42FHtL_R7c/Stmn7gOmPCI/AAAAAAAAAGs/ff_HAJp76GI/S220/untitled.bmp'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2493681572457119266.post-5494254918199295518</id><published>2008-11-22T17:09:00.002+05:30</published><updated>2008-11-22T17:35:00.040+05:30</updated><title type='text'>Common Oracle Database Recoveries</title><content type='html'>&lt;span style="color:#990000;"&gt;1. Loss of datafile(s)       System Tablespace :-&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;Action...&lt;br /&gt;&lt;br /&gt;sql&gt;shutdown immediate&lt;br /&gt;&lt;br /&gt;Oracle Instance shutdown.&lt;br /&gt;&lt;br /&gt;sql&gt;host cp backupfile file&lt;br /&gt;&lt;br /&gt;(Restore your data backup files from backup to related loss system’s datafiles)&lt;br /&gt;&lt;br /&gt;SQL&gt; CONNECT / AS SYSDBA&lt;br /&gt;&lt;br /&gt;SQL&gt; STARTUP MOUNT&lt;br /&gt;&lt;br /&gt;SQL&gt; RECOVER DATABASE;&lt;br /&gt;&lt;br /&gt;SQL&gt; ALTER DATABASE OPEN;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;----------------------------------------------------------------------------------------------------------------------------------------&lt;br /&gt;&lt;br /&gt;&lt;span style="color:#990000;"&gt;2.Loss of Non-system(s) Tablespace :-&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;Action...&lt;br /&gt;&lt;br /&gt;Don't need to shutdown database.&lt;br /&gt;&lt;br /&gt;sql&gt;alter tablespace  ......... offline&lt;br /&gt;&lt;br /&gt;SQL&gt; host cp backupfile file &lt;br /&gt;           (Restore your data backup files from backup to related loss system’s datafiles)&lt;br /&gt;&lt;br /&gt;SQL&gt; RECOVER TABLESPACE your_tablespace_name;&lt;br /&gt;&lt;br /&gt;SQL&gt; ALTER TABLESPACE your_tablespace_name ONLINE;&lt;br /&gt;&lt;br /&gt;&lt;span style="color:#990000;"&gt;Or    recover by using datafile(s)&lt;br /&gt;&lt;/span&gt;&lt;br /&gt;SQL&gt; ALTER DATAFILE  ‘/u01/…’ OFFLINE;&lt;br /&gt;&lt;br /&gt;SQL&gt; host cp backupfile file &lt;br /&gt;           (Restore your data backup files from backup to related loss system’s datafiles)&lt;br /&gt;SQL&gt; RECOVER DATAFILE ‘/u01…’;&lt;br /&gt;&lt;br /&gt;SQL&gt; ALTER DATAFIL ‘/u01/…’ ONLINE;&lt;br /&gt;&lt;br /&gt;&lt;span style="color:#990000;"&gt;Or shutdown database&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#3366ff;"&gt;&lt;/span&gt;&lt;br /&gt;SQL&gt; SHUTDOWN IMMDIATE;&lt;br /&gt;&lt;br /&gt;SQL&gt;  (Restore your data backup files from backup to related loss system’s datafiles)&lt;br /&gt;&lt;br /&gt;SQL&gt; STARTUP MOUNT;&lt;br /&gt;&lt;br /&gt;SQL&gt; RECOVER DATABASE;&lt;br /&gt;&lt;br /&gt;SQL&gt; ALTER DATABASE OPEN&lt;br /&gt;&lt;br /&gt;----------------------------------------------------------------------------------------------------------------------------------------&lt;br /&gt;&lt;span style="color:#990000;"&gt;3.Loss of data file(s) of rollback OR undo segments tablespace :-&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#3366ff;"&gt;&lt;/span&gt;&lt;br /&gt;A datafile in a rollback segment tablespace has been lost or damaged to a point that&lt;br /&gt;Oracle cannot recognize it anymore.If you try to startup the database will result in ORA-1157, ORA-1110, and possibly an operating system level error such as ORA-7360. Trying to shut down the database&lt;br /&gt;in normal or immediate mode will result in ORA-1116, ORA-1110, and possiblyan operating system level error such as ORA-7368. &lt;br /&gt;&lt;span style="color:#3366ff;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#990000;"&gt;PLEASE NOTE&lt;/span&gt; that before using _corrupted_rollback_segments parameter, you should&lt;br /&gt;explore all other options. This will require extra caution. Call Oracle Customer Support if you have any questions or need any assistance&lt;br /&gt;&lt;br /&gt;The Database is down:&lt;br /&gt;----------------------------------------------------------------------------------------------------------------------------------------&lt;br /&gt;&lt;span style="color:#990000;"&gt;Assuming that your database was cleanly shutdown (check your alert.log)&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#990000;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#000000;"&gt;SQL&gt; SHUTDOWN IMMEDIATE/NORMAL&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#000000;"&gt;&lt;br /&gt;SQL&gt; STARTUP RESTRICT MOUNT&lt;br /&gt;&lt;br /&gt;SQL&gt; ALTER DATABASE DATAFILE '&lt;full_path_file_name&gt;' OFFLINE DROP;&lt;br /&gt;&lt;br /&gt;SQL&gt; ALTER DATABASE OPEN&lt;br /&gt;&lt;br /&gt;SQL&gt; DROP TABLESPACE &lt;tablespace_name&gt; INCLUDING CONTENTS;&lt;br /&gt;&lt;/span&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style="color:#000000;"&gt;SQL&gt; -- Recreate the rollback tablespace with all its rollback segments.&lt;br /&gt;   Remember to bring the rollbacks online after you create them. &lt;/span&gt;&lt;br /&gt;----------------------------------------------------------------------------------------------------------------------------------------&lt;br /&gt;&lt;br /&gt;&lt;span style="color:#990000;"&gt;Assuming that you cann't open your database and you get the following error&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;messages: ORA-604, ORA-376, and ORA-1110.&lt;br /&gt;-- Comment out the ROLLBACK_SEGMENTS parameter and add the following line:&lt;br /&gt;_corrupted_rollback_segments = ( &lt;rollback1&gt;,...., &lt;rollbackn&gt; )&lt;br /&gt;with exact the same rollbacks.&lt;br /&gt;WARNING: Use this parameter ONLY IN THIS SPECIFIC SCENARIO or as&lt;br /&gt;instructed by Oracle Customer Support.&lt;br /&gt;&lt;br /&gt;SQL&gt; STARTUP RESTRICT&lt;br /&gt;&lt;br /&gt;SQL&gt; DROP TABLESPACE &lt;tablespace_name&gt; INCLUDING CONTENTS;&lt;br /&gt;&lt;br /&gt;SQL&gt; Recreate the rollback tablespace with all its rollback segments.&lt;br /&gt;&lt;br /&gt;SQL&gt; ALTER SYSTEM DISABLE RESTRICTED SESSION;&lt;br /&gt;&lt;br /&gt;-- put back your ROLLBACK_SEGMENTS parameter in the init.ora file.&lt;br /&gt;-- remove _CORRUPTED_ROLLBACK_SEGMENTS PARAMETER&lt;br /&gt;&lt;br /&gt;SQL&gt; -- Rebuild the database.&lt;br /&gt;----------------------------------------------------------------------------------------------------------------------------------------&lt;br /&gt;&lt;br /&gt;&lt;span style="color:#990000;"&gt;Assuming that database was not cleanly shutdown:&lt;/span&gt;&lt;br /&gt;-- Restore the lost file from a backup.&lt;br /&gt;&lt;br /&gt;SQL&gt; STARTUP MOUNT&lt;br /&gt;&lt;br /&gt;SQL&gt; SELECT FILE#, NAME, STATUS FROM V$DATAFILE;&lt;br /&gt;&lt;br /&gt;SQL&gt; ALTER DATABASE DATAFILE '&lt;full_path_file_name&gt;' ONLINE;&lt;br /&gt;     (if datafile is offline)&lt;br /&gt;&lt;br /&gt;SQL&gt; SELECT V1.GROUP#, MEMBER, SEQUENCE#, FIRST_CHANGE#&lt;br /&gt;        FROM V$LOG V1, V$LOGFILE V2&lt;br /&gt;        WHERE V1.GROUP# = V2.GROUP# ;&lt;br /&gt;&lt;br /&gt;SQL&gt; SELECT FILE#, CHANGE# FROM V$RECOVER_FILE;&lt;br /&gt;&lt;br /&gt;If NOARCHIVELOG Mode and the CHANGE# is GREATER than the minimum FIRST_CHANGE#&lt;br /&gt;of your logs, the datafile can be recovered.&lt;br /&gt;&lt;br /&gt;SQL&gt; RECOVER DATAFILE '&lt;full_path_file_name&gt;';&lt;br /&gt;&lt;br /&gt;SQL&gt; ALTER DATABASE OPEN;&lt;br /&gt;&lt;br /&gt;----------------------------------------------------------------------------------------------------------------------------------------&lt;br /&gt;&lt;span style="color:#990000;"&gt;Assuming that the database is up and it is in ARCHIVELOG mode:&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#990000;"&gt;&lt;/span&gt;&lt;br /&gt;SQL&gt; ALTER DATABASE DATAFILE '&lt;full_path_file_name&gt;' OFFLINE;&lt;br /&gt;&lt;br /&gt;SQL&gt; -- Restore it from your backup.&lt;br /&gt;&lt;br /&gt;SQL&gt; RECOVER DATAFILE '&lt;full_path_file_name&gt;';&lt;br /&gt;&lt;br /&gt;SQL&gt; ALTER DATABASE DATAFILE '&lt;full_path_file_name&gt;' ONLINE;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;-OR-&lt;br /&gt;&lt;br /&gt;SQL&gt; ALTER SYSTEM KILL SESSION ' , ' -- The transaction in RBS involved.&lt;br /&gt;&lt;br /&gt;SQL&gt; ALTER ROLLBACK SEGMENT &lt;rollback_segment&gt; OFFLINE;&lt;br /&gt;\&lt;br /&gt;SQL&gt; DROP ROLLBACK SEGMENT &lt;rollback_segment&gt;;&lt;br /&gt;&lt;br /&gt;SQL&gt; DROP TABLESPACE &lt;tablespace_name&gt; INCLUDING CONTENTS;  &lt;br /&gt;&lt;br /&gt;SQL&gt; CREATE TABLESPACE rbs ...;&lt;br /&gt;&lt;br /&gt;SQL&gt; CREATE ROLLBACK SEGMENT rbs01 ...;&lt;br /&gt;&lt;br /&gt;SQL&gt; ALTER ROLLBACK SEGMENT ... ONLINE;&lt;br /&gt;----------------------------------------------------------------------------------------------------------------------------------------&lt;br /&gt;&lt;br /&gt;&lt;span style="color:#990000;"&gt; In this case to access to data you will get a message like this:&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#990000;"&gt;&lt;/span&gt;&lt;br /&gt;ORA-00376: file 20 connot be read at this time&lt;br /&gt;File 2 happens to be one of the data files that belongs to the rollback segment tablespace.&lt;br /&gt;&lt;br /&gt;Solution:&lt;br /&gt;&lt;br /&gt;SQL&gt; select segment_name, status from dba_rollback_segs;&lt;br /&gt;           (If status are in “NEED RECOVERY”)&lt;br /&gt;&lt;br /&gt;SQL&gt; SHOW PARAMETER undo&lt;br /&gt;&lt;br /&gt;SQL&gt; CREATE UNDO TABLESPACE  myundotbs DATAFILE ‘/u01/…’ SIZE 50M;&lt;br /&gt;&lt;br /&gt;SQL&gt; ALTER SYSTEM SET undo_tablespace=’myundotbs’;&lt;br /&gt;&lt;br /&gt;SQL&gt; DROP TABLESPACE undotbs;&lt;br /&gt;           (Remove all related OS datafiles)&lt;br /&gt;----------------------------------------------------------------------------------------------------------------------------------------&lt;br /&gt;&lt;span style="color:#990000;"&gt;       Loss of Rollback segments while there were transaction activities;&lt;br /&gt;&lt;/span&gt;&lt;br /&gt;For example:&lt;br /&gt;&lt;br /&gt;SQL&gt; CREATE TABLE mytest (col1 varchar2(20));&lt;br /&gt;&lt;br /&gt;SQL&gt; BEGIN&lt;br /&gt;                        FOR this IN 1..100 LOOP&lt;br /&gt;                                        INSERT INTO mytest VALUSE (this);&lt;br /&gt;                        END LOOP;&lt;br /&gt;            END;&lt;br /&gt;            /&lt;br /&gt;&lt;br /&gt;SQL&gt; /* Notice that we didn’t commit any of above transaction */&lt;br /&gt;&lt;br /&gt;SQL&gt; /* shutdown abort or any crash on rollback datafiles will cause&lt;br /&gt;&lt;br /&gt;The following error messages if we start the database. */&lt;br /&gt;ORA-01157: cannot identify/lock data file 20 – see DBWR trace file&lt;br /&gt;ORA-01110: data file 20: ‘/u01/…’&lt;br /&gt;&lt;br /&gt;Solution:&lt;br /&gt;&lt;br /&gt;If you shutdown the server then you will get a message like this:&lt;br /&gt;ORA-01157: cannot identify/lock data file 8 - see DBWR trace file&lt;br /&gt;ORA-01110: data file 8: 'C:\MYUNDOTBS_01.DBF'&lt;br /&gt;&lt;br /&gt;SQL&gt; STARTUP MOUNT&lt;br /&gt;&lt;br /&gt;SQL&gt; ALTER DATABASE DATAFILE 'C:\MYUNDOTBS_01.DBF' OFFLINE;&lt;br /&gt;&lt;br /&gt;SQL&gt; ALTER DATABASE OPEN;&lt;br /&gt;&lt;br /&gt;SQL&gt; /* remember you can not access to that table with transaction */&lt;br /&gt;&lt;br /&gt;SQL&gt; SELECT segment_name, status FROM dba_rollback_segs;&lt;br /&gt;           (You will see that the segments are NEEDS RECOVERY)&lt;br /&gt;&lt;br /&gt;SQL&gt; /* replace your backup file and recover the tablespace */&lt;br /&gt;&lt;br /&gt;SQL&gt; RECOVER TABLESPACE your_tablespace_name;&lt;br /&gt;&lt;br /&gt;SQL&gt; ALTER TABLESPACE your_tablespace_name ONLINE;&lt;br /&gt;&lt;br /&gt;SQL&gt; ALTER ROLLBACK SEGMENT … ONLINE;&lt;br /&gt;           (Repeat this for all of your rollback segments)&lt;br /&gt;&lt;br /&gt;If you are not shutdown:&lt;br /&gt;&lt;br /&gt;SQL&gt; ALTER DATABASE DATAFILE 'C:\MYUNDOTBS_01.DBF' OFFLINE;&lt;br /&gt;&lt;br /&gt;SQL&gt; /* remember you can not access to that table with transaction */&lt;br /&gt;&lt;br /&gt;SQL&gt; SELECT tablespace_name, segment_name, status FROM dba_rollback_segs;&lt;br /&gt;           (You will see that the segments are NEEDS RECOVERY)&lt;br /&gt;&lt;br /&gt;SQL&gt; /* replace your backup file and recover the tablespace */&lt;br /&gt;&lt;br /&gt;SQL&gt; RECOVER TABLESPACE your_tablespace_name;&lt;br /&gt;&lt;br /&gt;SQL&gt; ALTER TABLESPACE your_tablespace_name ONLINE;&lt;br /&gt;&lt;br /&gt;SQL&gt; ALTER ROLLBACK SEGMENT … ONLINE;&lt;br /&gt;           (Repeat this for all of your rollback segments)&lt;br /&gt;&lt;br /&gt;----------------------------------------------------------------------------------------------------------------------------------------&lt;br /&gt;&lt;span style="color:#990000;"&gt;.        Loss of an UN-archived Online log file.&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#990000;"&gt;&lt;/span&gt;&lt;br /&gt;Solution:&lt;br /&gt;&lt;br /&gt;SQL&gt; /* Your database is done. */&lt;br /&gt;&lt;br /&gt;SQL&gt; /* Replace all your datafiles and online redo logfile, but not controlfiles. */&lt;br /&gt;&lt;br /&gt;SQL&gt; host cp … …&lt;br /&gt;&lt;br /&gt;SQL&gt; STARTUP MOUNT&lt;br /&gt;&lt;br /&gt;SQL&gt; RECOVER DATABASE UNTIL CANCEL;  --  UNTIL TIME …&lt;br /&gt;&lt;br /&gt;SQL&gt; ALTER DATABASE OPEN RESETLOGS;&lt;br /&gt;           /* Since you did incomplete recovery, you must use ‘RESETLOGS’ option.&lt;br /&gt;&lt;br /&gt;SQL&gt; SHUTDOWN IMMEDIATE&lt;br /&gt;           /* Do your cold backup immediately */&lt;br /&gt;&lt;br /&gt;&lt;span style="color:#990000;"&gt;Loss of your Online Redo-log files.&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#990000;"&gt;&lt;br /&gt;&lt;/span&gt;Solution:&lt;br /&gt;&lt;br /&gt;&lt;/span&gt;SQL&gt; /* If you loss your online redo-log files, your instance will hung or crash.&lt;br /&gt;                If not, try to shutdown abort. Restore all files from your cold backup&lt;br /&gt;                with exception of your control files. */&lt;br /&gt;&lt;br /&gt;SQL&gt; STARTUP MOUNT&lt;br /&gt;&lt;br /&gt;SQL&gt; /* Now do an incomplete recovery recover using CANCEL or TIME option */&lt;br /&gt;&lt;br /&gt;SQL&gt; RECOVER DATABASE UNTIL CANCEL;&lt;br /&gt;          /* you should apply up to your last archive and then cancel the recovery process */&lt;br /&gt;&lt;br /&gt;SQL&gt; ALTER DATABASE OPEN RESETLOGS;&lt;br /&gt;           /* Since you did incomplete recovery, you must use ‘RESETLOGS’ option.&lt;br /&gt;&lt;br /&gt;SQL&gt; SHUTDOWN IMMEDIATE&lt;br /&gt;           /* Do your cold backup immediately */&lt;br /&gt;&lt;span style="color:#000000;"&gt;---------------------------------------------------------------------------------------------------------------------------------------&lt;/span&gt;  &lt;span style="color:#990000;"&gt;Loss of your control file.&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#990000;"&gt;&lt;/span&gt;&lt;br /&gt;Solution:&lt;br /&gt;&lt;br /&gt;SQL&gt; /* Assuming you have already backup controlfile to trace */&lt;br /&gt;&lt;br /&gt;SQL&gt; ALTER DATABASE BACKUP CONTROLFILE TO trace;&lt;br /&gt;&lt;br /&gt;SQL&gt; /* modify and run your trace file and your control file is up to date */&lt;br /&gt;&lt;br /&gt;SQL&gt; /* if not, then copy a old control file */&lt;br /&gt;&lt;br /&gt;SQL&gt; STARTUP MOUNT;&lt;br /&gt;&lt;br /&gt;SQL&gt; RECOVER DATABASE USING BACKUP CONTROLFILE;&lt;br /&gt;&lt;br /&gt;SQL&gt; ALTER DATABASE OPEN;&lt;br /&gt;&lt;br /&gt;Database Opened.&lt;br /&gt;&lt;span style="color:#000000;"&gt;&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2493681572457119266-5494254918199295518?l=azardba.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://azardba.blogspot.com/feeds/5494254918199295518/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2493681572457119266&amp;postID=5494254918199295518' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/5494254918199295518'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/5494254918199295518'/><link rel='alternate' type='text/html' href='http://azardba.blogspot.com/2008/11/common-oracle-database-recoveries.html' title='Common Oracle Database Recoveries'/><author><name>Azar Mohamed Shaj</name><uri>http://www.blogger.com/profile/04251444414118162294</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://4.bp.blogspot.com/_M42FHtL_R7c/Stmn7gOmPCI/AAAAAAAAAGs/ff_HAJp76GI/S220/untitled.bmp'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2493681572457119266.post-6477099943541647392</id><published>2008-11-22T16:20:00.004+05:30</published><updated>2009-07-01T12:45:14.794+05:30</updated><title type='text'>Change Database Name</title><content type='html'>SQL&gt; SELECT NAME FROM V$DATABASE;&lt;br /&gt;&lt;br /&gt;Name&lt;br /&gt;-------&lt;br /&gt;localdb&lt;br /&gt;&lt;br /&gt;sql&gt;shutdown immediate&lt;br /&gt;&lt;br /&gt;Oracle instance shutdown.&lt;br /&gt;&lt;br /&gt;sql&gt;startup mount&lt;br /&gt;&lt;br /&gt;database mounted.&lt;br /&gt;&lt;br /&gt;&lt;strong&gt;NID: it’s a naming utility; you can able to change your database name and database id. &lt;/strong&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;C:\&gt;nid help=y&lt;br /&gt;&lt;br /&gt;DBNEWID: Release 10.2.0.1.0 - Production on Mon May 14 10:48:33 2007&lt;br /&gt;Copyright (c) 1982, 2005, Oracle. All rights reserved.&lt;br /&gt;Keyword Description (Default)&lt;br /&gt;----------------------------------------------------&lt;br /&gt;TARGET Username/Password (NONE)&lt;br /&gt;&lt;br /&gt;DBNAME New database name (NONE)&lt;br /&gt;&lt;br /&gt;LOGFILE Output Log (NONE)&lt;br /&gt;&lt;br /&gt;REVERT Revert failed change NO&lt;br /&gt;&lt;br /&gt;SETNAME Set a new database name only NO&lt;br /&gt;&lt;br /&gt;APPEND Append to output log NO&lt;br /&gt;&lt;br /&gt;HELP Displays these messages NO&lt;br /&gt;&lt;br /&gt;Here, I have change my database name using NID utility.&lt;br /&gt;&lt;br /&gt;C:\&gt;NID &lt;a href="mailto:TARGET=SYS/sys@localdb"&gt;TARGET=SYS/sys@localdb&lt;/a&gt; DBNAME=local SETNAME=Y&lt;br /&gt;&lt;br /&gt;DBNEWID: Release 10.2.0.1.0 - Production on Mon May 14 10:37:36 2007Copyright (c) 1982, 2005, Oracle.&lt;br /&gt;&lt;br /&gt;All rights reserved.Connected to database TAJ (DBID=1565772587)Connected to server version 10.2.0Control Files in database:&lt;br /&gt;&lt;br /&gt;F:\ORACLE\PRODUCT\10.2.0\ORADATA\localdb\CONTROL01.CTL&lt;br /&gt;&lt;br /&gt;F:\ORACLE\PRODUCT\10.2.0\ORADATA\localdb\CONTROL02.CTL&lt;br /&gt;&lt;br /&gt;F:\ORACLE\PRODUCT\10.2.0\ORADATA\localdb\CONTROL03.CTL&lt;br /&gt;Change database name of database localdb to local ? (Y/[N]) =&gt; Y Proceeding with operationChanging database name from localdb to local&lt;br /&gt;Control File F:\ORACLE\PRODUCT\10.2.0\ORADATA\localdb\CONTROL01.CTL - modifiedControl File&lt;br /&gt;&lt;br /&gt;F:\ORACLE\PRODUCT\10.2.0\ORADATA\localdb\CONTROL02.CTL - modifiedControl File&lt;br /&gt;&lt;br /&gt;F:\ORACLE\PRODUCT\10.2.0\ORADATA\localdb\CONTROL03.CTL - modifiedDatafile&lt;br /&gt;&lt;br /&gt;F:\ORACLE\PRODUCT\10.2.0\ORADATA\localdb\SYSTEM01.DBF - wrote new nameDatafile&lt;br /&gt;&lt;br /&gt;F:\ORACLE\PRODUCT\10.2.0\ORADATA\localdb\UNDOTBS01.DBF - wrote new nameDatafile&lt;br /&gt;&lt;br /&gt;F:\ORACLE\PRODUCT\10.2.0\ORADATA\localdb\SYSAUX01.DBF - wrote new nameDatafile&lt;br /&gt;&lt;br /&gt;F:\ORACLE\PRODUCT\10.2.0\ORADATA\localdb\USERS01.DBF - wrote new nameDatafile&lt;br /&gt;&lt;br /&gt;F:\ORACLE\PRODUCT\10.2.0\ORADATA\localdb\EXAMPLE01.DBF - wrote new nameDatafile&lt;br /&gt;&lt;br /&gt;F:\ORACLE\PRODUCT\10.2.0\ORADATA\localdb\RMAN01.DBF - wrote new nameDatafile&lt;br /&gt;&lt;br /&gt;F:\ORACLE\PRODUCT\10.2.0\ORADATA\localdb\TEMP01.DBF - wrote new nameControl File&lt;br /&gt;&lt;br /&gt;F:\ORACLE\PRODUCT\10.2.0\ORADATA\localdb\CONTROL01.CTL - wrote new nameControl File&lt;br /&gt;&lt;br /&gt;F:\ORACLE\PRODUCT\10.2.0\ORADATA\localdb\CONTROL02.CTL - wrote new nameControl File&lt;br /&gt;&lt;br /&gt;F:\ORACLE\PRODUCT\10.2.0\ORADATA\localdb\CONTROL03.CTL - wrote new nameInstance&lt;br /&gt;&lt;br /&gt;shut downDatabase name changed to local.Modify parameter file and generate a new password file before restarting.Succesfully changed database name.DBNEWID - Completed succesfully&lt;br /&gt;&lt;br /&gt;c:\&gt;oradim -new -sid local&lt;br /&gt;instance created.&lt;br /&gt;&lt;br /&gt;c:\&gt;net start oracle servicelocal&lt;br /&gt;service started.&lt;br /&gt;&lt;br /&gt;c:\&gt;set oracle_sid=local&lt;br /&gt;&lt;br /&gt;c:\&gt;slplus /nolog&lt;br /&gt;&lt;br /&gt;sql&gt;conn sys as sysdba&lt;br /&gt;&lt;br /&gt;enter new password: sys (choice)&lt;br /&gt;&lt;br /&gt;connected to idle instane.&lt;br /&gt;&lt;br /&gt;You should check your parameter file and modify it. and replace local instead of localdb&lt;br /&gt;&lt;br /&gt;sql&gt;startup mount&lt;br /&gt;&lt;br /&gt;database mounted.&lt;br /&gt;&lt;br /&gt;Note :- ora-02778 : Name given for the log directory is invalid. In this case, you should check your parameter file name&lt;br /&gt;&lt;br /&gt;sql&gt;alter database open;&lt;br /&gt;&lt;br /&gt;database opened.&lt;br /&gt;&lt;br /&gt;sql&gt;select name from v$database;&lt;br /&gt;&lt;br /&gt;Name&lt;br /&gt;&lt;br /&gt;----------&lt;br /&gt;local&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2493681572457119266-6477099943541647392?l=azardba.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://azardba.blogspot.com/feeds/6477099943541647392/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2493681572457119266&amp;postID=6477099943541647392' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/6477099943541647392'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/6477099943541647392'/><link rel='alternate' type='text/html' href='http://azardba.blogspot.com/2008/11/change-database-name.html' title='&lt;marquee behavior=&quot;alternate&quot;&gt;&lt;h2 style=&quot;color:red&quot;&gt;Change Database Name&lt;/h2&gt;&lt;/marquee&gt;'/><author><name>Azar Mohamed Shaj</name><uri>http://www.blogger.com/profile/04251444414118162294</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://4.bp.blogspot.com/_M42FHtL_R7c/Stmn7gOmPCI/AAAAAAAAAGs/ff_HAJp76GI/S220/untitled.bmp'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2493681572457119266.post-7522421363040971511</id><published>2008-11-22T15:11:00.003+05:30</published><updated>2008-11-22T16:34:46.273+05:30</updated><title type='text'></title><content type='html'>&lt;span style="color:#ff6600;"&gt;Ora -32004&lt;/span&gt; --- obsolete and/or deprecated parameter(s) specified&lt;br /&gt;&lt;br /&gt;Actions....&lt;br /&gt;&lt;br /&gt;See alert log for of parameters that are obsolete or deprecated .remove them from spfileor the server side pfile.&lt;br /&gt;&lt;br /&gt;sql&gt;select name,isspecified from v$obsolete_parameter where is isspecified ='TRUE';&lt;br /&gt;&lt;br /&gt;In my case somebody had been messing around with the parameter log_archive_start;&lt;br /&gt;&lt;br /&gt;sql&gt;alter system reset log_archive_start scope=spfile sid='*';&lt;br /&gt;system altered.&lt;br /&gt;&lt;br /&gt;sql&gt;shut&lt;br /&gt;&lt;br /&gt;sql&gt;startup&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2493681572457119266-7522421363040971511?l=azardba.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://azardba.blogspot.com/feeds/7522421363040971511/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2493681572457119266&amp;postID=7522421363040971511' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/7522421363040971511'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/7522421363040971511'/><link rel='alternate' type='text/html' href='http://azardba.blogspot.com/2008/11/ora-32004-obsolete-andor-deprecated.html' title=''/><author><name>Azar Mohamed Shaj</name><uri>http://www.blogger.com/profile/04251444414118162294</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://4.bp.blogspot.com/_M42FHtL_R7c/Stmn7gOmPCI/AAAAAAAAAGs/ff_HAJp76GI/S220/untitled.bmp'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2493681572457119266.post-4781630745199353744</id><published>2008-11-22T15:02:00.003+05:30</published><updated>2008-11-22T16:35:12.170+05:30</updated><title type='text'></title><content type='html'>&lt;span style="color:#ff6600;"&gt;Ora-01092&lt;/span&gt; - Oracle instance terminated&lt;br /&gt;&lt;br /&gt;Examine the alert log files for more information.&lt;br /&gt;&lt;br /&gt;Actions.......&lt;br /&gt;&lt;br /&gt;&lt;ul&gt;&lt;li&gt;Shutdown abort&lt;/li&gt;&lt;li&gt;Bad permissions of BDUMP, UDUMP or CDUMP Directories&lt;/li&gt;&lt;li&gt;Missing Datafiles&lt;/li&gt;&lt;li&gt;Renaming files when oracle is down&lt;/li&gt;&lt;li&gt;&amp;amp; many other os related causes&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;Check the parameter files whether datafiles or some files are located correct or not.&lt;/p&gt;&lt;p&gt;&lt;/p&gt;&lt;p&gt;&lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2493681572457119266-4781630745199353744?l=azardba.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://azardba.blogspot.com/feeds/4781630745199353744/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2493681572457119266&amp;postID=4781630745199353744' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/4781630745199353744'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/4781630745199353744'/><link rel='alternate' type='text/html' href='http://azardba.blogspot.com/2008/11/ora-01092-oracle-instance-terminated.html' title=''/><author><name>Azar Mohamed Shaj</name><uri>http://www.blogger.com/profile/04251444414118162294</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://4.bp.blogspot.com/_M42FHtL_R7c/Stmn7gOmPCI/AAAAAAAAAGs/ff_HAJp76GI/S220/untitled.bmp'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2493681572457119266.post-4963440887975100067</id><published>2008-11-22T14:57:00.002+05:30</published><updated>2008-11-22T14:59:07.668+05:30</updated><title type='text'>Recover</title><content type='html'>Recover database....&lt;br /&gt;&lt;br /&gt;recover database until cancel&lt;br /&gt;recover database until time '2004-03-21:22:59:04'&lt;br /&gt;recover database until change 123456&lt;br /&gt;&lt;br /&gt;recover datafile 'filename' until cancel&lt;br /&gt;recover datafile 'filename' until time '2004-03-21:22:59:04'&lt;br /&gt;recover datafile 'filename' until change 123456&lt;br /&gt;&lt;br /&gt;recover tablespace ts_name until cancel&lt;br /&gt;recover tablespace ts_name until time '2004-03-21:22:59:04'&lt;br /&gt;recover tablespace ts_name until change 123456&lt;br /&gt;&lt;br /&gt;recover database using backup controlfile&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2493681572457119266-4963440887975100067?l=azardba.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://azardba.blogspot.com/feeds/4963440887975100067/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2493681572457119266&amp;postID=4963440887975100067' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/4963440887975100067'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/4963440887975100067'/><link rel='alternate' type='text/html' href='http://azardba.blogspot.com/2008/11/recover.html' title='Recover'/><author><name>Azar Mohamed Shaj</name><uri>http://www.blogger.com/profile/04251444414118162294</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://4.bp.blogspot.com/_M42FHtL_R7c/Stmn7gOmPCI/AAAAAAAAAGs/ff_HAJp76GI/S220/untitled.bmp'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2493681572457119266.post-1747825652260405918</id><published>2008-11-22T14:44:00.002+05:30</published><updated>2008-11-22T14:55:13.356+05:30</updated><title type='text'>Database Size</title><content type='html'>I want to find the size....&lt;br /&gt;&lt;br /&gt;sql&gt;show parameter db_block_size;&lt;br /&gt;&lt;br /&gt;Name                                     Type                       Value&lt;br /&gt;-----------------------------------------------------------&lt;br /&gt;db_block_size                integer                     8192&lt;br /&gt;&lt;br /&gt;How to check the size in Oracle 9i&lt;br /&gt;&lt;br /&gt;sql&gt;select segment_name ,bytes/1024 as totsize_bytes, (blocks * 8192)/1024 as totbytes from user_segments where segment_name = upper('&amp;amp;1') and segment_type='TABLE';&lt;br /&gt;&lt;br /&gt;Enter value for 1:&lt;br /&gt;&lt;br /&gt;If you put any segment name and then you will see that table size.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2493681572457119266-1747825652260405918?l=azardba.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://azardba.blogspot.com/feeds/1747825652260405918/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2493681572457119266&amp;postID=1747825652260405918' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/1747825652260405918'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/1747825652260405918'/><link rel='alternate' type='text/html' href='http://azardba.blogspot.com/2008/11/database-size.html' title='Database Size'/><author><name>Azar Mohamed Shaj</name><uri>http://www.blogger.com/profile/04251444414118162294</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://4.bp.blogspot.com/_M42FHtL_R7c/Stmn7gOmPCI/AAAAAAAAAGs/ff_HAJp76GI/S220/untitled.bmp'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2493681572457119266.post-2057428394081431499</id><published>2008-11-22T12:21:00.003+05:30</published><updated>2008-11-22T12:34:03.453+05:30</updated><title type='text'>Online user managed backup</title><content type='html'>Step 1 :-&lt;br /&gt;&lt;br /&gt;&lt;ul&gt;&lt;li&gt;Put the tablespace in backup mode&lt;/li&gt;&lt;li&gt;Copy the datafiles which tablespace in backup mode&lt;/li&gt;&lt;li&gt;Once copy the datafiles is completed putout from the backup mode&lt;/li&gt;&lt;li&gt;switch logfile&lt;/li&gt;&lt;li&gt;archive log mode is enabled&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;Step 2 :-&lt;/p&gt;&lt;p&gt;sql&gt; select tablespace_name from dba_data_files;&lt;/p&gt;&lt;p&gt;tablespace_name&lt;/p&gt;&lt;p&gt;----------------------------------&lt;/p&gt;&lt;p&gt;system&lt;/p&gt;&lt;p&gt;sysaux&lt;/p&gt;&lt;p&gt;users&lt;/p&gt;&lt;p&gt;undo&lt;/p&gt;&lt;p&gt;temp&lt;/p&gt;&lt;p&gt;example&lt;/p&gt;&lt;p&gt;sql&gt;alter tablespace system begin backup;&lt;/p&gt;&lt;p&gt;sql&gt;host copy E:\oracle\product\10.2.0\oradata\localdb\system01.dbf e:\oracle\backup;&lt;/p&gt;&lt;p&gt;1 files copied&lt;/p&gt;&lt;p&gt;sql&gt;select * from v$backup;&lt;/p&gt;&lt;p&gt;file status change# time&lt;/p&gt;&lt;p&gt;-----------------------------------------------&lt;/p&gt;&lt;p&gt;1 active 1134456 22-nov-08&lt;/p&gt;&lt;p&gt;2 not active 0 &lt;/p&gt;&lt;p&gt;" " "&lt;/p&gt;&lt;p&gt;sql&gt; alter tablespace system end backup;&lt;/p&gt;&lt;p&gt;system altered.&lt;/p&gt;&lt;p&gt;After exec, you should check the any datafiles in backup mode. If any datafiles in backup mode ,you should exec end backup condition after taken backup datafiles.&lt;/p&gt;&lt;p&gt;sql&gt;alter system switch logfile;&lt;/p&gt;&lt;p&gt;system altered.&lt;/p&gt;&lt;p&gt;&lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2493681572457119266-2057428394081431499?l=azardba.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://azardba.blogspot.com/feeds/2057428394081431499/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2493681572457119266&amp;postID=2057428394081431499' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/2057428394081431499'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/2057428394081431499'/><link rel='alternate' type='text/html' href='http://azardba.blogspot.com/2008/11/online-user-managed-backup.html' title='Online user managed backup'/><author><name>Azar Mohamed Shaj</name><uri>http://www.blogger.com/profile/04251444414118162294</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://4.bp.blogspot.com/_M42FHtL_R7c/Stmn7gOmPCI/AAAAAAAAAGs/ff_HAJp76GI/S220/untitled.bmp'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2493681572457119266.post-1263877595923195276</id><published>2008-11-18T15:10:00.003+05:30</published><updated>2008-11-22T14:43:31.847+05:30</updated><title type='text'>Cold Backup</title><content type='html'>This is consistent backup that means all datafiles and controlfiles are consistent to point in time.database in no archive log mode.&lt;br /&gt;&lt;br /&gt;Steps....&lt;br /&gt;&lt;br /&gt;&lt;ul&gt;&lt;li&gt;shutdown the database ,sql&gt;shutdown normal&lt;/li&gt;&lt;li&gt;Copy the controlfiles and datafiles,parameter file and passwordfile os level and then paste it in another location.&lt;/li&gt;&lt;li&gt;startup database ,sql&gt;startup&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;Example.....&lt;/p&gt;&lt;ul&gt;&lt;li&gt;shutdown the database, drop the all controlfiles and datafiles and then startup the database.&lt;/li&gt;&lt;li&gt;Error ora-00205-Error in identifying the control files for the location.&lt;/li&gt;&lt;li&gt;If you have 5 multiplexing controlfiles,2 multiplexing in different location and remain 3 controlfiles were dropped,you should modify the location in parameter file current controlfile and then save it.&lt;/li&gt;&lt;li&gt;startup the database using parameter files.&lt;/li&gt;&lt;li&gt;In mount database,error will appear.&lt;/li&gt;&lt;li&gt;Recover datafile system and then some datafile , in this case you should copy the backup files and paste it in default location.&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;sql&gt;recover database;&lt;/p&gt;&lt;p&gt;media recovery complete.&lt;/p&gt;&lt;p&gt;sql&gt;alter database open;&lt;/p&gt;&lt;p&gt;Database opened.&lt;/p&gt;&lt;p&gt;&lt;/p&gt;&lt;p&gt;&lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2493681572457119266-1263877595923195276?l=azardba.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://azardba.blogspot.com/feeds/1263877595923195276/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2493681572457119266&amp;postID=1263877595923195276' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/1263877595923195276'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/1263877595923195276'/><link rel='alternate' type='text/html' href='http://azardba.blogspot.com/2008/11/cold-backup-this-is-consistent-backup.html' title='Cold Backup'/><author><name>Azar Mohamed Shaj</name><uri>http://www.blogger.com/profile/04251444414118162294</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://4.bp.blogspot.com/_M42FHtL_R7c/Stmn7gOmPCI/AAAAAAAAAGs/ff_HAJp76GI/S220/untitled.bmp'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2493681572457119266.post-526750254363931411</id><published>2008-11-17T16:16:00.004+05:30</published><updated>2008-11-17T16:25:20.862+05:30</updated><title type='text'></title><content type='html'>&lt;span style="color:#993300;"&gt;ora-01031- insufficent privilege&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;Suppose these error occur means..your ora_dba group not  configured in OS authentication.&lt;br /&gt;&lt;br /&gt;Solve...&lt;br /&gt;&lt;ul&gt;&lt;li&gt;Control Panel -----------&gt; Adminstrative tools -------&gt; Computer management&lt;/li&gt;&lt;li&gt;Click Local groups and then users or groups&lt;/li&gt;&lt;li&gt;on right side administrative is appear.right click on this and click properties.&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;In this case You should find Ora_dba ..its not appear in this. so you go to add the Ora_dba privilege to OS.&lt;/p&gt;&lt;ul&gt;&lt;li&gt;run -------&gt; cmd enter&lt;/li&gt;&lt;li&gt;&gt; net localgroup ora_dba /add enter&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;And then you find the Ora_dba is there and then add ora_dba to your administrator groups.&lt;/p&gt;&lt;ul&gt;&lt;li&gt;&gt;set oracle_sid=oracle&lt;/li&gt;&lt;li&gt;sqlplus&lt;/li&gt;&lt;li&gt;&lt;a href="mailto:sys/sys@localdb"&gt;sys/sys@localdb&lt;/a&gt; as sysdba&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;database connected.........and then you can easily access it.&lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2493681572457119266-526750254363931411?l=azardba.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://azardba.blogspot.com/feeds/526750254363931411/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2493681572457119266&amp;postID=526750254363931411' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/526750254363931411'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/526750254363931411'/><link rel='alternate' type='text/html' href='http://azardba.blogspot.com/2008/11/ora-01031-insufficent-privilege-suppose.html' title=''/><author><name>Azar Mohamed Shaj</name><uri>http://www.blogger.com/profile/04251444414118162294</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://4.bp.blogspot.com/_M42FHtL_R7c/Stmn7gOmPCI/AAAAAAAAAGs/ff_HAJp76GI/S220/untitled.bmp'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2493681572457119266.post-7444761499966207139</id><published>2008-09-29T16:11:00.003+05:30</published><updated>2008-11-18T12:31:11.744+05:30</updated><title type='text'>Ora-12514 TNS: listener does not currently  know of service</title><content type='html'>Due to error occur on Oracle Listner not properly mentioned&lt;br /&gt;&lt;br /&gt;So.., you should check lisntener.ora file and modify&lt;br /&gt;&lt;br /&gt;Example :-&lt;br /&gt;&lt;br /&gt;&lt;span style="color:#009900;"&gt;(SID_DESC = &lt;/span&gt;&lt;br /&gt;&lt;span style="color:#009900;"&gt;(SID_NAME = PLSExtProc) &lt;/span&gt;&lt;br /&gt;&lt;span style="color:#009900;"&gt;(ORACLE_HOME = E:\oracle\product\10.2.0\db_1) &lt;/span&gt;&lt;br /&gt;&lt;span style="color:#009900;"&gt;(PROGRAM = extproc) &lt;/span&gt;&lt;br /&gt;&lt;span style="color:#009900;"&gt;)&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#009900;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#009900;"&gt;&lt; (SID_DESC = &lt;/span&gt;&lt;br /&gt;&lt;span style="color:#009900;"&gt;(SID_NAME = localdb ) &lt;/span&gt;&lt;br /&gt;&lt;span style="color:#009900;"&gt;(ORACLE_HOME = E:\oracle\product\10.2.0\db_1) &lt;/span&gt;&lt;br /&gt;&lt;span style="color:#009900;"&gt;(SID_NAME = localdb) &gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;Note : &lt; ... &gt; here check your service name either there or not?localdb -------- db name&lt;br /&gt;And then go to&lt;br /&gt;lsnrctl &gt;stop&lt;br /&gt;&lt;br /&gt;lsnrctl&gt;start&lt;br /&gt;&lt;br /&gt;Or&lt;br /&gt;&lt;br /&gt;&gt;set oracle_sid=localdb&lt;br /&gt;&gt;sqlplus&lt;br /&gt;username : / as sysdba&lt;br /&gt;&gt;startup&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&amp;amp;  then you connect &lt;a href="mailto:sys/sys@localdb"&gt;sys/sys@localdb&lt;/a&gt; as sysdba&lt;br /&gt;&lt;br /&gt;Your service should be started&lt;br /&gt;------------------------------------------------------------------------------------------&lt;br /&gt;Thanks &amp;amp; Regards&lt;br /&gt;S.Mohamed Azarudeen&lt;br /&gt;&lt;a href="mailto:azarmohds@gmail.com"&gt;azarmohds@gmail.com&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2493681572457119266-7444761499966207139?l=azardba.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://azardba.blogspot.com/feeds/7444761499966207139/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2493681572457119266&amp;postID=7444761499966207139' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/7444761499966207139'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/7444761499966207139'/><link rel='alternate' type='text/html' href='http://azardba.blogspot.com/2008/09/ora-12514-tns-listener-does-not.html' title='Ora-12514 TNS: listener does not currently  know of service'/><author><name>Azar Mohamed Shaj</name><uri>http://www.blogger.com/profile/04251444414118162294</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://4.bp.blogspot.com/_M42FHtL_R7c/Stmn7gOmPCI/AAAAAAAAAGs/ff_HAJp76GI/S220/untitled.bmp'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2493681572457119266.post-8285711129596711349</id><published>2008-09-29T15:49:00.005+05:30</published><updated>2008-09-29T17:19:04.453+05:30</updated><title type='text'>Hit/Miss Ratios</title><content type='html'>&lt;strong&gt;&lt;span style="color:#333333;"&gt;Buffer Hit Ratio :-&lt;/span&gt;&lt;/strong&gt;&lt;br /&gt;&lt;em&gt;&lt;span style="color:#3333ff;"&gt;&lt;/span&gt;&lt;/em&gt;&lt;br /&gt;&lt;span style="color:#333333;"&gt;Buffer hit ratio notes:&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;ul&gt;&lt;li&gt;&lt;span style="color:#333333;"&gt;Consistent Gets - The number of blocks accesses made to the block buffer to retrive data in a consistent mode.&lt;/span&gt;&lt;/li&gt;&lt;li&gt;&lt;span style="color:#333333;"&gt;DB Blk gets - The number of blocks accessed via single block gets.&lt;/span&gt;&lt;/li&gt;&lt;li&gt;&lt;span style="color:#333333;"&gt;Physical Reads - The cumulative number of blocks read from disk.&lt;/span&gt;&lt;/li&gt;&lt;li&gt;&lt;span style="color:#333333;"&gt;Logical reads are the sum of consisent gets and db block gets.&lt;/span&gt;&lt;/li&gt;&lt;li&gt;&lt;span style="color:#333333;"&gt;the db block gets statstic value is incremented when a block is read for update and when segment header blocks are accessed.&lt;/span&gt;&lt;/li&gt;&lt;li&gt;&lt;span style="color:#333333;"&gt;Hit ratio should be &gt; 80% , else increase db_block_buffers in init.ora&lt;/span&gt;&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;&lt;span style="color:#009900;"&gt;sql&gt;select sum(decode(name, 'consistent gets',value,0)) "consistent gets",&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color:#009900;"&gt;sum(decode(name,'db block gets',value,0)) "db block gets",&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color:#009900;"&gt;sum(decode(name,'physical reads',value,0)) " physical reads",&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color:#009900;"&gt;round((sum(decode(name,'consistent gets',value,0)) +&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color:#009900;"&gt;sum(decode(name,'db block gets',value,0)) - sum(decode(name,'physical reads',value,0))) /&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color:#009900;"&gt;(sum(decode(name,'consistent gets',value,0)) + &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color:#009900;"&gt;sum(decode(name,'db block gets',value,0))) * 100,2) "Hit Ratio" from v$sysstat;&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color:#009900;"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color:#333333;"&gt;&lt;strong&gt;Data Dict Hit Ratio :-&lt;/strong&gt;&lt;/span&gt;&lt;/p&gt;&lt;ul&gt;&lt;li&gt;&lt;span style="color:#333333;"&gt;Gets - Total number of requests for information on the data object.&lt;/span&gt;&lt;/li&gt;&lt;li&gt;&lt;span style="color:#333333;"&gt;Cache Misses -- Number of data requests resulting in cache misses.&lt;/span&gt;&lt;/li&gt;&lt;li&gt;&lt;span style="color:#333333;"&gt;Hit ratio should be &gt; 90%,else increse Shared_pool_size in init.ora&lt;/span&gt;&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;&lt;span style="color:#333333;"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color:#009900;"&gt;Sql&gt; Select sum(gets),sum(getmisses), round((1-(sum(getmisses)/sum(gets))) * 100,2) from v$rowcache;&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color:#333333;"&gt;&lt;strong&gt;Library Cache Miss Ratio :-&lt;/strong&gt;&lt;/span&gt;&lt;/p&gt;&lt;ul&gt;&lt;li&gt;&lt;span style="color:#333333;"&gt;Executions - The number of times a pin was requested for objects of this namespace.&lt;/span&gt;&lt;/li&gt;&lt;li&gt;&lt;span style="color:#333333;"&gt;Cache misses - any pin of an object that is not the first pin performed since the object handle was created and which requires loading the object from disk.&lt;/span&gt;&lt;/li&gt;&lt;li&gt;&lt;span style="color:#333333;"&gt;Hit ratio should be &lt;&gt;&lt;/ul&gt;&lt;/span&gt;&lt;p&gt;&lt;span style="color:#333333;"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color:#009900;"&gt;Sql&gt; Select sum(pins) executions,sum(reloads) cache_misses,sum(reloads) / sum(pins) miss_ratio from v$librarycache;&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color:#009900;"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color:#333333;"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color:#009900;"&gt;&lt;/span&gt;&lt;/p&gt;&lt;span style="font-family:verdana;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="color:#3333ff;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#333333;"&gt;&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2493681572457119266-8285711129596711349?l=azardba.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://azardba.blogspot.com/feeds/8285711129596711349/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2493681572457119266&amp;postID=8285711129596711349' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/8285711129596711349'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/8285711129596711349'/><link rel='alternate' type='text/html' href='http://azardba.blogspot.com/2008/09/hitmiss-ratios.html' title='Hit/Miss Ratios'/><author><name>Azar Mohamed Shaj</name><uri>http://www.blogger.com/profile/04251444414118162294</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://4.bp.blogspot.com/_M42FHtL_R7c/Stmn7gOmPCI/AAAAAAAAAGs/ff_HAJp76GI/S220/untitled.bmp'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2493681572457119266.post-4164017997717535317</id><published>2008-09-25T15:18:00.004+05:30</published><updated>2008-09-25T15:58:17.291+05:30</updated><title type='text'>Undo_Retention</title><content type='html'>&lt;a href="http://4.bp.blogspot.com/_M42FHtL_R7c/SNtiOnjI7cI/AAAAAAAAACU/RVO2cdcUU6s/s1600-h/optimal_undo_retention.gif"&gt;&lt;/a&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Rollback Segments are renamed Undo logs.Traditionally transaction undo information stroed in rollback segments until a commit or rollback statment was issued.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Automatic undo management allows the dba to how long undo information should retained after commit.preventing 'snapshot-too old' error on long running queries.&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;This is done by undo_retention parameter.the default is 900 seconds(5minutes).you can set this parameter to gurantte that oracle keeps undo logs for extended period of time.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;rather then having to define rollback segments,you can simply define an undo tablespace and oracle let take the rest and automatic tuning. &lt;strong&gt;Undo_management=AUTO&lt;/strong&gt;&lt;/div&gt;&lt;div&gt;&lt;strong&gt;&lt;/strong&gt;&lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;div&gt;&lt;em&gt;Calculate Undo_Retention&lt;/em&gt;&lt;strong&gt;:-&lt;/strong&gt;&lt;/div&gt;&lt;div&gt;&lt;a href="http://1.bp.blogspot.com/_M42FHtL_R7c/SNtifNCT0xI/AAAAAAAAACc/0-VkOAH6Hqk/s1600-h/optimal_undo_retention.gif"&gt;&lt;/a&gt;&lt;/div&gt;&lt;div&gt;&lt;a href="http://1.bp.blogspot.com/_M42FHtL_R7c/SNtifNCT0xI/AAAAAAAAACc/0-VkOAH6Hqk/s1600-h/optimal_undo_retention.gif"&gt;&lt;img id="BLOGGER_PHOTO_ID_5249898078845260562" style="CURSOR: hand" alt="" src="http://1.bp.blogspot.com/_M42FHtL_R7c/SNtifNCT0xI/AAAAAAAAACc/0-VkOAH6Hqk/s320/optimal_undo_retention.gif" border="0" /&gt;&lt;/a&gt;&lt;/div&gt;&lt;div&gt;&lt;em&gt;&lt;span style="color:#cc0000;"&gt;Actual undo size :-&lt;/span&gt;&lt;/em&gt;&lt;/div&gt;&lt;div&gt;&lt;em&gt;&lt;/em&gt;&lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;div&gt;sql&gt; Select sum(a.bytes) "Undo_Size" from v$datafile a, v$tablespace b,dba_tablespaces c where c.contents='UNDO' and c.status='ONLINE' and b.name=c.tablespace_name and a.ts#=b.ts#;&lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#990000;"&gt;&lt;em&gt;Undo block per second&lt;/em&gt; :-&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;div&gt;sql&gt;select max(undoblks/((end_time-begin_time)*3600*24)) " Undo_block_per_second" from v$undostat;&lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;div&gt;&lt;em&gt;&lt;span style="color:#990000;"&gt;Db_block_size:-&lt;/span&gt;&lt;/em&gt;&lt;/div&gt;&lt;div&gt;&lt;em&gt;&lt;/em&gt;&lt;/div&gt;&lt;div&gt;&lt;em&gt;&lt;/em&gt;&lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;div&gt;sql&gt;select to_number(value) from 'db_block_size' from v$parameter where name='db_block_size';&lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;**** 04/04/2008 Oracle 10g OCA 1z0-042 question&lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;div&gt;&lt;em&gt;Your database is configured for automatic undo management.Undo_retention is set to three hours.You want to fashback a table that was created last year.how far back can the flash back query go?&lt;/em&gt;&lt;/div&gt;&lt;div&gt;&lt;em&gt;&lt;/em&gt;&lt;/div&gt;&lt;div&gt;&lt;em&gt;&lt;/em&gt;&lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;div&gt;a.3 hours&lt;/div&gt;&lt;div&gt;b.6months&lt;/div&gt;&lt;div&gt;c.until last year&lt;br /&gt;d.until last commit&lt;/div&gt;&lt;div&gt;e.until the point when the undo tablespace was refreshed.&lt;/div&gt;&lt;div&gt;f.until the database is shutdown and the memory erased.&lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;div&gt;&lt;strong&gt;Ans : A .3 Hours&lt;/strong&gt;&lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2493681572457119266-4164017997717535317?l=azardba.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://azardba.blogspot.com/feeds/4164017997717535317/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2493681572457119266&amp;postID=4164017997717535317' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/4164017997717535317'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/4164017997717535317'/><link rel='alternate' type='text/html' href='http://azardba.blogspot.com/2008/09/undoretention.html' title='Undo_Retention'/><author><name>Azar Mohamed Shaj</name><uri>http://www.blogger.com/profile/04251444414118162294</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://4.bp.blogspot.com/_M42FHtL_R7c/Stmn7gOmPCI/AAAAAAAAAGs/ff_HAJp76GI/S220/untitled.bmp'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://1.bp.blogspot.com/_M42FHtL_R7c/SNtifNCT0xI/AAAAAAAAACc/0-VkOAH6Hqk/s72-c/optimal_undo_retention.gif' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2493681572457119266.post-7884300932946861694</id><published>2008-07-16T15:12:00.004+05:30</published><updated>2008-07-31T14:55:52.448+05:30</updated><title type='text'>Interview</title><content type='html'>&lt;span style="color:#3333ff;"&gt;How Do you move table from sys tablespace to user tablespace :-&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#3333ff;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#000000;"&gt;sql&gt;alter table tablename move tablespace tablespacename;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="color:#000099;"&gt;Finding out Table and Tablespace Location :-&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#000099;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#000000;"&gt;sql&gt;select owner,table_name,tablespace_name from dba_tables where table_name='tablename';&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="color:#3333ff;"&gt;How many memory layers are in the shared pool?&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#3333ff;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#333333;"&gt;Shared poll consists of two layers. &lt;/span&gt;&lt;br /&gt;&lt;ul&gt;&lt;li&gt;&lt;span style="color:#333333;"&gt;Library Cache ---- parsed sql staments and cursor information its a symmentric check.&lt;/span&gt;&lt;/li&gt;&lt;li&gt;&lt;span style="color:#333333;"&gt;Data Dictionary Cache --- user account,privilege,segments,datafile and extend information stored in the data dictionary cache.&lt;/span&gt;&lt;/li&gt;&lt;/ul&gt;&lt;p&gt; &lt;/p&gt;&lt;span style="color:#000000;"&gt;&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2493681572457119266-7884300932946861694?l=azardba.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://azardba.blogspot.com/feeds/7884300932946861694/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2493681572457119266&amp;postID=7884300932946861694' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/7884300932946861694'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/7884300932946861694'/><link rel='alternate' type='text/html' href='http://azardba.blogspot.com/2008/07/interview.html' title='Interview'/><author><name>Azar Mohamed Shaj</name><uri>http://www.blogger.com/profile/04251444414118162294</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://4.bp.blogspot.com/_M42FHtL_R7c/Stmn7gOmPCI/AAAAAAAAAGs/ff_HAJp76GI/S220/untitled.bmp'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2493681572457119266.post-6425883186688447181</id><published>2008-07-12T15:35:00.000+05:30</published><updated>2008-07-12T16:00:40.065+05:30</updated><title type='text'>User and Privilege and Roles</title><content type='html'>&lt;span style="color:#3333ff;"&gt;Users Privilege :-&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="color:#006600;"&gt;sql&gt;create user azar idenitified by azar;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;or&lt;br /&gt;&lt;br /&gt;&lt;span style="color:#006600;"&gt;sql&gt;create user azar idenitified by azar default tablespace &lt;tbalespacename&gt;temporary tablespace &lt;tempname&gt;quota unlimited on &lt;tablespacename&gt;password expire;&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#006600;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#006600;"&gt;sql&gt;grant create session,create table to azar;&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#006600;"&gt;&lt;/span&gt;&lt;br /&gt;or&lt;br /&gt;&lt;br /&gt;&lt;span style="color:#006600;"&gt;sql&gt;Grant connect,resource to azar;&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#006600;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#006600;"&gt;sql&gt;show user;&lt;/span&gt;&lt;br /&gt;azar&lt;br /&gt;&lt;br /&gt;&lt;span style="color:#006600;"&gt;sql&gt;alter user azar account lock;&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#006600;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#006600;"&gt;sql&gt;alter user azar account unlock;&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#006600;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#3333ff;"&gt;Password Change&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="color:#006600;"&gt;sql&gt;alter user azar identified by &lt;newpassword&gt;;&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#006600;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#006600;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#006600;"&gt;sql&gt;drop user azar cascade;&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#006600;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="color:#3333ff;"&gt;System Privilege&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="color:#006600;"&gt;sql&gt;Grant create any table to azar;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="color:#3333ff;"&gt;Revoke Privilege &lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="color:#006600;"&gt;sql&gt;revoke create any table from azar;&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#006600;"&gt;&lt;/span&gt;&lt;br /&gt;View :- dba_sys_privs&lt;br /&gt;&lt;br /&gt;&lt;span style="color:#006600;"&gt;sql&gt;select * from dba_sys_privs where grantee= 'username';&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="color:#3333ff;"&gt;Object Privilege :&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="color:#006600;"&gt;sql&gt;Grant select,update,insert,delete on &lt;username.tablename&gt;  &lt;username.tablename&gt;&lt;username.tablename&gt;&lt;username.tablename&gt;to azar;&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#006600;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#006600;"&gt;sql&gt;Revoke select,update,insert,delete on &lt;username.tablename&gt; &lt;username.tablename&gt;&lt;username.tablename&gt;&lt;username.tablename&gt;from azar;&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#006600;"&gt;&lt;/span&gt;&lt;br /&gt;View :- dba_tab_privs&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="color:#006600;"&gt;sql&gt;grant dba to azar;&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#006600;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#006600;"&gt;sql&gt;revoke dba from azar;&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#006600;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#006600;"&gt;sql&gt;select * from dba_role_privs where grantee ='dba';&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#006600;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#006600;"&gt;sql&gt;select role from session_roles;&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#006600;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#006600;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#006600;"&gt;&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2493681572457119266-6425883186688447181?l=azardba.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://azardba.blogspot.com/feeds/6425883186688447181/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2493681572457119266&amp;postID=6425883186688447181' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/6425883186688447181'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/6425883186688447181'/><link rel='alternate' type='text/html' href='http://azardba.blogspot.com/2008/07/user-and-privilege-and-roles.html' title='User and Privilege and Roles'/><author><name>Azar Mohamed Shaj</name><uri>http://www.blogger.com/profile/04251444414118162294</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://4.bp.blogspot.com/_M42FHtL_R7c/Stmn7gOmPCI/AAAAAAAAAGs/ff_HAJp76GI/S220/untitled.bmp'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2493681572457119266.post-5285904701385247180</id><published>2008-07-10T15:39:00.000+05:30</published><updated>2008-07-12T12:54:10.828+05:30</updated><title type='text'>Managing Tablespace</title><content type='html'>&lt;span style="color:#3333ff;"&gt;Tablespace :-&lt;br /&gt;&lt;/span&gt;&lt;br /&gt;Logical&lt;br /&gt;&lt;br /&gt;database ---- &gt; tablespace --- &gt; segment ---- &gt; extent ---- &gt; Oracle block&lt;br /&gt;&lt;br /&gt;* An Oracle Database can be logically grouped into smaller logical areas of space Known as Tablespace&lt;br /&gt;&lt;br /&gt;* Tablespace Consists of one or more datafiles.&lt;br /&gt;&lt;br /&gt;* It consists of zero or more segments&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="color:#3333ff;"&gt;Creating Tablespace &lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="color:#006600;"&gt;sql&gt;create tablespace azar datafile  '\oracle\oradata\azar01.dbf' size 20m;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;Check your tablespace view  dba_tablespaces&lt;br /&gt;&lt;br /&gt;&lt;span style="color:#006600;"&gt;sql&gt;select * from dba_tablespaces;&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#006600;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#006600;"&gt;sql&gt;alter tablespace azar read only;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;Your tablespace in read only mode you can drop your tablespace contents.&lt;br /&gt;&lt;br /&gt;&lt;span style="color:#006600;"&gt;sql&gt;select tablespace_name,status from dba_tablespaces;&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#006600;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#006600;"&gt;sql&gt;alter tablespace azar read write;&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#006600;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#006600;"&gt;sql&gt;select tablespace_name,status from dba_tablespaces;&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#006600;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#006600;"&gt;sql&gt;alter tablespace azar offline;&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#006600;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#006600;"&gt;sql&gt;alter tablespace azar online;&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#006600;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#3333ff;"&gt;Increase your size tablespace in three Ways :-&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="color:#006600;"&gt;sql&gt;alter tablespace azar datafile '\oracle\oradata\azar01.dbf' size 20m autoextend on;&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#006600;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#006600;"&gt;sql&gt;alter tablespace azar add datafile '\oracle\oradata\azar02.dbf' size 10m;&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#006600;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#006600;"&gt;sql&gt;alter database datafile '\oracle\oradata\azar01.dbf' resize 30m;&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#006600;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#3333ff;"&gt;View:-&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;dba_data_files&lt;br /&gt;&lt;br /&gt;dba_free_space&lt;br /&gt;&lt;br /&gt;Moving tablespace from one location to another location&lt;br /&gt;&lt;br /&gt;&lt;ul&gt;&lt;li&gt;Offline your tablespace&lt;/li&gt;&lt;li&gt;Cut your datafile and paste datafile in target place&lt;/li&gt;&lt;li&gt;&lt;span style="color:#006600;"&gt;sql&gt;alter tablespace azar rename datafile '\oracle\oradata\azar01.dbf' to 'any path' ;&lt;/span&gt;&lt;/li&gt;&lt;li&gt;Online your tablespace&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;Create temporary tablespace :-&lt;/p&gt;&lt;p&gt;Using for only sort operation&lt;/p&gt;&lt;p&gt;&lt;span style="color:#006600;"&gt;sql&gt; Create temporary tablespace  azardba tempfile '\oracle\oradata\temp02.dbf'  size 2m;&lt;/span&gt;&lt;/p&gt;&lt;p&gt;If you want change your temporary tablespace to default tablespace&lt;/p&gt;&lt;p&gt;&lt;span style="color:#006600;"&gt;sql&gt;alter database default temporay tablespace azardba;&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color:#3333ff;"&gt;View:-&lt;/span&gt;&lt;/p&gt;&lt;p&gt;dba_temp_files&lt;/p&gt;&lt;p&gt;v$tempfile&lt;/p&gt;&lt;p&gt;v$temp_space_header&lt;/p&gt;&lt;p&gt; &lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2493681572457119266-5285904701385247180?l=azardba.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://azardba.blogspot.com/feeds/5285904701385247180/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2493681572457119266&amp;postID=5285904701385247180' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/5285904701385247180'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/5285904701385247180'/><link rel='alternate' type='text/html' href='http://azardba.blogspot.com/2008/07/managing-tablespace.html' title='Managing Tablespace'/><author><name>Azar Mohamed Shaj</name><uri>http://www.blogger.com/profile/04251444414118162294</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://4.bp.blogspot.com/_M42FHtL_R7c/Stmn7gOmPCI/AAAAAAAAAGs/ff_HAJp76GI/S220/untitled.bmp'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2493681572457119266.post-7396279552317195177</id><published>2008-07-07T18:24:00.000+05:30</published><updated>2008-07-10T15:39:30.964+05:30</updated><title type='text'>Redo Log FIle</title><content type='html'>&lt;a href="http://bp3.blogger.com/_M42FHtL_R7c/SHWrTHoYqqI/AAAAAAAAAAw/S_n36ff-NdE/s1600-h/redo.bmp"&gt;&lt;img id="BLOGGER_PHOTO_ID_5221267687960259234" style="FLOAT: left; MARGIN: 0px 10px 10px 0px; CURSOR: hand" alt="" src="http://bp3.blogger.com/_M42FHtL_R7c/SHWrTHoYqqI/AAAAAAAAAAw/S_n36ff-NdE/s320/redo.bmp" border="0" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;div&gt;&lt;span style="color:#3333ff;"&gt;Redo log File :-&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;* Redo log files record all changes made to data and provide a recovery mechanism from a system or media failure.&lt;br /&gt;&lt;br /&gt;* Redo log files are organized into groups&lt;br /&gt;&lt;br /&gt;* An Oracle database requires at least two groups&lt;br /&gt;&lt;br /&gt;* Each redo log within a group is called a member.&lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#3333ff;"&gt;Online Redo log groups :-&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;div&gt;* A set of identical copies of online redo log file is called an Online redo log group.&lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;div&gt;* Log writer writes same information to all online redolog files in a group.&lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;div&gt;* Oracle Server Needs minimum two online redo log group.&lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#3333ff;"&gt;Online Redo log Member :-&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;div&gt;* Each online redol og file in a group called Online redo log member.&lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;div&gt;* Each member in a group has a identical log sequence number and same size.&lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;div&gt;* The log sequence number is assigned each time the oracle server starts writing to a log group to identify each redo log file uniquely.&lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;div&gt;* The current log sequence number is stored in the control file and header of all data files.&lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#3333ff;"&gt;Redo logs Work :-&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;div&gt;* When you redo log file is full, Logwriter will move to the next Log group is called Log switch&lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;div&gt;* Checkpoint occurs&lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;div&gt;* Information written to Control files&lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#3333ff;"&gt;Logwriter Writes Under the Condition&lt;/span&gt; &lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;ul&gt;&lt;li&gt;When a transaction commits&lt;/li&gt;&lt;li&gt;Redolog buffer becomes one-third full&lt;/li&gt;&lt;li&gt;More than a megabytes of changed record in the redo log buffer&lt;/li&gt;&lt;li&gt;Before database writer writer to the datafile.&lt;/li&gt;&lt;/ul&gt;&lt;div&gt;&lt;span style="color:#3333ff;"&gt;Forcing Log switch and Checkpoints :-&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#3333ff;"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#3333ff;"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#000000;"&gt;* Log switches and checkpoints are automatically done at certain operation point of the database.&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#000000;"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#000000;"&gt;but a DBA force to log switch or checkpoint occur.&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;sql&gt; alter system switch logfile;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;sql&gt; alter system checkpoint;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;Archive mode&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;sql&gt; archive log list;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;database log mode noarchive&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;automatic archival disable&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#000000;"&gt;Change your database from noarchive mode to archive mode&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#000000;"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#000000;"&gt;Mount stage&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;sql&gt; shutdown immediate&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;sql&gt; startup mount&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;sql&gt; archive log list;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;sql&gt; alter database archivelog;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;database altered&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;sql&gt; archive log list;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;database log mode archive mode&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;automatice archival disabled&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;sql&gt; archive log start;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;If you want set instance level&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;sql&gt; show parameter log_archive_start&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;value&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;false&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;sql&gt; alter system set log_archive_start=true scope=spfile&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;system altered&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;sql&gt; shutdown immediate&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;sql&gt; startup&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;sql&gt; archive log list;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;Change your archive destination&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;sql&gt; alter system set log_archive_dest = '\oracle\admin\{sid}' scope=spfile&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;shutdown and startup&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;sql&gt; archive log list;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#3333ff;"&gt;Adding Group and Member :-&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;sql&gt;alter database add logfile group 3 &lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;'\oracle\oradata\{sid}\redo03a.log' size 5m;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;sql&gt; alter database drop logfile group 3;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;adding member&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;sql&gt;alter database add logfile member '\oracle\oradata\{sid}\redo03b.dbf to group 3;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;sql&gt;alter database drop logfile member '\oracle\oradata\{sid}\redo03b.log' ;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#3333ff;"&gt;View :-&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;V$log&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;v$logfile&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#3333ff;"&gt;Group and member status :-&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;active - archived ,instance required&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;Inactive -- archived but instance not required&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;curretn -- currently log writer writes data in a the group&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;*********&lt;/span&gt;&lt;span style="color:#000000;"&gt; drop your group only inactive state,you cannot drop current state.&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#000000;"&gt;If you want to drop current state you sholud log switch logfile.&lt;/span&gt;&lt;/div&gt;&lt;div&gt; &lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;sql&gt;select archiver from v$instance;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;started&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#006600;"&gt;&lt;/span&gt; &lt;/div&gt;&lt;div&gt;&lt;span style="color:#000000;"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#009900;"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#3333ff;"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2493681572457119266-7396279552317195177?l=azardba.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://azardba.blogspot.com/feeds/7396279552317195177/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2493681572457119266&amp;postID=7396279552317195177' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/7396279552317195177'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/7396279552317195177'/><link rel='alternate' type='text/html' href='http://azardba.blogspot.com/2008/07/redo-log-file.html' title='Redo Log FIle'/><author><name>Azar Mohamed Shaj</name><uri>http://www.blogger.com/profile/04251444414118162294</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://4.bp.blogspot.com/_M42FHtL_R7c/Stmn7gOmPCI/AAAAAAAAAGs/ff_HAJp76GI/S220/untitled.bmp'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://bp3.blogger.com/_M42FHtL_R7c/SHWrTHoYqqI/AAAAAAAAAAw/S_n36ff-NdE/s72-c/redo.bmp' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2493681572457119266.post-6525202022924629793</id><published>2008-07-07T11:23:00.000+05:30</published><updated>2008-07-07T12:33:50.020+05:30</updated><title type='text'>Control File</title><content type='html'>&lt;span style="color:#3333ff;"&gt;Control File :-&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#3333ff;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#000000;"&gt;* Small Binary file necessry for the database to start and operate successfully.&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;* Each Control file associated with only one database.&lt;br /&gt;&lt;br /&gt;* Before database opened, the control file is read to determine if the database is in a valid state to use.&lt;br /&gt;&lt;br /&gt;* Control file is updated continously by the oracle server.&lt;br /&gt;&lt;br /&gt;* It must be available for writing whenever the database is open.&lt;br /&gt;&lt;br /&gt;* No databse administrator or end user can not edit this file.&lt;br /&gt;&lt;br /&gt;* If all copies of a control file lost, the database must be recovered before database opened.&lt;br /&gt;&lt;br /&gt;* Control file should be multiplexed upto &lt;strong&gt;eight times.&lt;/strong&gt;&lt;br /&gt;&lt;strong&gt;&lt;/strong&gt;&lt;br /&gt;&lt;span style="color:#3333ff;"&gt;Control Files Contents :-&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#3333ff;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;ul&gt;&lt;li&gt;&lt;span style="color:#000000;"&gt;Database name and identifier&lt;/span&gt;&lt;/li&gt;&lt;li&gt;Time stamp of database creation&lt;/li&gt;&lt;li&gt;Tablespaces names&lt;/li&gt;&lt;li&gt;Names and locations of datafiles and redolog files.&lt;/li&gt;&lt;li&gt;Current redo log file sequence number.&lt;/li&gt;&lt;li&gt;Checkpoint information&lt;/li&gt;&lt;li&gt;Begin and end of undo segments&lt;/li&gt;&lt;li&gt;Redo log archive information&lt;/li&gt;&lt;li&gt;Backuop information.&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;&lt;span style="color:#009900;"&gt;sql&gt; show parameter control_files;&lt;/span&gt;&lt;/p&gt;&lt;p&gt;Multiplex control files using pfile&lt;/p&gt;&lt;p&gt;(alreay have two control files and then)&lt;/p&gt;&lt;p&gt;&lt;span style="color:#006600;"&gt;sql&gt; Alter system set control_files= '\oracle\oradata\{sid}\control01.ctl',&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color:#006600;"&gt;'\oracle\oradata\{sid}\control02.ctl','\oracle\oradata\{sid}\control03.ctl' scope = spfile ;&lt;/span&gt;&lt;/p&gt;&lt;p&gt;system altered.&lt;/p&gt;&lt;p&gt;&lt;span style="color:#006600;"&gt;sql&gt; show parameter control_files;&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;/p&gt;&lt;p&gt;***** Now not effet right now and so you shutdown the database and startup manually and copy the controlfile os level and paste it and rename it.&lt;/p&gt;&lt;p&gt;(control01.ctl (copy) and paste it same location (copy of control01.ctl ) and then rename it (control03.ctl))&lt;/p&gt;&lt;p&gt;&lt;span style="color:#006600;"&gt;sql&gt;shutdown immediate&lt;/span&gt;&lt;/p&gt;&lt;p&gt;copy and paste and rename it&lt;/p&gt;&lt;p&gt;&lt;span style="color:#006600;"&gt;sql&gt; startup &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color:#006600;"&gt;Sql&gt; show parameter control_files;&lt;/span&gt;&lt;/p&gt;&lt;p&gt;Backup the control file :-&lt;/p&gt;&lt;p&gt;&lt;span style="color:#006600;"&gt;sql&gt; Alter database backup controlfile to 'filename';&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color:#006600;"&gt;sql&gt;alter database backup controlfile to trace;&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color:#3333ff;"&gt;View :-&lt;/span&gt;&lt;/p&gt;&lt;ul&gt;&lt;li&gt;&lt;span style="color:#006600;"&gt;v$controlfile&lt;/span&gt;&lt;/li&gt;&lt;li&gt;&lt;span style="color:#006600;"&gt;v$parameter&lt;/span&gt;&lt;/li&gt;&lt;li&gt;&lt;span style="color:#006600;"&gt;v$controlfile_record_section&lt;/span&gt;&lt;/li&gt;&lt;li&gt;&lt;span style="color:#006600;"&gt;show parameter control_files&lt;/span&gt;&lt;/li&gt;&lt;li&gt;&lt;span style="color:#006600;"&gt;v$backup&lt;/span&gt;&lt;/li&gt;&lt;li&gt;&lt;span style="color:#006600;"&gt;v$datafile&lt;/span&gt;&lt;/li&gt;&lt;li&gt;&lt;span style="color:#006600;"&gt;v$tempfile&lt;/span&gt;&lt;/li&gt;&lt;li&gt;&lt;span style="color:#006600;"&gt;v$tablespace&lt;/span&gt;&lt;/li&gt;&lt;li&gt;&lt;span style="color:#006600;"&gt;v$archive&lt;/span&gt;&lt;/li&gt;&lt;li&gt;&lt;span style="color:#006600;"&gt;v$log&lt;/span&gt;&lt;/li&gt;&lt;li&gt;&lt;span style="color:#006600;"&gt;v$logfile&lt;/span&gt;&lt;/li&gt;&lt;li&gt;&lt;span style="color:#006600;"&gt;v$loghist&lt;/span&gt;&lt;/li&gt;&lt;li&gt;&lt;span style="color:#006600;"&gt;v$archived_log&lt;/span&gt;&lt;/li&gt;&lt;li&gt;&lt;span style="color:#006600;"&gt;v$database&lt;/span&gt;&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;&lt;/p&gt;&lt;p&gt;&lt;/p&gt;&lt;strong&gt;&lt;/strong&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2493681572457119266-6525202022924629793?l=azardba.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://azardba.blogspot.com/feeds/6525202022924629793/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2493681572457119266&amp;postID=6525202022924629793' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/6525202022924629793'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/6525202022924629793'/><link rel='alternate' type='text/html' href='http://azardba.blogspot.com/2008/07/control-file.html' title='Control File'/><author><name>Azar Mohamed Shaj</name><uri>http://www.blogger.com/profile/04251444414118162294</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://4.bp.blogspot.com/_M42FHtL_R7c/Stmn7gOmPCI/AAAAAAAAAGs/ff_HAJp76GI/S220/untitled.bmp'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2493681572457119266.post-7653365449908457352</id><published>2008-07-03T16:42:00.000+05:30</published><updated>2008-07-03T17:08:01.666+05:30</updated><title type='text'>Data Dictionary</title><content type='html'>Data Dictionary :-&lt;br /&gt;&lt;br /&gt;* During Database creation, The oracle server crerates additional object structures within datafiles.&lt;br /&gt;&lt;br /&gt;&lt;ul&gt;&lt;li&gt;Data Dictionary Tables&lt;/li&gt;&lt;li&gt;Dynamic Performance Tables&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;Data Dictionary :-&lt;/p&gt;&lt;p&gt;* Set of read only tables and views that record,verify and provide information associated with database.&lt;/p&gt;&lt;p&gt;*Describe databases and its objects&lt;/p&gt;&lt;p&gt;Two types of objects&lt;/p&gt;&lt;ul&gt;&lt;li&gt;Base Tables&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;--- Store description of database&lt;/p&gt;&lt;p&gt;--- Created with create database&lt;/p&gt;&lt;ul&gt;&lt;li&gt;Data Dictionary Views&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;--- Summarize base table information&lt;/p&gt;&lt;p&gt;--- Created using catalog.sql script&lt;/p&gt;&lt;p&gt;Base Tables :-&lt;/p&gt;&lt;p&gt;* Base tables are the first objects created in any oracle database.&lt;/p&gt;&lt;p&gt;* They are automatically created when the Oracle server runs the sql.bsq script at the time database is created.&lt;/p&gt;&lt;p&gt;* Users rarely access them directly. because it stored in a cryptic format.&lt;/p&gt;&lt;p&gt;* Example -- IND$ table which contains information about the index in the database.&lt;/p&gt;&lt;p&gt;&lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2493681572457119266-7653365449908457352?l=azardba.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://azardba.blogspot.com/feeds/7653365449908457352/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2493681572457119266&amp;postID=7653365449908457352' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/7653365449908457352'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/7653365449908457352'/><link rel='alternate' type='text/html' href='http://azardba.blogspot.com/2008/07/data-dictionary.html' title='Data Dictionary'/><author><name>Azar Mohamed Shaj</name><uri>http://www.blogger.com/profile/04251444414118162294</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://4.bp.blogspot.com/_M42FHtL_R7c/Stmn7gOmPCI/AAAAAAAAAGs/ff_HAJp76GI/S220/untitled.bmp'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2493681572457119266.post-6630377792198223431</id><published>2008-07-03T15:29:00.001+05:30</published><updated>2008-07-03T16:16:09.273+05:30</updated><title type='text'>Create Database</title><content type='html'>How to Create Database :-&lt;br /&gt;&lt;br /&gt;When you install oracle ,database automatically created. If you want create manually doing following steps...( Windows )&lt;br /&gt;&lt;br /&gt;&lt;ul&gt;&lt;li&gt;SID ---&gt; Any name that is your database name&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;&lt;span style="color:#3333ff;"&gt;Step 1 :&lt;/span&gt;&lt;/p&gt;&lt;ul&gt;&lt;li&gt;Copy the default parameter file and prepare it ( \Oracle\ora90\database)&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;&lt;span style="color:#3333ff;"&gt;Step 2 :&lt;/span&gt;&lt;/p&gt;&lt;ul&gt;&lt;li&gt;You should change sid name as like your database name (put in pfile folder in \oracle\admin\{sid}\pfile)&lt;/li&gt;&lt;li&gt;Put it five folder in \oracle\admin\{sid}\(put it and rename like create,pfile,udump,bdump,cdump)&lt;/li&gt;&lt;li&gt;Save the parameter file&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;&lt;span style="color:#3333ff;"&gt;Step 3 : &lt;/span&gt;&lt;/p&gt;&lt;p&gt;* create password file &lt;/p&gt;&lt;p&gt;type on cmd platform&lt;/p&gt;&lt;p&gt;&lt;span style="color:#cc33cc;"&gt;Run ---&gt; cmd Enter&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color:#cc33cc;"&gt;cmd&gt;orapwd file= \oracle\ora90\database\pwd{sid}.ora pwd=sys (as your choice)&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color:#3333ff;"&gt;Step 4:&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color:#000000;"&gt;* In windows create services for instance&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color:#993399;"&gt;cmd&gt;oradim -new -sid {sid}&lt;/span&gt;&lt;/p&gt;&lt;p&gt;* Set Oracle Sid&lt;/p&gt;&lt;p&gt;&lt;span style="color:#993399;"&gt;cmd&gt;set oracle_sid={sid}&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color:#3333ff;"&gt;Step 5:&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color:#993399;"&gt;cmd&gt;sqlplus&lt;/span&gt;&lt;/p&gt;&lt;p&gt;Enter username : sys/sys as sysdba&lt;/p&gt;&lt;p&gt;Connected to an idle instance&lt;/p&gt;&lt;p&gt;&lt;span style="color:#009900;"&gt;sql&gt;Startup nomount&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color:#009900;"&gt;sql&gt;create database {sid}&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color:#009900;"&gt;Logfile&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color:#009900;"&gt;group 1 ('\oracle\oradata\{sid}\redo01.log') size 100m,&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color:#009900;"&gt;group 2 ('\oracle\oradata\{sid}\redo02.log') size 100m&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color:#009900;"&gt;datafile '\oracle\oradata\{sid}\system01.dbf' size 20m autoextend on&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color:#009900;"&gt;undo tablespace undotbs&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color:#009900;"&gt;datafile '\oracle\oradata\{sid}\undotbs01.dbf' size 20m&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color:#009900;"&gt;default temporary tablespace tempts1&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color:#009900;"&gt;tempfile '\oracle\oradata\{sid}\tempts01.dbf' &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color:#009900;"&gt;size 20m&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color:#009900;"&gt;/&lt;/span&gt;&lt;/p&gt;&lt;p&gt;Database created&lt;/p&gt;&lt;p&gt;&lt;span style="color:#009900;"&gt;sql&gt;@c:\oracle\ora90\rdbms\admin\catalog.sql&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color:#009900;"&gt;sql&gt;@c:\oracle\ora90\rdbms\admin\catproc.sql&lt;/span&gt;&lt;/p&gt;&lt;p&gt;**** &lt;/p&gt;&lt;p&gt;&lt;a href="http://www.adp-gmbh.ch/ora/admin/creatingdbmanually.html"&gt;http://www.adp-gmbh.ch/ora/admin/creatingdbmanually.html&lt;/a&gt;&lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2493681572457119266-6630377792198223431?l=azardba.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://azardba.blogspot.com/feeds/6630377792198223431/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2493681572457119266&amp;postID=6630377792198223431' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/6630377792198223431'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/6630377792198223431'/><link rel='alternate' type='text/html' href='http://azardba.blogspot.com/2008/07/create-database.html' title='Create Database'/><author><name>Azar Mohamed Shaj</name><uri>http://www.blogger.com/profile/04251444414118162294</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://4.bp.blogspot.com/_M42FHtL_R7c/Stmn7gOmPCI/AAAAAAAAAGs/ff_HAJp76GI/S220/untitled.bmp'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2493681572457119266.post-2432815204082063557</id><published>2008-07-03T15:00:00.000+05:30</published><updated>2008-07-03T15:21:24.513+05:30</updated><title type='text'>Shutdown Database</title><content type='html'>&lt;span style="color:#3333ff;"&gt;Shutdown Mode :-&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#3333ff;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;ul&gt;&lt;li&gt;Shutdown immediate&lt;/li&gt;&lt;li&gt;Shutdown Abort&lt;/li&gt;&lt;li&gt;Shutdown Transactional&lt;/li&gt;&lt;li&gt;Shutdown Normal&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;&lt;span style="color:#009900;"&gt;Sql&gt; Shutdown [immediate  Normal  Abort  Transactional ]&lt;/span&gt;&lt;/p&gt;&lt;ul&gt;&lt;li&gt;Database buffer cache written to the data files.&lt;/li&gt;&lt;li&gt;Uncommitted Changes Roll Back&lt;/li&gt;&lt;li&gt;Resources released&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;&lt;span style="color:#3333ff;"&gt;Shutdown Normal :-&lt;/span&gt;&lt;/p&gt;&lt;ul&gt;&lt;li&gt;No New Connections can be made.&lt;/li&gt;&lt;li&gt;The oracle server waits for all users to disconnect before completing shutdown&lt;/li&gt;&lt;li&gt;Database and redo buffers are written to disk&lt;/li&gt;&lt;li&gt;Bg processes are terminated. and the sga is removed from the meory.&lt;/li&gt;&lt;li&gt;Oracle closes and dismounts the database before shutting down the instance&lt;/li&gt;&lt;li&gt;The next startup does not require an instance recovery.&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;&lt;span style="color:#3333ff;"&gt;Shutdown Transactional :-&lt;/span&gt;&lt;/p&gt;&lt;p&gt;* Transactional shutdown prevents client from losing work.&lt;/p&gt;&lt;ul&gt;&lt;li&gt;No client can start a new transaction on this particular instance.&lt;/li&gt;&lt;li&gt;A client is disconnected when the client ends the transaction&lt;/li&gt;&lt;li&gt;When all transactions have finished ,a shutdown immediately occurs&lt;/li&gt;&lt;li&gt;The next startup does not require an instance recovery.&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;&lt;span style="color:#3333ff;"&gt;Shutdown immediate:-&lt;/span&gt;&lt;/p&gt;&lt;ul&gt;&lt;li&gt;Current sql statments being processed by oracle are not completed.&lt;/li&gt;&lt;li&gt;Oracle server does not wait for users currently connected to the database to disconnect.&lt;/li&gt;&lt;li&gt;Oracle rolls back active transactions.&lt;/li&gt;&lt;li&gt;Oracle closes and dismounts the database before shutting the instance.&lt;/li&gt;&lt;li&gt;The next startup does not require intance recovery.&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;&lt;span style="color:#3333ff;"&gt;Shutdown abort :-&lt;/span&gt;&lt;/p&gt;&lt;ul&gt;&lt;li&gt;sql statments by the oracle server immediately terminated.&lt;/li&gt;&lt;li&gt;oralce does not wait for users currently connected to the database  to disconnect.&lt;/li&gt;&lt;li&gt;database and redo buffers are not written to disk.&lt;/li&gt;&lt;li&gt;Uncommited transactions are not rolled back.&lt;/li&gt;&lt;li&gt;the instance is terminated without closing the files.&lt;/li&gt;&lt;li&gt;database not closed or dismounted.&lt;/li&gt;&lt;li&gt;Next startup needs instance recovery. which occurs automatically.&lt;/li&gt;&lt;/ul&gt;&lt;p&gt; &lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2493681572457119266-2432815204082063557?l=azardba.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://azardba.blogspot.com/feeds/2432815204082063557/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2493681572457119266&amp;postID=2432815204082063557' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/2432815204082063557'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/2432815204082063557'/><link rel='alternate' type='text/html' href='http://azardba.blogspot.com/2008/07/shutdown-database.html' title='Shutdown Database'/><author><name>Azar Mohamed Shaj</name><uri>http://www.blogger.com/profile/04251444414118162294</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://4.bp.blogspot.com/_M42FHtL_R7c/Stmn7gOmPCI/AAAAAAAAAGs/ff_HAJp76GI/S220/untitled.bmp'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2493681572457119266.post-1726461069952596407</id><published>2008-07-02T17:38:00.000+05:30</published><updated>2008-07-03T14:18:01.344+05:30</updated><title type='text'>Startup</title><content type='html'>&lt;span style="color:#000099;"&gt;Starting up a database (Nomount) :-&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#000099;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#000000;"&gt;* When starting the database, you select the states in which it starts.&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;ul&gt;&lt;li&gt;Usually start an instance without mounting a database only during database creation or the recreation of control-files.&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;&lt;span style="color:#009900;"&gt;sql&gt;Startup nomount&lt;/span&gt;&lt;/p&gt;&lt;p&gt;*Starting an instance include following tasks,&lt;/p&gt;&lt;ul&gt;&lt;li&gt;Reading the initializtion files&lt;/li&gt;&lt;li&gt;Allocating the SGA&lt;/li&gt;&lt;li&gt;Starting the background processes&lt;/li&gt;&lt;li&gt;Opening the alertSID.log file and the trace files.&lt;/li&gt;&lt;li&gt;The database must be named with the db_name parameter.&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;&lt;span style="color:#3333ff;"&gt;Starting up a database (Mount) :-&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color:#000000;"&gt;* The database must be mounted but not open during the following tasks,&lt;/span&gt;&lt;/p&gt;&lt;ul&gt;&lt;li&gt;Renaming datafiles&lt;/li&gt;&lt;li&gt;Enabling and disabling redo log archive options&lt;/li&gt;&lt;li&gt;Performing full database recovery&lt;/li&gt;&lt;li&gt;Locating and opening the control file specified initializtion parameters file.&lt;/li&gt;&lt;li&gt;Reading the control files to obtain the name and status of the redo log files and datafiles.&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;&lt;span style="color:#3333ff;"&gt;Starting up a database (Open) :-&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color:#000000;"&gt;* An instance started and database mounted and then datbase opened. During database open ,the user can be attempt to open database and performing.&lt;/span&gt;&lt;/p&gt;&lt;p&gt;*During the database open following tasks,&lt;/p&gt;&lt;ul&gt;&lt;li&gt;Datafiles and ONline redolog files are Available&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;Note :- When you open the database, a datafiles and online redo log file not avilable ,the oracle returns error. Mean time database needs recovery options.&lt;/p&gt;&lt;p&gt;*** If necessary,System Monitor background process (SMON) initiates instance recovery.&lt;/p&gt;&lt;p&gt;&lt;span style="color:#3333ff;"&gt;Startup Command :-&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color:#000000;"&gt;To startup an instance, use the following commands&lt;/span&gt;&lt;/p&gt;&lt;ul&gt;&lt;li&gt;&lt;span style="color:#009900;"&gt;Startup [force] [restrict] [pfile=filename] [open [recover] [database] Mount Nomount ]&lt;/span&gt;&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;Note :- This is not the Complex syntax.&lt;/p&gt;&lt;ul&gt;&lt;li&gt;Force ---&gt; aborting the running instance before performing a startup&lt;/li&gt;&lt;li&gt;Restrict ---&gt; Enables only users with restricted session privilege to access the database&lt;/li&gt;&lt;li&gt;Recover ---&gt; can be media recovery when the database starts&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;**** Attempting to open Oracle utilities without start the service, Oracle returns a error &lt;span style="color:#009900;"&gt;Ora-12547 --TNS&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color:#3333ff;"&gt;The Alter Database Command :-&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color:#000000;"&gt;* Chang the states of the database from Nomount ot Mount stage,&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color:#009900;"&gt;sql&gt; alter database db01 mount;&lt;/span&gt;&lt;/p&gt;&lt;p&gt;* Open the database read only mode&lt;/p&gt;&lt;p&gt;&lt;span style="color:#009900;"&gt;sql&gt; alter database db01 open read only;&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color:#009900;"&gt;Alter database db01 open [read only read write]&lt;/span&gt;&lt;/p&gt;&lt;p&gt;where &lt;/p&gt;&lt;ul&gt;&lt;li&gt;Read Write ---&gt; Opens the database read write mode so users can generate redo logs.&lt;/li&gt;&lt;li&gt;Read Only ----&gt; Restrict users to read only transactions,preventing them from generating Redo log information.&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;&lt;span style="color:#3333ff;"&gt;Restrict Command :-&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color:#009900;"&gt;sql&gt;startup restrict;&lt;/span&gt;&lt;/p&gt;&lt;p&gt;* Use the Alter system command in restriction mode,&lt;/p&gt;&lt;p&gt;&lt;span style="color:#009900;"&gt;sql&gt; alter system enable restricted session;&lt;/span&gt;&lt;/p&gt;&lt;p&gt;**** When you perform struture maintanice or database export or import. The database can be restricted session so that it is available only to the restricted session privilige users.&lt;/p&gt;&lt;p&gt;&lt;span style="color:#009900;"&gt;Alter system [enable disable ] restricted session;&lt;/span&gt;&lt;/p&gt;&lt;ul&gt;&lt;li&gt;Enable ---&gt; who have restircted privilige users&lt;/li&gt;&lt;li&gt;Disable ----&gt; users who do not have the priviliges also log on.&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;&lt;span style="color:#3333ff;"&gt;Terminate Session :-&lt;/span&gt;&lt;/p&gt;&lt;p&gt;* After placing an instance in resticted mode, you may want to kill all current user sessions before performing administrative tasks.&lt;/p&gt;&lt;ul&gt;&lt;li&gt;&lt;span style="color:#009900;"&gt;Alter system kill session 'integer1,integer 2'&lt;/span&gt;&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;Where &lt;/p&gt;&lt;ul&gt;&lt;li&gt;Integer 1 ----&gt; Value of the column in the &lt;span style="color:#009900;"&gt;v$session&lt;/span&gt; view&lt;/li&gt;&lt;li&gt;Integer 2 ----&gt; value of the serail# in the &lt;span style="color:#009900;"&gt;v$session&lt;/span&gt; view&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;***** &lt;a href="http://www.oracle-base.com/articles/misc/KillingOracleSessions.php"&gt;http://www.oracle-base.com/articles/misc/KillingOracleSessions.php&lt;/a&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color:#3333ff;"&gt;Efects of Terminating a Session :-&lt;/span&gt;&lt;/p&gt;&lt;p&gt;* Pmon perform following tasks,&lt;/p&gt;&lt;ul&gt;&lt;li&gt;Roll back the users current transaction&lt;/li&gt;&lt;li&gt;Release all currently held table or rows&lt;/li&gt;&lt;li&gt;Free all resources currently reserved by the user&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;&lt;span style="color:#3333ff;"&gt;Opening database in Read Only Mode :-&lt;/span&gt;&lt;/p&gt;&lt;ul&gt;&lt;li&gt;Executes query&lt;/li&gt;&lt;li&gt;Execute disk sort using locally managed tablespace&lt;/li&gt;&lt;li&gt;Take datafiles offline and Online ,.Not tablespace&lt;/li&gt;&lt;li&gt;Perform recovery offlines of datafile and tablespace.&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;&lt;/p&gt;&lt;p&gt;&lt;/p&gt;&lt;p&gt;&lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2493681572457119266-1726461069952596407?l=azardba.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://azardba.blogspot.com/feeds/1726461069952596407/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2493681572457119266&amp;postID=1726461069952596407' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/1726461069952596407'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/1726461069952596407'/><link rel='alternate' type='text/html' href='http://azardba.blogspot.com/2008/07/startup.html' title='Startup'/><author><name>Azar Mohamed Shaj</name><uri>http://www.blogger.com/profile/04251444414118162294</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://4.bp.blogspot.com/_M42FHtL_R7c/Stmn7gOmPCI/AAAAAAAAAGs/ff_HAJp76GI/S220/untitled.bmp'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2493681572457119266.post-4315652775625380470</id><published>2008-07-02T16:36:00.000+05:30</published><updated>2008-07-02T17:36:47.699+05:30</updated><title type='text'>Managing an Oracle Instance</title><content type='html'>&lt;span style="color:#3333ff;"&gt;Initialization Parameter Files :-&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#3333ff;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#33cc00;"&gt;sql&gt;Connect / as sysdba&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#33cc00;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#33cc00;"&gt;sql&gt;startup&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#000000;"&gt;&lt;/span&gt;&lt;br /&gt;* To start an instance, the Oracle server must read on the Initializtion parameter Files.&lt;br /&gt;&lt;br /&gt;* Changes to entries in the file take effect based on the type of initialization parameter file used.&lt;br /&gt;&lt;br /&gt;&lt;ul&gt;&lt;li&gt;Static Parameter file , PFILE ----&gt; commonly refered as initSID.ora&lt;/li&gt;&lt;li&gt;Persistent Parameter file , SPFILE ----&gt; Commonly refered as spfileSID.ora&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;&lt;span style="color:#3366ff;"&gt;Parameter File Contents,&lt;/span&gt;&lt;/p&gt;&lt;ul&gt;&lt;li&gt;A list of instance parameters.&lt;/li&gt;&lt;li&gt;The name of the database instance assoiciated with&lt;/li&gt;&lt;li&gt;Allocations for memory strutures of the System global area&lt;/li&gt;&lt;li&gt;what to do with filled Online redo log files&lt;/li&gt;&lt;li&gt;The names and locations of control files&lt;/li&gt;&lt;li&gt;Information on undo segments.&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;&lt;span style="color:#3366ff;"&gt;PFILE :-&lt;/span&gt;&lt;/p&gt;&lt;ul&gt;&lt;li&gt;&lt;span style="color:#000000;"&gt;The pfile is a text file .it maintained by standard operating system editor.&lt;/span&gt;&lt;/li&gt;&lt;li&gt;Paramerter file is read only during instance startup.&lt;/li&gt;&lt;li&gt;If the file is modified,the instance must be shutdown and restarted in order to make the new parameter effective.&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;&lt;span style="color:#3333ff;"&gt;SPFILE :-&lt;/span&gt;&lt;/p&gt;&lt;ul&gt;&lt;li&gt;&lt;span style="color:#000000;"&gt;Binary file&lt;/span&gt;&lt;/li&gt;&lt;li&gt;Maintained by oracle server&lt;/li&gt;&lt;li&gt;Alter system command using to changes made&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;&lt;span style="color:#009900;"&gt;sql&gt; alter system set uno_tablespace='undo2';&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color:#009900;"&gt;sql&gt; alter system set parameter = value [scope =memory spfile both]&lt;/span&gt;&lt;/p&gt;&lt;ul&gt;&lt;li&gt;&lt;span style="color:#000000;"&gt;Memory ---&gt; Changes the parameter values only in the currently running file.&lt;/span&gt;&lt;/li&gt;&lt;li&gt;Spfile ----&gt; changes the parameter values only in the spfile.&lt;/li&gt;&lt;li&gt;Both -----&gt; Currently running the instnace and spfile.&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;Creating a spfile,&lt;/p&gt;&lt;p&gt;&lt;span style="color:#009900;"&gt;sql&gt;create spfile from pfile;&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;/p&gt;&lt;p&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color:#000000;"&gt;&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2493681572457119266-4315652775625380470?l=azardba.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://azardba.blogspot.com/feeds/4315652775625380470/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2493681572457119266&amp;postID=4315652775625380470' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/4315652775625380470'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/4315652775625380470'/><link rel='alternate' type='text/html' href='http://azardba.blogspot.com/2008/07/managing-oracle-instance.html' title='Managing an Oracle Instance'/><author><name>Azar Mohamed Shaj</name><uri>http://www.blogger.com/profile/04251444414118162294</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://4.bp.blogspot.com/_M42FHtL_R7c/Stmn7gOmPCI/AAAAAAAAAGs/ff_HAJp76GI/S220/untitled.bmp'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2493681572457119266.post-6576563488562341616</id><published>2008-07-02T15:12:00.000+05:30</published><updated>2008-07-02T15:54:42.595+05:30</updated><title type='text'>Background Process</title><content type='html'>&lt;span style="color:#3333ff;"&gt;Background Processes :-&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#3333ff;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#000000;"&gt;* The relationship between physical (database) and memory sturture maintain  and enforced by the Oracle's Background processes.&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;* Mandatory backgroun processes,&lt;br /&gt;&lt;ul&gt;&lt;li&gt;DBWR -- Database Writer&lt;/li&gt;&lt;li&gt;LGWR -- Log writer&lt;/li&gt;&lt;li&gt;PMON -- Process Monitor&lt;/li&gt;&lt;li&gt;SMON -- System Monitor&lt;/li&gt;&lt;li&gt;CKPT --  Checkpoint&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;&lt;span style="color:#3366ff;"&gt;Database Writer :- &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color:#000000;"&gt;* Database Writer writes when,&lt;/span&gt;&lt;/p&gt;&lt;ul&gt;&lt;li&gt;Checkpoint Occur&lt;/li&gt;&lt;li&gt;Dirty buffer thershold reached&lt;/li&gt;&lt;li&gt;No free Buffers&lt;/li&gt;&lt;li&gt;Timeout&lt;/li&gt;&lt;li&gt;RAC ping request&lt;/li&gt;&lt;li&gt;Tablespace offline&lt;/li&gt;&lt;li&gt;Tablespace read only&lt;/li&gt;&lt;li&gt;Table DROP or Truncate&lt;/li&gt;&lt;li&gt;Tablespace BEGIN BACKUP&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;*db writer writes dirty buffer from the database buffer cache to the datafiles.&lt;/p&gt;&lt;p&gt;&lt;span style="color:#3366ff;"&gt;What is Dirty Buffer?&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color:#000000;"&gt;* A buffer that is currently not in use, and contains data that has been committed but not written back to the disk by the buffer writer process is called a dirty buffer.&lt;/span&gt;&lt;/p&gt;&lt;p&gt;* If a user process finds a dirty buffer in the least recently used (LRU) list, it moves the dirty buffer to the write list and continues searching for more dirty buffers.&lt;/p&gt;&lt;p&gt;&lt;span style="color:#3366ff;"&gt;Log Writer :-&lt;/span&gt;&lt;/p&gt;&lt;ul&gt;&lt;li&gt;&lt;span style="color:#000000;"&gt;At commit&lt;/span&gt;&lt;/li&gt;&lt;li&gt;When one-third full&lt;/li&gt;&lt;li&gt;When there is 1MB of redo&lt;/li&gt;&lt;li&gt;Every 3 seconds&lt;/li&gt;&lt;li&gt;Befor DBWN writes&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;&lt;span style="color:#3366ff;"&gt;System Monitor :-&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color:#000000;"&gt;* Instance recovery&lt;/span&gt;&lt;/p&gt;&lt;ul&gt;&lt;li&gt;Rolls forward changes in the redo logs.&lt;/li&gt;&lt;li&gt;Opens the database for user access&lt;/li&gt;&lt;li&gt;Roll back uncommitted transactions.&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;* Coalesces free space ever 3 sec&lt;/p&gt;&lt;p&gt;* Deallocates temporary segments.&lt;/p&gt;&lt;p&gt;&lt;span style="color:#3333ff;"&gt;Process Monitor :-&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color:#000000;"&gt;* Cleans up after failed processes by&lt;/span&gt;&lt;/p&gt;&lt;ul&gt;&lt;li&gt;Rolling back the transaction&lt;/li&gt;&lt;li&gt;Releasing locks&lt;/li&gt;&lt;li&gt;Releasing Other Resources&lt;/li&gt;&lt;li&gt;Restarts dead dispatchers&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;&lt;span style="color:#3333ff;"&gt;What is Checkpoint?&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color:#000000;"&gt;* A checkpoint occurs when the db writer process writes all modified buffers in the sga buffer cache to the database datafiles. &lt;/span&gt;&lt;/p&gt;&lt;p&gt;* Data file headers are also updated with the latest checkpoint SCN, even if the file had no changed blocks.&lt;/p&gt;&lt;p&gt;* Checkpoints occur AFTER (not during) every redo log switch.&lt;/p&gt;&lt;p&gt;* set parameter &lt;span style="color:#009900;"&gt;log_checkpoints_to_alert=true&lt;/span&gt; to observe checkpoint start and end times in the database alert log.&lt;/p&gt;&lt;p&gt;* Checkpoints can be forced with the &lt;span style="color:#009900;"&gt;Alter system checkpoint&lt;/span&gt; command.&lt;/p&gt;&lt;p&gt;&lt;span style="color:#3333ff;"&gt;What is SCN?&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color:#000000;"&gt;* System Change Number ---&gt; A number,internal to Oracle that is incremented Over time as change vectors are generated,applied and written to the redo log.&lt;/span&gt;&lt;/p&gt;&lt;p&gt;* System commit Number ---&gt; A number,internal to oracle that is incremented with each database commit.&lt;/p&gt;&lt;p&gt; &lt;/p&gt;&lt;p&gt; &lt;/p&gt;&lt;p&gt;&lt;span style="color:#000000;"&gt;&lt;/span&gt; &lt;/p&gt;&lt;p&gt;&lt;span style="color:#000000;"&gt;&lt;/span&gt; &lt;/p&gt;&lt;p&gt; &lt;/p&gt;&lt;p&gt; &lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2493681572457119266-6576563488562341616?l=azardba.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://azardba.blogspot.com/feeds/6576563488562341616/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2493681572457119266&amp;postID=6576563488562341616' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/6576563488562341616'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/6576563488562341616'/><link rel='alternate' type='text/html' href='http://azardba.blogspot.com/2008/07/background-process.html' title='Background Process'/><author><name>Azar Mohamed Shaj</name><uri>http://www.blogger.com/profile/04251444414118162294</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://4.bp.blogspot.com/_M42FHtL_R7c/Stmn7gOmPCI/AAAAAAAAAGs/ff_HAJp76GI/S220/untitled.bmp'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2493681572457119266.post-4531661740082177295</id><published>2008-07-02T10:57:00.000+05:30</published><updated>2008-07-02T15:10:45.409+05:30</updated><title type='text'>Memory Struture</title><content type='html'>&lt;div align="left"&gt;&lt;span style="color:#ff0000;"&gt;Memory Struture:-&lt;/span&gt;&lt;br /&gt;* SGA (system global area) --- Allocated When instance started.&lt;br /&gt;* PGA (program global Area) --- Allocated when server process Started.&lt;/div&gt;&lt;p&gt;&lt;span style="color:#3366ff;"&gt;Sytem Global Area ( Shared Global Area):-&lt;/span&gt;&lt;/p&gt;&lt;ul&gt;&lt;li&gt;&lt;span style="color:#000000;"&gt;Shared Pool ( Library Cache and Data Dictionary Cache)&lt;/span&gt;&lt;/li&gt;&lt;li&gt;Database buffer Cache&lt;/li&gt;&lt;li&gt;Redo log buffer cache&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;two optionally memory struture &lt;/p&gt;&lt;ul&gt;&lt;li&gt;Java Pool&lt;/li&gt;&lt;li&gt;Large Pool&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;* Sga is used to store database information that is shared by database process.It Contains data and control information for the database.&lt;/p&gt;&lt;p&gt;* Its allocated for the virtual memory of the computer where oracle resides.&lt;/p&gt;&lt;p&gt;&lt;span style="color:#009900;"&gt;sql&gt; show sga&lt;/span&gt;&lt;span style="color:#33cc00;"&gt;;&lt;/span&gt; (this is view of sga).&lt;/p&gt;&lt;p&gt;&lt;span style="color:#3366ff;"&gt;Dynamic Sga :-&lt;/span&gt;&lt;/p&gt;&lt;p&gt;* It allows sga configuration changes without Shutdown the instance . It Can be shared pool ,database buffer cache ,redo log buffer cache.&lt;/p&gt;&lt;p&gt;buffer ( temporarly storage one,example browsing any page when click on any link its seeking that page very slowly ,when you enterd backside button,its coming very fastly).&lt;/p&gt;&lt;p&gt;* A granule is a unit of contiguous(in contact or sharing an edge) virtual memory allocation.&lt;/p&gt;&lt;p&gt;* one granule size 4MB means if estimated sga size is &lt;128mb.&lt;/p&gt;&lt;p&gt;*One granule size is 16MB Otherwise. &gt;128MB.&lt;/p&gt;&lt;p&gt;*buffer cache,large pool,shared pool are allowed to shrink and grow based on granules boundries.&lt;/p&gt;&lt;p&gt;*Allocation of granules via &lt;span style="color:#33cc00;"&gt;ALTER SYSTEM&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color:#000000;"&gt;*Target size in granules tracked and displayed by the&lt;span style="color:#33cc00;"&gt; V$BUFFER_POOL&lt;/span&gt; view.&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color:#3366ff;"&gt;Shared Pool :-&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color:#000000;"&gt;* Its used to store the most recently executed sal statments and data definitions.&lt;/span&gt;&lt;/p&gt;&lt;ul&gt;&lt;li&gt;Library cache&lt;/li&gt;&lt;li&gt;Data dictionary cache&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;&lt;span style="color:#33cc00;"&gt;sql&gt; alter system set shared_pool_size=64MB;&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color:#000000;"&gt;* It Contains both fixed and variable size.&lt;/span&gt;&lt;/p&gt;&lt;p&gt;* Variable Struture ---- It grow and shrink depends on user programme requirments.&lt;/p&gt;&lt;p&gt;** Total sga size cannot exceed sga_max_size.&lt;/p&gt;&lt;p&gt;&lt;span style="color:#3366ff;"&gt;Library Cache :-&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color:#000000;"&gt;* the query or sql statment against the database.&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color:#000000;"&gt;* It stores information about most recently executed used shared sql and pl/sql statments.&lt;/span&gt;&lt;/p&gt;&lt;p&gt;* It managed by least recently used (LRU) algorithm.&lt;/p&gt;&lt;p&gt;* size determined by shared pool size.&lt;/p&gt;&lt;p&gt;* If the size of the shared pool too small,statments are reloaded into the library cache ,which affects performance.&lt;/p&gt;&lt;p&gt;* As the cache fills, Less recently used execution paths and parse trees removed from the library cache to make room for the new entries. They eventually aged out.&lt;/p&gt;&lt;p&gt;&lt;/p&gt;&lt;p&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color:#3366ff;"&gt;Data Dictionary Cache :-&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color:#000000;"&gt;* Its a collection of most recently used definitions in the database.&lt;/span&gt;&lt;/p&gt;&lt;p&gt;* It includes information about &lt;/p&gt;&lt;ul&gt;&lt;li&gt;Database files&lt;/li&gt;&lt;li&gt;Indexes&lt;/li&gt;&lt;li&gt;tables&lt;/li&gt;&lt;li&gt;columns&lt;/li&gt;&lt;li&gt;users&lt;/li&gt;&lt;li&gt;priviliges and other database objects.&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;* During the parse phase ,the server process looks at the data dictionary information to resolve object names and validate access.&lt;/p&gt;&lt;p&gt;* Caching the data dictionary information into memory improves response time on queries.&lt;/p&gt;&lt;p&gt;* Size determined by shared pool sizing.&lt;/p&gt;&lt;p&gt;&lt;span style="color:#3366ff;"&gt;Database Buffer Cache :-&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color:#000000;"&gt;* It stores copies of data block that retrived from the datafiles.&lt;/span&gt;&lt;/p&gt;&lt;p&gt;* It enables great performance gains when you obtain and update data.&lt;/p&gt;&lt;p&gt;* It is managed by LRU algorithm&lt;/p&gt;&lt;p&gt;*&lt;span style="color:#33cc00;"&gt; db_block_size&lt;/span&gt; determined by the primary block size.&lt;/p&gt;&lt;ul&gt;&lt;li&gt;query process ---&gt;server process looks ----&gt; database buffer cache for any need blocks.&lt;/li&gt;&lt;li&gt;If not found, ----&gt; server process reads the block -----&gt; datafiles.and places copies in db cache.&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;* Consistent of independent of sub-caches &lt;/p&gt;&lt;ul&gt;&lt;li&gt;&lt;span style="color:#33cc00;"&gt;db_cache_size&lt;/span&gt; --&gt; default buffer cache size only and cannot set to be zero.&lt;/li&gt;&lt;li&gt;&lt;span style="color:#009900;"&gt;db_keep_cache_size&lt;/span&gt; ---&gt; To retain blocks in memory that are likely to be reused.&lt;/li&gt;&lt;li&gt;&lt;span style="color:#009900;"&gt;db_recycle_cache_size&lt;/span&gt; ---&gt; eliminate block from the memory that have little reused.&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;* Db cache dynamically resized&lt;/p&gt;&lt;ul&gt;&lt;li&gt;&lt;span style="color:#33cc00;"&gt;sql&gt;alter system set db_cache_size = 96M;&lt;/span&gt;&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;* Size of each buffer cache is equal to the size of an Oracle Block.&lt;/p&gt;&lt;p&gt;* Non-standard block size any power of two value between 2kb and 32kb.&lt;/p&gt;&lt;p&gt;&lt;span style="color:#3366ff;"&gt;Redolog Buffer Cache :-&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color:#000000;"&gt;* It records all changes made to the database data blocks.&lt;/span&gt;&lt;/p&gt;&lt;p&gt;* Its primary purpose recovery.&lt;/p&gt;&lt;p&gt;* Changes recorded within are called &lt;span style="color:#cc33cc;"&gt;redo entries.&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color:#000000;"&gt;* Redo entries contain information to the reconstruct or redo changes.&lt;/span&gt;&lt;/p&gt;&lt;p&gt;* size is defined by Log_buffer.&lt;/p&gt;&lt;p&gt;&lt;/p&gt;&lt;p&gt;&lt;/p&gt;&lt;p&gt;&lt;/p&gt;&lt;p&gt;&lt;/p&gt;&lt;p&gt;&lt;/p&gt;&lt;p&gt;&lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2493681572457119266-4531661740082177295?l=azardba.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://azardba.blogspot.com/feeds/4531661740082177295/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2493681572457119266&amp;postID=4531661740082177295' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/4531661740082177295'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/4531661740082177295'/><link rel='alternate' type='text/html' href='http://azardba.blogspot.com/2008/07/memory-struture.html' title='Memory Struture'/><author><name>Azar Mohamed Shaj</name><uri>http://www.blogger.com/profile/04251444414118162294</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://4.bp.blogspot.com/_M42FHtL_R7c/Stmn7gOmPCI/AAAAAAAAAGs/ff_HAJp76GI/S220/untitled.bmp'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2493681572457119266.post-5586290331423164592</id><published>2008-07-01T16:38:00.001+05:30</published><updated>2008-07-02T11:39:13.472+05:30</updated><title type='text'>Oracle Fundamentals I</title><content type='html'>&lt;a href="http://bp3.blogger.com/_M42FHtL_R7c/SGoW5vJBdSI/AAAAAAAAAAM/DLses3aTaDk/s1600-h/oracle+architecture.bmp"&gt;&lt;img id="BLOGGER_PHOTO_ID_5218008299424806178" style="FLOAT: left; MARGIN: 0px 10px 10px 0px; CURSOR: hand" alt="" src="http://bp3.blogger.com/_M42FHtL_R7c/SGoW5vJBdSI/AAAAAAAAAAM/DLses3aTaDk/s320/oracle+architecture.bmp" border="0" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;div&gt;&lt;span style="color:#ff0000;"&gt;Oracle Architectural Components&lt;/span&gt;&lt;/div&gt;&lt;br /&gt;&lt;div&gt;&lt;span style="color:#3366ff;"&gt;Oracle Server:-\ &lt;/span&gt;&lt;/div&gt;&lt;br /&gt;&lt;div&gt;* It contains Several files,process and memory strutures in an oracle server .Not all of them are used when executing a sql statment.&lt;/div&gt;&lt;br /&gt;&lt;div&gt;*The database can be recovered in event of software or hardware error.&lt;/div&gt;&lt;div&gt;*It consists of Oracle Instance and Database.&lt;/div&gt;&lt;ul&gt;&lt;li&gt;Client-application server-server&lt;/li&gt;&lt;li&gt;client-server&lt;/li&gt;&lt;li&gt;host-based&lt;/li&gt;&lt;/ul&gt;&lt;div&gt;&lt;span style="color:#3366ff;"&gt;Client-application-server:-\&lt;/span&gt; (three tiers) user access the database from local computer through an application server.&lt;/div&gt;&lt;div&gt;&lt;span style="color:#3366ff;"&gt;Client-Server:-\&lt;/span&gt; (two tiers) User access the database from their personal computer(client) over a network.Database sits in a separate computer(server).&lt;/div&gt;&lt;div&gt;&lt;span style="color:#3366ff;"&gt;Host-Based :-\&lt;/span&gt; Users directly connected to the same computer on which the database resides.&lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#3366ff;"&gt;Oracle Instance:-\&lt;/span&gt;&lt;/div&gt;&lt;div&gt;* It combination of Background process and memory struture.&lt;/div&gt;&lt;div&gt;*Instance must be started to access the data in database.&lt;/div&gt;&lt;div&gt;*when instance start----&gt; SGA(system global Area ) allocated &amp;amp; bg process are started.&lt;/div&gt;&lt;div&gt;*It perform functions on behalf of invoking processes.&lt;/div&gt;&lt;div&gt;*Always open one and only database.&lt;/div&gt;&lt;br /&gt;&lt;div&gt;&lt;span style="color:#3366ff;"&gt;Oracle Database :-\&lt;/span&gt;&lt;/div&gt;&lt;div&gt;*It consists of Operating system files and also known as datafiles.&lt;/div&gt;&lt;div&gt;*It provide actual storage information and data kept consistent and can be recovered in event of&lt;/div&gt;&lt;div&gt;software or hardware error.&lt;/div&gt;&lt;div&gt;* It consists of three files,&lt;/div&gt;&lt;div&gt;Datafiles--Actual data in a database.&lt;/div&gt;&lt;div&gt;Redo logs --- A record changes of made to the database to enable recovery of the data in case of failures.&lt;/div&gt;&lt;div&gt;Control files ---- containg information necessary to maintain and verify database integrity.&lt;/div&gt;&lt;div&gt;Other Key Files :-&lt;/div&gt;&lt;div&gt;Password file&lt;/div&gt;&lt;div&gt;Parameter file (characterstics of an Oracle instance.it contains size of the sga and so) and Archived redo log file (Offline copies of the redo log files).&lt;/div&gt;&lt;div&gt;&lt;span style="color:#3366ff;"&gt;Establishing a connection &amp;amp; Creating Session:-&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#000000;"&gt;Database user(user process)&lt;------connection established-----&gt;server process&lt;----&gt;(session create) oracle server.&lt;/span&gt;&lt;/div&gt;&lt;div&gt;* Before users can submit Sql statments to an oracle database,they must connect to an instance.&lt;/div&gt;&lt;div&gt;* Such as sql*plus (tool) or Oracle Forms(Application) is excuted as s user process.&lt;/div&gt;&lt;div&gt;* When user logs on to the Oracle server, A process is created on the computer running the Oracle Server. This process is called a &lt;span style="color:#cc33cc;"&gt;Server process&lt;/span&gt;.&lt;/div&gt;&lt;div&gt;&lt;span style="color:#3366ff;"&gt;Sessions:-&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#000000;"&gt;* The session starts when the user is validated by the oracle Server and it ends when the user logs out or when there is an abnormal condition.&lt;/span&gt;&lt;/div&gt;&lt;div&gt;Example: When you log on to any mail id,it created session and then if you are not using particular time ,the session will be ended and then you again login.&lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;div&gt;* One to one correspondance between a user and server process is called a&lt;span style="color:#cc66cc;"&gt; dedicated server.&lt;/span&gt;&lt;/div&gt;&lt;div&gt;* Possible for multiple user processes to &lt;span style="color:#cc66cc;"&gt;share server processes&lt;/span&gt;.&lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#000000;"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="color:#3366ff;"&gt;&lt;/span&gt;&lt;/div&gt;&lt;br /&gt;&lt;div&gt;&lt;span style="color:#333333;"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2493681572457119266-5586290331423164592?l=azardba.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://azardba.blogspot.com/feeds/5586290331423164592/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2493681572457119266&amp;postID=5586290331423164592' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/5586290331423164592'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2493681572457119266/posts/default/5586290331423164592'/><link rel='alternate' type='text/html' href='http://azardba.blogspot.com/2008/07/hai-everbody.html' title='Oracle Fundamentals I'/><author><name>Azar Mohamed Shaj</name><uri>http://www.blogger.com/profile/04251444414118162294</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://4.bp.blogspot.com/_M42FHtL_R7c/Stmn7gOmPCI/AAAAAAAAAGs/ff_HAJp76GI/S220/untitled.bmp'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://bp3.blogger.com/_M42FHtL_R7c/SGoW5vJBdSI/AAAAAAAAAAM/DLses3aTaDk/s72-c/oracle+architecture.bmp' height='72' width='72'/><thr:total>0</thr:total></entry></feed>
