||Oracle Tips by Burleson
Oracle disk Raw Devices
In Unix and NT/Windows systems there are several types of disk
formats used. Generally, the highest performance comes from programs
that can directly access the disk. In order to be directly accessed
a disk must be configured in what as known as raw format meaning no
OS buffering or access control is used.
While raw disks provide performance gains over many traditional disk
formats they have several limitations that make their use difficult.
An example is that only one file may be placed in a raw disk
partition at one time, another is that raw disk partitions may
require special backup commands. Finally, raw devices can be easily
overwritten if the system administrator is not careful.
If you have tuned your application, I/O, and all applicable SGA
parameters and still cannot get the performance you want on UNIX or
NT, then consider using raw devices. Oracle is capable of reading
and writing directly to raw devices. This can increase Oracle
performance for disk I/O by over 50 percent and ensures that data
integrity is maintained. But when raw devices are used, Oracle
datafile names are restricted to a specified syntax. Another
limitation is that the entire raw partition has to be used for only
one file, which can lead to wasted disk space unless the areas are
carefully planned. This will require the Remote DBA to keep an accurate map
of which devices belong to which tablespaces, log files, and so on.
Another method is to turn off UNIX buffering. Whether the option of
removing UNIX buffering is open to you depends on the version of
UNIX you are using.
There are also limitations on types of backup that can be used. Many
third-party software packages that are designed for use with Oracle
support backup of RAW devices. If you don’t have one of these
packages, I suggest ensuring you have enough formatted (cooked) file
systems to support a “dd” to a cooked file system followed by a
There is some debate as to whether the reported up-to-50 percent
increase in speed of access is due to the RAW device usage, or a
good deal of it is an artifact of the conversion process from a
cooked to araw system. Generally, a system with bad performance has
other problems, such as chained rows and excessive table extents as
well as improper placement of indexes, tables, redo, and rollback.
The Remote DBA converts to raw by exporting, dropping the database, doing
the raw partitions, re-creating the database, and then importing.
Usually, files will be better placed due to lessons learned. The
chained rows and multiple table extents are eliminated by the
export/import; and another major performance problem, brown indexes
(the process by which excessive numbers of empty leaf nodes
resulting from UPDATE and DELETE operations cause index broadening),
is fixed by the import rebuild of the indexes. Voila! The system is
50 percent faster, and RAW gets the credit, when doing all of the
above to the database on a cooked file system would have given the
If you want to use a shared instance (Oracle’s Parallel Server or
Real Application Clusters option), you must use raw devices on UNIX
since there are no UNIX file systems that support the proper sharing
of disks in other than a raw state.
Expert Remote DBA
BC is America's oldest and largest Remote DBA Oracle support
provider. Get real Remote DBA experts, call
BC Remote DBA today.