Oracle® Database Installation Guide 10g Release 1 (10.1.0.2.0) for Windows Part Number B10130-01 |
|
|
View PDF |
This appendix describes the Optimal Flexible Architecture (OFA) standard. The OFA standard is a set of file naming and configuration guidelines created to ensure reliable Oracle installations that require little maintenance.
This appendix contains these topics:
For previous releases of Oracle Database, the OFA recommended Oracle home path was similar to the following:
c:\oracle\ora92
For Oracle Database 10g release 1 (10.1), the OFA recommended Oracle home path has changed. The OFA recommended path is now similar to the following:
c:\oracle\product\10.1.0\type_n
In this example, type
is the type of Oracle home, for example Oracle Database (db
) or Oracle Database Client (client
), and n
is an optional counter. This syntax provides the following benefits:
You can install different products with the same release number in the same Oracle base directory, for example:
c:\oracle\product\10.1.0\db_1 c:\oracle\product\10.1.0\client_1
You can install the same product more than once in the same Oracle base directory, for example:
c:\oracle\product\10.1.0\db_1 c:\oracle\product\10.1.0\db_2
When you install Oracle Database, you are installing one of the largest applications that your computer can support. Using multiple Oracle homes and OFA provides many advantages when administering large databases. The OFA standard is designed to:
Organize large amounts of complicated software and data on disk, to avoid device bottlenecks and poor performance
Facilitate routine administrative tasks such as software and data backup, which are often vulnerable to data corruption
Facilitate switching between multiple Oracle databases
Adequately manage and administer database growth
Help eliminate fragmentation of free space in the data dictionary, isolate other fragmentation, and minimize resource contention
OFA can be thought of as a set of good habits to adopt when organizing Oracle directories and files on your computer. All Oracle components on the installation media are OFA-compliant; that is, Oracle Universal Installer places Oracle components in directory locations that follow OFA guidelines. Although using OFA is not a requirement, Oracle recommends that you use it if your database will grow in size, or if you plan to have multiple databases.
The aim of OFA is to prevent an entire class of problems that can occur when you have different releases of Oracle software and multiple, growing databases on your computer.
Oracle Universal Installer separates Oracle software executables from database files. Previously, database files were placed in ORACLE_HOME
\database
, a subdirectory of the Oracle home directory that also contained Oracle software.
Using OFA, Oracle Universal Installer puts Oracle software in ORACLE_BASE
\
ORACLE_HOME
and database files in ORACLE_BASE
\oradata
. Now when you upgrade a database to the latest release, the new Oracle software executables will be placed in a different Oracle home directory. After you judge the upgrade successful, you can easily remove the old Oracle home directory and reclaim space, because the database does not reside there.
An OFA-compliant database has the following characteristics:
Independent subdirectories
Categories of files are separated into independent subdirectories so that files in one category are minimally affected by operations on files in other categories.
Consistent naming conventions for database files
Database files are easily distinguishable from all other files. Files of one database are easily distinguishable from files of another database. Datafiles, redo log files, and control files are easily identifiable. Datafiles are clearly associated with a particular tablespace.
Integrity of Oracle home directories
You can add, move, or delete Oracle home directories without having to revise applications that refer to them.
Separation of administrative information for each database
The ability to distinguish administrative information about one database from that of another ensures a reasonable structure for the organization and storage of administrative data.
Separation of tablespace contents
Tablespace free space fragmentation and I/O request contention are minimized, while administrative flexibility is maximized.
Tuning I/O loads across all disks
I/O loads are tuned across all disks, including disks storing Oracle data in raw devices, if needed.
OFA has necessitated changes to the Oracle Database directory tree. This section lists the differences.
When you install an Oracle8i release 8.1.3 or earlier release, all subdirectories are located under a top-level ORACLE_HOME
directory that by default is C:\orant
.
When you install an Oracle8i release 8.1.4 or later OFA-compliant database, all subdirectories are no longer under a top-level ORACLE_HOME
directory. There is now a new top-level directory called ORACLE_BASE of form c:\oracle\product\10.1.0
, where c
is any hard drive.
ORACLE_BASE
contains \
ORACLE_HOME
directories, \oradata
directories (for database files), and \admin
directories (for database administration files).
In Oracle8i release 8.1.3 and earlier releases, database files have the SID in the database filename. For example, the first control file is named ctl1
SID
.ora
.
Beginning with Oracle8i release 8.1.4, database files no longer have the SID in the database filename. For example, the first control file is named control01.ctl.
There is no need for the presence of the SID in the filename, because all the database files for a particular database are placed in \oradata
under a directory called DB_NAME
that is named for that database.
In Oracle8i release 8.1.3 and earlier releases, all database files have the same ".ORA"
extension.
In an OFA-compliant release, the convention of having ".ora"
as the filename extension for database files is no longer used. Database filenames now have more meaningful extensions. These are:
.ctl
for control files
.log
for log files
.dbf
for datafiles
OFA uses directory naming conventions that make it easy to identify the precise Oracle home and database name that is associated with a set of files. This section describes the naming conventions used for top-level directories of an OFA-compliant database directory tree:
ORACLE_BASE
is the root of the Oracle directory tree. If you install an OFA-compliant database using Oracle Universal Installer defaults, then ORACLE_BASE
is x:\oracle\product\10.1.0
where x is any hard drive.
If you are installing Oracle Database for Windows on a computer with no other Oracle software installed, then you can change ORACLE_BASE
before running Oracle Universal Installer. Most users will not need or want to do this.
Do not change the value of ORACLE_BASE
after you run Oracle Universal Installer for the first time. If there is an existing ORACLE_BASE
and you change it, then there will be a conflict of Oracle base directories. If you create another ORACLE_BASE
when the original ORACLE_BASE
already exists, then certain tools and the database will not be able to find previously created files. They will look for them in the new ORACLE_BASE
instead of the original ORACLE_BASE
.
See Also: Your operating system documentation for instructions on editing environment variables |
The \ORACLE_HOME
directory is located beneath c:\ORACLE_BASE
and contains subdirectories for Oracle software executables and network files.
If you install Oracle Database for Windows on a computer with no other Oracle software installed and you use default settings, then the first Oracle home directory that you create is called \db_1
.
Database administration files are stored in subdirectories of ORACLE_BASE
\ \admin\
DB_NAME
. Names and brief descriptions of some of these subdirectories are:
\bdump --background process trace files \cdump --core dump files \create --database creation files \exp --database export files \pfile --initialization parameter files \udump --user SQL trace files
Database files are stored in ORACLE_BASE\ORADATA\DB_NAME
. Names and brief descriptions of these files are:
CONTROL01.CTL --control file 1 CONTROL02.CTL --control file 2 CONTROL02.CTL --control file 3 EXAMPLE01.DBF --EXAMPLE tablespace datafiles SYSAUX01.DBF --SYSAUX tablespace datafiles SYSTEM01.DBF --SYSTEM tablespace datafile TEMP01.DBF --TEMP tablespace datafile USERS01.DBF --USERS tablespace datafile *.dbf --datafiles corresponding to each tablespace in your database REDO01.LOG --redo log file group one, member one REDO02.LOG --redo log file group two, member one REDO03.LOG --redo log file group three, member one
Note: This directory structure allows for disk striping only on UNIX platforms. See "Support for Symbolic Links on Windows". |
DB_NAME
is the unique name for a particular database and has the same value as parameter DB_NAME
in the initialization parameter file. When you create a database, DB_NAME
can be no more than eight characters long and can contain only the following characters:
Alphabetic characters
Numbers
Underscores (_)
Pound sign (#)
Dollar sign ($)
The following sections describe various OFA and multiple Oracle homes configurations.
To install an OFA-compliant database, you must specify an Oracle home directory in the Path field of Oracle Universal Installer. It is of the form:
X:\[PATHNAME]\oracle\HOME_NAME
where:
X:\
is any hard drive. For example, C:\
PATHNAME
is an optional directory path name
\oracle
is a mandatory directory path name, unless you changed the value of registry key ORACLE_BASE
before performing the installation
HOME_NAME
is the name of the Oracle home
The following are examples of OFA-compliant Oracle home directories:
C:\test\oracle\product\10.1.0\db_1
D:\oracle\product\10.1.0\db_1
Install any Oracle Database that supports OFA (Oracle Database 8.1.6 or later) on a computer with no other Oracle software installed and make sure that you accept default settings for the Oracle home (for example, c:\oracle\ora81
).
Install any Oracle Database (for example, Oracle Database) in a second Oracle home accepting the default settings.
Table B-1 shows the default OFA database settings.
Install any Oracle Database that supports OFA (Oracle Database 8.1.6 or later) on a computer with no other Oracle software installed and change default Oracle Universal Installer settings for the first Oracle home (for example, from C:\oracle\ora81
to X:\xyz
).
Install any Oracle Database (for example, Oracle Database 10g release 1 (10.1)) in a second Oracle home and change default Oracle Universal Installer settings for the second Oracle home (for example, from X:\xyz
to Y:\abc
).
Table B-2 shows the nondefault OFA database settings for example 1.
Table B-2 Nondefault OFA Database Settings: Example 1
Directory | Value |
---|---|
ORACLE_BASE |
X:\xyz for first Oracle home; Y:\abc for second Oracle home |
Oracle home 1 | X:\xyz |
Oracle home 2 | Y:\abc |
The resulting directory tree would look similar to this:
X:\xyz \admin \DB_NAME1 \DB_NAME2 \bin \network \oradata \DB_NAME1 CONTROL01.CTL CONTROL02.CTL CONTROL03.CTL EXAMPLE01.DBF SYSAUX01.DBF SYSTEM01.DBF TEMP01.DBF USERS01.DBF REDO01.LOG REDO02.LOG REDO03.LOG \DB_NAME2 Y:\abc \admin \DB_NAME1 \DB_NAME2 \bin \network \oradata \DB_NAME1 CONTROL01.CTL CONTROL02.CTL CONTROL03.CTL EXAMPLE01.DBF SYSAUX01.DBF SYSTEM01.DBF TEMP01.DBF USERS01.DBF REDO01.LOG REDO02.LOG REDO03.LOG \DB_NAME2
Install any Oracle Database that supports OFA (Oracle Database 8.1.6 or later) on a computer with no other Oracle software installed and change default Oracle Universal Installer settings for the first Oracle home (for example, from C:\oracle\ora81
to X:\xyz\oracle\abc
).
Install any Oracle Database and change default Oracle Universal Installer settings for the second Oracle home (for example, from C:\oracle\ora10
to X:\pqr
).
Table B-3 shows the nondefault OFA database settings for example 2.
Table B-3 Nondefault OFA Database Settings: Example 2
Setting | Value |
---|---|
ORACLE_BASE |
X:\xyz\oracle
(same for both Oracle homes) |
Oracle home 1 | X:\xyz\oracle\abc |
Oracle home 2 | X:\pqr |
The resulting directory tree would look similar to this:
X:\pqr --Oracle home 2 \bin \network X:\xyz \oracle --ORACLE_BASE for both Oracle homes \abc --Oracle home 1 \bin \network \admin \DB_NAME1 \adhoc \bdump \cdump \create \exp \pfile \udump \DB_NAME2 \... \oradata \DB_NAME1 CONTROL01.CTL CONTROL02.CTL CONTROL03.CTL EXAMPLE01.DBF SYSAUX01.DBF SYSTEM01.DBF TEMP01.DBF USERS01.DBF REDO01.LOG REDO02.LOG REDO03.LOG \DB_NAME2
One of the basic goals of OFA is to increase reliability and performance by distributing I/O loads across different physical drives. Two ways to do that are:
Oracle Database log files and database files can be separated and treated with different levels of hardware reliability. Oracle Database log files are highly reliable to start with, because they are stored redundantly. Creating similar reliability for database files may require you to duplicate all of your data, using disk mirrors.
Disk mirroring usually involves two or more identical drives and either a hardware controller or Windows Disk Administrator. If one disk fails, then the other disk(s) can be used to recover data that would otherwise be lost. Using one of the disks to recover lost data may involve "breaking" the mirror. If the mirror breaks, then you must build a new mirror.
Disk mirroring is part of some levels of Redundant Array of Independent Disks (RAID) configurations, provided by the disk controller. The RAID level determines the amount of redundancy. Some RAID levels can use the "hot swapping" feature, which means that you can replace a bad disk with a good one without turning off the computer or losing functionality.
How you set up disks for use in a database depends on the number of disks and the type of hard disk controllers available. If the hard disk controllers support both striping and mirroring, then Oracle recommends you configure the controllers to support striping.
Some controllers are configured at system startup time by issuing a keyboard sequence that brings up configuration programs written by the controller manufacturer. One goal is to stripe as many drives together as possible by configuring the controllers. Each stripe shows up as one logical device.
Striping provides significant performance advantages. All the space from the striped drives appears as a single logical drive. Furthermore, the space is used by interlacing "stripes" of space from all of the disks in the stripe. This means that a large file uses some space from the first disk, then some from the second disk and so on to the last disk and then starting back at the first disk again. Each file can be spread over all of the striped disks. Data in such a file may be accessed randomly by more than one CPU without contention.
Controllers that support striping usually provide caching as well. This means that data can be written to the controller and cached and saved for a time in storage not on the disk. Data that is read can be cached on the controller in a similar fashion. Read caching should not be used with Oracle Database, because all database reads are cached already in the System Global Area (SGA). The value of parameter DB_CACHE_SIZE
in the initialization parameter file (init.ora
) determines the buffer size that can be used in the SGA. This value also configures Oracle Database on startup.
Note:
|
A raw partition is a portion of a physical disk that is accessed at the lowest possible level. I/O of a raw partition improves performance by approximately 5% to 10% compared to I/O of a partition containing a file system. Therefore, Oracle encourages you to use raw partitions for your tablespace files.
You implement OFA on Windows and UNIX in the same way. However, differences exist with regard to the following:
Support for Symbolic Links on Windows
See Also: Your UNIX operating system-specific administrator's reference for information about OFA on UNIX |
Top-level names of the OFA directory tree differ between Windows and UNIX. However, main subdirectory and filenames are the same on both operating systems.
On Windows, ORACLE_BASE
is associated with an Oracle home directory. ORACLE_BASE
is defined in the registry (for example, in HKEY_LOCAL_MACHINE\SOFTWARE\ORACLE\KEY_
HOME_NAME
).
On UNIX, ORACLE_BASE
is associated with a UNIX user's environment.
The goal of OFA is to place all Oracle software under one ORACLE_BASE
directory and to spread files across different physical drives as your databases increase in size.
On UNIX, although everything seems to be in one directory on the same hard drive, files can be on different hard drives if they are symbolically linked or have that directory as a mount point.
Windows currently does not support symbolic links, so datafiles will not all show up under a single directory like on UNIX. Instead, you may have oradata
directories on multiple drives, with datafiles in each one. In this way, you still get OFA benefits, even though datafiles are not all visible in a single directory.
Oracle recommends that you use one logical drive to store your database administration files and that you place other files, as needed, on other logical drives in an oradata\
DB_NAME
directory.
In the following example, there are four logical drives for a database named prod
:
C:\
contains an Oracle home and database administration files.
F:\
contains redo log files. (F:\
drive could also represent two physical drives that have been striped to increase performance.)
G:\
contains one of the control files and all tablespace files. (G:\
drive could also use a RAID Level-5 configuration to increase reliability.)
H:\
contains the second control file.
The directory structure would look similar to this:
C:\oracle\product\10.1.0 --First logical drive \db_1 --Oracle home \bin --Subtree for Oracle binaries \network --Subtree for Oracle Net \... \admin --Subtree for database administration files \prod --Subtree for prod database administration files \adhoc --Ad hoc SQL scripts \adump --Audit files \bdump --Background process trace files \cdump --Core dump files \create --Database creation files \exp --Database export files \pfile --Initialization parameter file \udump --User SQL trace files F:\oracle\product\10.1.0 --Second logical drive (two physical drives, striped) \oradata --Subtree for Oracle Database files \prod --Subtree for prod database files redo01.log --Redo log file group one, member one redo02.log --Redo log file group two, member one redo03.log --Redo log file group three, member one G:\oracle\product\10.1.0 --Third logical drive (RAID level 5 configuration) \oradata --Subtree for Oracle Database files \prod --Subtree for prod database files CONTROL01.CTL --Control file 1 EXAMPLE01.DBF --EXAMPLE tablespace datafiles SYSAUX01.DBF --SYSAUX tablespace datafiles SYSTEM01.DBF --System tablespace datafile TEMP01.DBF --Temporary tablespace datafile USERS01.DBF --Users tablespace datafile H:\oracle\product\10.1.0 --Fourth logical drive \oradata --Subtree for Oracle Database files \prod --Subtree for prod database files CONTROL02.CTL --Control file 2