Architecture
1. Why do we need to maintain our data in database?
As we all know Database has a availability of a storage system, the most obvious of these being persistence. To sum it up, we can identify the following reasons for wanting a Database Management Systems short for DBMS:
We need to share data of all kinds between users (except for very small systems), between tools working on them, and usually between different computers. All should be able to work with the same set of data.
We need persistent storage and storage must be reliable.
Several users and/or several tools must be able to safely access the same data concurrently.
A DBMS may provide more efficient access to large amounts of data, through indexing and other optimizations.
A DBMS and its data model provides an abstraction; we do not need to care about the physical storage format.
A DBMS may also be used for communication between different users or applications.
2. What are the responsibilities of a Database Administrator?
Installing and upgrading theOracle Server and application tools.
Allocating system storage and planning future storage requirements for the database system.
Managing primary database structures (tablespaces) Managing primary objects (table, views, indexes)
Enrolling users and maintaining system security.
Ensuring compliance with Oralce license agreement Controlling and monitoring user access to the database.
Monitoring and optimizing the performance of the database.
Planning for backup and recovery of database information.
Maintain archived data on tape Backing up and restoring the database.
Contacting Oracle Corporation for technical support.
3. What are the Daily Activities of aOracle DBA
3. What are the Daily Activities of a
1. Check the Database availability
2. Check the Listener availability
3. Check the alert log file for errors
4. Monitoring space availability in table spaces
5. Monitoring mount point (see capacity planning document)
6. Validate Database backup or Archive backup
7. Find objects which is going to reach max extents
8. Database Health check
9. CPU, Processor, Memory usage
4. What is the most challenging aspect of your job?
This question will give you clues about the mindset of the DBA. When asked what is challenging about the DBA job, the DBA’s answer will reveal a great deal about his or her personality and ability to work well with other people. The DBA who talks about the technical challenges of the job and difficulties administering and maintaining the database may not be ideally suited for a position where contact for the development staff is critical. On the other hand, the DBA who speaks openly of the challenges associated with getting the developers fast answers and accurate information might be a better consideration.
This question will give you clues about the mindset of the DBA. When asked what is challenging about the DBA job, the DBA’s answer will reveal a great deal about his or her personality and ability to work well with other people. The DBA who talks about the technical challenges of the job and difficulties administering and maintaining the database may not be ideally suited for a position where contact for the development staff is critical. On the other hand, the DBA who speaks openly of the challenges associated with getting the developers fast answers and accurate information might be a better consideration.
5. How do you perceive the relationship between the DBA and the development staff?
DBAs by virtue of their high pay and product-specific knowledge, tend to think of developers as underlings, in some cases, DBAs view developers with outright contempt, believing their queries to be naive. On the other hand, DBAs with the proper attitude will respond to this question by talking about the developers as clients to whom they provide data services essential to the application. In some shops, the DBAs may be responsible for code, reviewing SQL queries, or DML statements written by developers; so, a good relationship is vital.
DBAs by virtue of their high pay and product-specific knowledge, tend to think of developers as underlings, in some cases, DBAs view developers with outright contempt, believing their queries to be naive. On the other hand, DBAs with the proper attitude will respond to this question by talking about the developers as clients to whom they provide data services essential to the application. In some shops, the DBAs may be responsible for code, reviewing SQL queries, or DML statements written by developers; so, a good relationship is vital.
6. What is a Database instance?
Explain A database instance (Server) is a set of memory structure and background processes that access a set of database files. The process can be shared by all users. The memory structure that are used to store most queried data from database. This helps up to improve database performance by decreasing the amount of I/O performed against data file.
7. What are mandatory background processes in Oracle Database?
Smon, pmon, ckpt, dbwr, lgwr
8. What is Oltp database?OLTP means Online Transaction Processing. OLAP means Online Analytical Processing. OLTP deals with processing of data from transactional systems. For example, an application that loads the reservation data of a hotel is an OLTP system. An OLTP system is designed mainly keeping in the mind the performance of the end application. It comprises of the application, database & the reporting system that directly works on this database. The database in an OLTP system would be designed in a manner as to facilitate the improvement in the application efficiency thereby reducing the processing time of the application.
9. What is Olap database?
OLAP systems were mainly developed using data in a warehouse. Having said that a need was felt to isolate older data, it was necessary to store them in a format that would be useful in easing out the reporting bottlenecks. A need was felt to isolate the data & redesign the application data to such a format & structure that this data repository would be the prime source of business decisions. Coming back to OLAP systems, these systems were mainly developed on the isolated data.
10. What is the basic element of Base configuration of an oracle Database?
It consists of one or more data files. One or more control files. Two or more redo log groups. The Database contains multiple users/schemas one or more rollback segments
one or more tablespaces Data dictionary tables User objects (table,indexes,views etc.,) The server that access the database consists of SGA (Database buffer cache,Shared pool ,Redo log buffer)
It consists of one or more data files. One or more control files. Two or more redo log groups. The Database contains multiple users/schemas one or more rollback segments
one or more tablespaces Data dictionary tables User objects (table,indexes,views etc.,) The server that access the database consists of SGA (Database buffer cache,Shared pool ,Redo log buffer)
SMON (System monitor)
PMON (Process MONitor)
LGWR (LoG Write)
DBWR (Data Base Write)
ARCH (ARCHiver)
CKPT (Check Point)
RECO
Dispatcher
User Process with associatedPGA .
PMON (Process MONitor)
LGWR (LoG Write)
DBWR (Data Base Write)
CKPT (Check Point)
RECO
Dispatcher
User Process with associated
11. What is the function of Optimizer?
The goal of the optimizer is to choose the most efficient way to execute a SQL statement.
12. What is Execution Plan?
The combination of the steps the optimizer chooses to execute a statement is called an execution plan.
13. What are the different approaches used by Optimizer in choosing an execution plan?
Rule-based and Cost-based.
Rule-based and Cost-based.
14. What are the different Components of SGA?
1. The fixed SGA (Fixed SGA)
2. Default block buffer (Db cache)
3. Different Standard Block buffers
4. Redo log buffer (Redo log buffer)
5. Java pool (Java pool)
6. Large pool (Large pool)
7. Shared pool (Shared pool)
8. Stream pool (Stream pool)
9. Result cache
3. Different Standard Block buffers
4. Redo log buffer (Redo log buffer)
5. Java pool (Java pool)
6. Large pool (Large pool)
7. Shared pool (Shared pool)
8. Stream pool (Stream pool)
9. Result cache
15. What is dictionary cache?
The dictionary cache stores “metadata” (data about your tables and indexes) and it’s also known as the row cache. It is used to cache data dictionary related information in RAM for quick access. The dictionary cache is like the buffer cache, except it’s for Oracle data dictionary information instead of user information.
16. What is Database Buffers?
Database buffers are cache in the SGA used to hold the data blocks that are read from the data segments in the database such as tables, indexes and clusters DB_BLOCK _BUFFERS parameter in INIT.ORA decides the size
17. What is the functionality of SYSTEM table space?
System tablespace is a main part oforacle database. All the database information is in it.it is created when database is created.It is managed byoracle server . dba cannot change its contents. it contains the data dictionary objects .
18. What is the function of checkpoint (CKPT)?
Checkpoint is a background process which ensures dbwn process has written data to datafiles and upadates control file and datafile header to establish data consistency.The CKPT is also useful to get the point in time from where to begin the recovery in case of failure.
19. When does LGWR write to the database?
Log Writer (LGWR) writes redo log entries. it is generated in the redo log buffer of the SGA to on-line Redo Log File.LGWR writes redo log entries into an on-line redo log file when transactions commit and the log buffer files are full.
20. What is Shared SQL Area ?
A shared SQL area contains the parse tree and execution plan for a given SQL statement. Oracle saves memory by using one shared SQL area for SQL statements run multiple times, which often happens when many users run the same application.Oracle allocates memory from the shared pool when a new SQL statement is parsed, to store in the shared SQL area. The size of this memory depends on the complexity of the statement. If the entire shared pool has already been allocated, Oracle can deallocate items from the pool using a modified LRU (least recently used) algorithm until there is enough free space for the new statement's shared SQL area.
21. What Does DBWR do?
Database writer writes modified blocks from the database buffer cache to the data files.
22. What is server processes?
A server process is one that handles user requests. When you type in a SQL statement, the server process handles the parsing and running of that SQL statement,
23 Name the process which carries the request to the memory components,And also fetches from disk to buffer? Server Process
24. Which background process write dirty blocks from database buffer cache to data files?
Database writer (DBWR)
25. Which background process writes data from log buffer to redo log files?
Log writer (LGWR)
26. Which background process performs Crash recovery?
SMON (system monitor)
27. What is Log Switch?
The point at whichORACLE ends writing to one online redo log file and begins writing to another is called a log switch.
The point at which
28. What is On-line Redo Log? The On-line Redo Log is a set of tow or more on-line redo files that record all committed changes made to the database. Whenever a transaction is committed, the corresponding redo entries temporarily stores in redo log buffers of the SGA are written to an on-line redo log file by the background process LGWR. The on-line redo log files are used in cyclical fashion.
29. What are the steps involved in Instance Recovery?Rolling forward to recover data that has not been recorded in data files yet has been recorded in the on-line redo log, including the contents of rollback segments. Rolling back transactions that have been explicitly rolled back or have not been committed as indicated by the rollback segments regenerated in step a. Releasing any resources (locks) held by transactions in process at the time of the failure. Resolving any Pending distributed transactions undergoing a two-phase commit at the time of the instance failure.
30. What does COMMIT do?
COMMIT 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 transaction is committed.
COMMIT 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 transaction is committed.
31. How do you know whether the process is Server Side Process? By seeing the process in ps-ef as ORACLE _SID.
32. When ckpt occurs? 1. For every 3 seconds
2. When 1/3rd of DB buffer fills
3. When log swtich occurs
4. When database shuts down
2. When 1/3rd of DB buffer fills
3. When log swtich occurs
4. When database shuts down
33. What are the two steps involved in instance recovery?
1. Roll forward (redofiles data to datafiles), 2.Roll backward (undo files to data files).
34. What is the use of SMON?
SMON is an Oracle mandatory background process. It is used for Instance recovery.
35. List the Optional Flexible Architecture (OFA) of Oracle database? How can we organize the tablespaces in Oracle database to have maximum performance?
1. SYSTEM - Data dictionary tables.
2. DATA - Standard operational tables.
3. DATA 2- Static tables used for standard operations
4. INDEXES - Indexes for Standard operational tables.
5. INDEXES1 - Indexes of static tables used for standard operations.
6. TOOLS - Tools table.
7. TOOLS1 - Indexes for tools table.
8. RBS - Standard Operations Rollback Segments,
9. RBS1, RBS2 - Additional/Special Rollback segments.
10. TEMP - Temporary purpose tablespace
11. TEMP_USER - Temporary tablespace for users.
12. USERS - User tablespace.
36. How do you know when the process is started?
Using ps -ef grep process name
37. What is meant by redo log buffer?Changes made to entries are written to the on-line redo log files. So that they can be used in roll forward operations during database recoveries. Before writing them into the redo log files, they will first brought to redo log buffers in SGA and LGWR will write into files frequently. LOG_BUFFER parameter will decide the size.
No comments:
Post a Comment