Job Seekers   Employers
dbapool: Authors | Submissions | Contact Us
   Forgot password? | Sign up
  Home   Discussion Forum   Articles   Interview Questions   FAQs   Scripts   Rewards   Analyzer   White Papers   Blog   Certification   Downloads   Tools
 

Topic: Database Administration >> commit

Disclaimer: The purpose of all dbapool forums including OCP and Other Oracle Certification forums is to help each other with specific issues but not to share dump and copyrighted exam content, materials or intellectual property. You may review the entire Oracle Certification Program Candidate Agreement online Here.



  


 Title: commit
 shikhu  Posted: Jul 05, 2007 10:05:05 AM

 Total Post: 61
 Joined: Jul, 2006






 Hi All,

I want to know what exactly happens internally when we issue a commit, means How Oracle going to know that what data is committed and what is uncommited as my data files may contain both types of data.

 Ratnaker
Posted: Jul 06, 2007 09:10:09 AM  

 Total Post: 136
 Joined: Apr, 2007






 
Hi Sikku,

To commit a transaction makes permanent the changes resulting from all SQL statements in the transaction. The changes made by the SQL statements of a transaction become visible to other user sessions' transactions that start only after the transaction is committed.

Ratnaker

 shikhu
Posted: Jul 06, 2007 09:55:03 AM  

 Total Post: 61
 Joined: Jul, 2006






 
hi KP,

Question is : when a transaction is going on and is not commited and there is a logswitch then this uncommited tranx. is written to datafiles, meaning to say that my datafile may contain commited and uncommited data and suddenly my instance got crashed then SMON activates and rollback that incompleted/uncommited transaction from Undo t/s , my confusion is howcome SMON come to know that this transaction is uncommited or what shud I say an open transaction , and need a rollback.




 Ratnaker
Posted: Jul 09, 2007 01:54:46 AM  

 Total Post: 136
 Joined: Apr, 2007






 
Hi shikku,

The goal of crash and instance recovery is to restore the data block changes located in the cache of the terminated instance and to close the redo thread that was left open. Instance and crash recovery use only online redo log files and current online datafiles. Oracle recovers the redo threads of the terminated instances together.

Crash and instance recovery involve two distinct operations: rolling forward the current, online datafiles by applying both committed and uncommitted transactions contained in online redo records, and then rolling back changes made in uncommitted transactions to their original state.

Crash and instance recovery have the following shared characteristics:

Redo the changes using the current online datafiles (as left on disk after the failure or SHUTDOWN ABORT)

Use only the online redo logs and never require the use of the archived logs

Have a recovery time governed by the number of terminated instances, amount of redo generated in each terminated redo thread since the last checkpoint, and by user-configurable factors such as the number and size of redo log files, checkpoint frequency, and the parallel recovery setting

Oracle performs this recovery automatically on two occasions:

At the first database open after the failure of a single-instance database or all instances of an Oracle Real Applications Cluster database (crash recovery).

When some but not all instances of an Oracle Real Application Clusters configuration fail (instance recovery). The recovery is performed automatically by a surviving instance in the configuration.

The important point is that in both crash and instance recovery, Oracle applies the redo automatically: no user intervention is required to supply redo logs.


 positive
Posted: Jun 29, 2008 08:56:17 PM  

 Total Post: 361
 Joined: Jun, 2008






 
when commit is issued,

data from db buffer cache is written to disk and header is updated.simultaneously scn is updated in controlfile.data from redolog buffer are written to redo logs.

To get more details visit:

http://neworacledba.blogspot.com/

 Time Zone: EDT

  




Forum Rules & Description


Who Can Read The Forum? Any registered user or guest
Who Can Post New Topics? Any registered user
Who Can Post Replies? Any registered user




 








Get FREE Magazines

Top 10 Forum User

  Murtuja Khokhar814
  Mohammed Taj694
  Jayanta Sur479
  Vigyan Kaushik386
  positive fanatic361
  Gitesh Trivedi322
  Gopu Gopi239
  neeraj sharma228
  Ramesh Jois226
  snehalatha p169






oracle Mag



  About Us Advertise Terms of Use Privacy Newsletters Contact Us    

Home   Discussion Forum   FAQs  Articles  Jobs   Newsletters  Directory  Downloads 

Our Premium Sponsor
Confio Software