Waiting for snapshot control file enqueue
![waiting for snapshot control file enqueue waiting for snapshot control file enqueue](https://venturebeat.com/wp-content/uploads/2020/01/OpsRamp-dashboard.png)
These structures are (1) datafiles (2) controlfiles and (3) redolog files. The Oracle Internals maintain the structural details of these structures. Oracle has three important structures that take care of the database.
![waiting for snapshot control file enqueue waiting for snapshot control file enqueue](https://4.bp.blogspot.com/-5ng1eFuTl44/XGztp0HW2gI/AAAAAAAAAtM/mPajYBcjQfYfpN1_RWSjWhKJcFHFtSECgCLcBGAs/s1600/sran_snapshot1.png)
If an instance failure or a system failure occurs during that event of resizing the controlfiles may get corrupted. Controlfile backups are advocated along with the datafiles only because the resizing takes place under the protection of CF enqueue. The control_file_record_keep_time parameter can also be set to zero to prevent keep time related controlfile expansion, if it suits the requirements of maintenance of database. (The controlfile size limit is based on the number of blocks that can be represented in the block version bitmap, and is thus most unlikely to be reached.) Informational “kccrsz” messages about the dynamic expansion of the controlfile (or the failure to do so) may be seen in the alert log file for the instance. If all the slots in a record section are in use and that number of days has not yet elapsed since the timestamp on the earliest entry, then Oracle dynamically expands the record section (and thus the controlfile too) to make more slots available, up to a maximum of 65535 slots per section, or the controlfile size limit. The particular initialization parameter ‘control_file_record_keep_time’ sets the minimum number of days that must have elapsed before a reusable controlfile record slot can be reused. Overwriting the information already contained in the controlfile reuses the space in the controlfiles and thus a bit of control can be exercised by the User. The SQL is to be executed as SYS user only other wise table or view does not exist error may popup. To know the addresses of these structures the X$KCCRS columns can be mapped. The View V$CONTROLFILE_RECORD_SECTION contains all the structures a control file has in it. Then, instead of using pairs of physical blocks to represent each logical block, each checkpoint progress record is maintained in its own physical block so that checkpoint heartbeat writes can be performed and committed atomically without affecting any other data. Instead the size of the checkpoint progress record is overstated as half of the available space in a controlfile block, so that one physical block is allocated to the checkpoint progress record section per thread. The controlfile transaction mechanism is not used for updates to the checkpoint heartbeat. It is also used in queries that perform multiple controlfile reads to ensure that a consistent snapshot of the controlfile has been seen. It is used in the cache header of each controlfile block in place of an SCN to detect possible split blocks from hot backups. This number is recorded with the block version bitmap and database information entry in the first record section of the controlfile. Whenever a controlfile transaction is committed, the controlfile sequence number is incremented. This is essentially to maintain the mechanism of controlfile transactions. Two physical blocks represent each logical block. After the header block, all controlfile blocks occur in pairs. Oracle 9i permits you to have tablespaces created with different data blocks, of course, with some restrictions, such as SYSTEM, TEMP and RBS/UNDO tablespaces cannot have different data blocks than the default data block size. Hence it is not advised to go for a change of data block after the database is created. There are several restrictions varying from the platforms to oracle versions. If the Oracle data block size is to be modified the database is to be exported and imported into the database created with a different size of the data block. This default size cannot be changed once database is created. So comparing the size of the controlfile with the size as shown at OS level tallies the number of the Controlfile blocks. Oracle data blocks are in the multiples of OS blocks and OS blocks are determinable and specific as provided by the OS vendors in the OS docs. This is tallied with the size of the controlfile in bytes at the OS level.