Previous Table of Contents Next


Memory Requirements

The Oracle Installation Guide will also list the correct UNIX kernel settings for several important memory parameters. Prior to installation, make sure SHMMAX (max size of a shared memory segment), SHMMHI (max number of shared memory segments), SEMMNI (minimum number of semaphores on the system), SEMMNS (max number of semaphores on the system), and SHMSEG (max number of segments per process) are all set to the recommended settings.


Tip:  
If Oracle is unable to allocate a semaphore, increase the SEMMNI and SEMMNS values. If Oracle is unable to attain shared memory, try increasing the SHMSEG value.


Tip:  
If available on your particular UNIX platform, pin or lock the SGA in physical memory to prevent it from being swapped or paged out of memory.

Use the UNIX program vmstat to monitor if the UNIX kernel is swapping processes out of memory. Swapping in an Oracle environment is not a good thing. It means some process was temporarily stored on disk to free memory for another, more urgent process to execute. If swapping is occurring, there are two options that can quickly remedy this situation. The first solution is to add more memory to the hardware platform. The second option involves the buffer-cache-hit ratio calculation (Listing 24.2) covered in depth in the next section. The size of the buffer cache can be reduced until the buffer-cache-hit ratio is adversely affected. Lowering the amount of db_block_buffers in the init.ora parameter will free physical memory. See the Oracle RDBMS level section on buffer cache tuning for a further discussion and a calculation for the buffer-cache-hit ratio.


Tip:  
Make sure there is enough memory so that there is no dynamic memory swapping occurring and the buffer-cache-hit ratio is not adversely affected.

Disk Requirements

This section will discuss disk drives (physical disk drives with UNIX file systems), raw partitions (no UNIX file system), and RAID drive technology (see Figure 24.1).


Figure 24.1.  Raw versus file system disk access diagram.

Disk drives with the UNIX file system are easy to monitor (with the sar command), easy to back up and restore, and in general, just plain easier to work with. The UNIX file system has a number of commands that allow easy access to disk drives. UNIX disk drives can be mounted most anywhere in the UNIX directory structure, adding a degree of logical application separation to multiple disk drives with the ease of access, backup and restore, and so on, all from a single UNIX directory.

Raw partitions have no UNIX file system or the 15 percent performance overhead of UNIX file system drives. There is also about 10 percent additional disk space available without the UNIX file system overhead. Raw partitions are more difficult to administrate in general, and backup and recovery will be more complex.


Note:  
Raw partitions are 15 percent to 20 percent faster than file-system drives at the expense of being more difficult to administrate.


Note:  
Oracle Parallel Server requires the use of raw partitions for shared database files.

RAID, or redundant array of inexpensive devices, is a bank of disk drives the computer will view as one physical drive. The Oracle environment will view a single RAID device as a single disk device as well.

There are 5 levels of RAID. RAID level 0 stripes data files across the available disk drives without any mirroring or parity checking. RAID level 1 identically mirrors disk drives. RAID levels 2, 3, and 4 are not used and do not apply to business systems. RAID level 5 is a combination of RAID level 0 and RAID level 1. RAID level 5 stripes data files, mirrors the striped disk segments across many available drives, and provides parity to insure the accuracy of the reads and writes. Both RAID level 1 and RAID level 5 will automatically alert the system operator of a disk failure and automatically use the mirrored copy. RAID’s levels 1 and 5 also support disk drive replacing without interruption to the UNIX environment or the application. This technology will automatically restore data to the newly replaced disk drive.


Note:  
RAID level 5 can have up to four physical writes for each disk write command issued.

There should be enough disk drives available on the hardware platform to separate the UNIX operating system, application software, and other UNIX processes. The Oracle software should be separated from the tablespace data files, and the SYSTEM, TEMPORARY, and ROLLBACK tablespace data files should be on separate drives as well. If the application has a lot of INSERT and UPDATE activity, the online redo logs should be on yet another separate disk drive. Depending on application needs, there should be enough disk drives to separate and load balance application I/O, enabling additional options in the database design level tuning. Each level of tuning aids the next level down. Application performance and fault-tolerant requirements will dictate the use of raw partitions and/or RAID drives. If RAID drives are utilized, RAID level 1 could have an Oracle mirrored set of redo logs (adding to the security of the data) as well as files associated with most any tablespace.


Note:  
It has been my experience that the best performance gains come from physically separating I/O traffic, something that is difficult to do with RAID level 0 and RAID level 5.


Tip:  
I would use RAID level 5 for mostly read applications that require a high degree of availability.


Tip:  
I would not use RAID technology for the SYSTEM, TEMPORARY, or ROLLBACK tablespaces unless the application demanded a fault-tolerant environment at the expense of performance.


Previous Table of Contents Next
Используются технологии uCoz