Oracle Learning Notes --- FAQ Collection

xiaoxiao2021-03-06  56

1. What is the relationship between examples and SID? What is the relationship between examples and databases?

Often someone asking the SID? SID in the Oracle system is a frequent variable, such as environment variables Oracle_sid, initialization file INITSID.ORA, what is SID? In fact, the SID is an identifier of the Oracle instance, and the different SIDs correspond to different memory buffers (SGAs) and different background processes. In this way we can have multiple SID database instances on a physical server.

A running Oracle database can be seen as an Oracle Server, which consists of database (Database) and instances (instance), in general, one Oracle Server contains an instance and a corresponding database, but In special cases, such as the OPS, 9i RAC of 8i, one database in a server can correspond to multiple instances.

A series of physical files (data files, control files, online logs, etc.) or corresponding logical structures (table space, segments, etc.) are called database, simply, is a series of physical files with disk. Composition. Oracle Memory Structure and Background Process are instances of the database, one instance can only be installed (mount) and open (Open) on a database, responsible for the corresponding operation of the database and interact with the user.

2, what is the relationship between Oracle Database and an instance?

The database is composed of an instance of a physical file and an access data file. When an instance of an access data file is one, the database is called a single-node database. This is the most database form we see. Of course, there is a multi-node database, which is one or more instances to access a database (or jointly accessing a set of data files), better providing stability and parallel processing capabilities. This is called OPS (Oracle Parallel Server) in Oracle9i in Oracle9i, called RAC (Real Application Cluster). In this database. Two / multiple instances are on different servers, all Oracle data files on a shared disk array, instances on multiple servers can work simultaneously, they communicate through an internal network. If a server can't serve the service, the other will take over its work, especially in key business, great potential.

3. Is there any data that may be not submitted in the data file in the running database?

This is likely to exist because the data of the user data file is written by DBWR, and DBWR is a very bottom background process, not responsible for interacting with the user. The user's interaction is done by LGWR.

4, in the problem 3, if there is no data written, the machine suddenly power off, will the data integrity will be damaged?

No, because the integrity of the database is LGWR to ensure that Oracle ensures that any modifications of DBWR write data files have been recorded in redo log files. When the system starts again, you can know that those data are not submitted by reading a log file. This time Oracle will automatically roll back these data. Therefore, the damage of the online log, especially the current online log, the impact on the database is huge, which may result in incomplete databases.

5. Does the data file lose data?

It can be said that if you have backed up and archiving, it will not. Because all records of data modifications are recorded in redo logs, it will not be lost, and you will resume all data as long as you recover the previous backups Restore and current online log files.

6, is there a log damage to log damage?

Online log is extremely damage to the database, so it is not only possible to lose data, but it may also cause different steps from the database. Records of all commits in redo logs will be lost, which is why Oracle is the reason for mirroring on line weight log files. Any data loss is not allowed. 7. Can I specify if I don't write a rollback segment?

It is not possible, the writeback segment is Oracle to ensure consistent read and transaction consistency. The rollback segment is a high-write section, it is recommended to put it on a separate device. For DDL statements, such as DROP, TRUNCATE can do not write a segment (without UNDO information), so the deletion of the entire table, if the amount of data is relatively large, it is recommended to use Truncate Table. Do not write online logs, but you can write very little online logs in some specific operations, such as creating a table via Create Table Tablename as SELECT in NOLOGGING, or in an append method INSERT data to the table, Or direct loading and other operations.

转载请注明原文地址:https://www.9cbs.com/read-117324.html

New Post(0)