Overview of Unix Resources
In this Document
1 Applies to:
Oracle Database - Enterprise Edition -
Version 10.2.0.1 and later 2 Purpose This note provides information about administering Oracle Database on UNIX-based operating systems. You must set Oracle Database environment variables, parameters, and user settings for Oracle Database to work. 3 Scope
Database performance is bounded by the system
resources. Sometimes, poor database performance can be caused by faulty
configuration of the instance and database. Sometimes, it can be caused by
abnormal resource consumption by an Oracle transaction, user, or process. 4 Details 5 Environment Variables
To display the current value of an environment
variable, use the env command. For example, to display the value of the
ORACLE_SID environment variable, run the following command:
To display the current value of all environment
variables, run the env command as follows: 1. Oracle Database Environment Variables Below are some environment variables used with Oracle Database and their descriptions: NLS_LANG: Specifies the language, territory, and character set of the client environment. The client character set specified by NLS_LANG must match the character set of the terminal or terminal emulator. ORA_NLS10: Specifies the directory where the language, territory, character set, and linguistic definition files are stored. ORA_TZFILE: Specifies the full path and file name of the time zone file. The Oracle Database Server always uses the large time zone file ($ORACLE_HOME/oracore/zoneinfo/timezlrg_number.dat).
ORACLE_BASE: Specifies the base of the Oracle directory structure
for Optimal Flexible Architecture compliant installations.
ORAENV_ASK: Controls whether the oraenv or coraenv script prompts
or does not prompt for the value of the ORACLE_SID environment variable. TWO_TASK: Specifies the default connect identifier to use in the connect string. If this environment variable is set, then do not specify the connect identifier in the connect string. NLS_OS_CHARSET: Specifies the Oracle character set name corresponding to the UNIX locale character set in which the file names and user names are encoded by the operating system. 2. UNIX Environment Variables Below are some of the UNIX environment variables used with Oracle Database: HOME: The home directory of the user. LD_LIBRARY_PATH: Environment variable to specify the path used to search for libraries on UNIX and Linux. The environment variable may have a different name on some operating systems, such as LIBPATH on AIX, and SHLIB_PATH on HP-UX.
PATH: Used by the shell to locate executable programs; must include the
$ORACLE_HOME/bin directory. 6 Memory Requirements
The following are the memory requirements for
installing Oracle Database 11g Release 2 (11.2): To determine the RAM size, enter the following command: # grep MemTotal /proc/meminfo If the size of the RAM is less than the required size, then you must install more memory before continuing.
On Linux, the HugePages feature allocates non-swappable memory for large page tables using memory-mapped files. If you enable HugePages, then you should deduct the memory allocated to HugePages from the available RAM before calculating swap space.
7 Configuring Swap Space Swap space holds the virtual memory of the system. Every program you run occupies a certain amount of virtual memory. Once all your virtual memory has been allocated to specific applications you cannot start new programs and currently running programs may fail if they try to grow. Physical memory is what you know as the RAM of the system. If you use up all the RAM, your system may run more slowly, but you can still start more programs because the swap space absorbs excess data. Oracle does not access nor use swap space directly. If it is used indirectly, it would be provided to Oracle as "virtual memory" by the Linux / UNIX OS, as a consequence of the Linux / UNIX system running out of RAM memory.
Oracle's Recommendations for swap size on
Linux / UNIX systems are best summarized in: To see the amount of swap space on the machine and its usage, check the following:
8 Configuring Huge Pages HugePages is a feature integrated into the Linux kernel with release 2.6. This feature basically provides the alternative to the 4K page size (16K for IA64) providing bigger pages. Some HugePages Facts/Features
Size of a HugePage The size of a single HugePage varies according to:
The actual size of the HugePage on a specific system can be checked by: $ grep Hugepagesize /proc/meminfo
9 Configuring Kernel Parameters
For the Oracle Database to work appropriately, we need
to ensure that the kernel parameters are set to values greater than or equal
to the minimum value shown below.
If the current value of any parameter is higher than the value listed in this table, then do not change the value of that parameter. To view the current value specified for these kernel parameters and to change them if necessary, enter commands similar to the following to view the current values of the kernel parameters:
If the value of any kernel parameter is different from
the recommended value, then using any text editor, create or edit the
/etc/sysctl.conf file, and add or edit lines similar to the following:
For more information, please visit Oracle
11g Documentation guide, found via the following link: The table in Document:144638.1 mentions the Unix and Linux kernel parameters that should be monitored and possibly increased after changes are made to the related init.ora parameter. Please check with your Operating System documentation for specific details on the parameter changes
10 Configuring Resource Limits For each installation software owner, check the resource limits for installation
To check resource limits:
$ ulimit -Sn
$ ulimit -Su
$ ulimit -Ss
If necessary, update the resource limits in the /etc/security/limits.conf configuration file for the installation owner. For example, add the following lines to the /etc/security/limits.conf file:
oracle
soft nproc 2047 When the limits.conf file is changed, these changes take effect immediately. However, if the grid or oracle users are logged in, then these changes do not take effect until you log these users out and log them back in. You must do this before you attempt to use these accounts to install.
11 CPU Utilization CPU consumption varies with the activities of the processes. During the peak workload, the DBAs and the SAs may see CPU utilization go up to 90%. You can monitor the CPU utilization with the following commands:
Sun Solaris: sar -u In addition of monitoring the CPU usage you should monitor the runqueue to determine if processes are waiting for an available processor. You can use "sar -q" to monitor the runqueue. To see how much CPU time is being used by each processor on a multiprocessor machine:
Sun Solaris: /usr/bin/mpstat To see the number of CPUs there are in the machine, and their status:
Sun Solaris: /usr/sbin/mpstat
12 I/O Utilization You should regularly monitor disk IO statistics by using utilities such as: "sar -d" or "iostat" Average service times of 50ms or less are reason for concern if it continues over a long time. One of the goals should be minimizing disk I/O by balancing the load on the disks. |
來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/21754115/viewspace-1723270/,如需轉載,請註明出處,否則將追究法律責任。
相關文章
- ASP.NET Web Page Resources OverviewASP.NETWebView
- angularjs resourcesAngularJS
- Flutter OverviewFlutterView
- angularJS articles and resourcesAngularJS
- dart class overviewDartView
- Stormstarter-OverviewORMView
- Overview of PartitioningView
- Overview of Database CheckpointsViewDatabase
- oracle function overviewOracleFunctionView
- Item Import OverviewImportView
- Overview of Extents(11)View
- Overview of Partitioned IndexesViewIndex
- Overview of Tablespaces (38)View
- Overview of Views (174)View
- Overview of Datafiles (62)View
- Overview of Segments (22)View
- 高通USB overviewView
- Android WebView Resources$NotFoundExceptionAndroidWebViewException
- Java 7 Try-With-ResourcesJava
- 關於gcs_resources:GC
- try-with-resources語法
- Overview of Availability in a CDBViewAI
- 2.4 Overview of Services in a CDBView
- 7-Overview-namesView
- 8-Overview-NamespacesViewnamespace
- 10-Overview-AnnotationsView
- [英] TensorFlow OverviewView
- Deadlock Overview and DiscussionView
- Overview of Data Blocks(二)ViewBloC
- Overview of Clusters (238)View
- Overview of Tables (154)View
- Overview of Dimensions (191)View
- Overview of Synonyms (193)View
- Overview of Indexes (194)ViewIndex
- Chapter 7 Resources in Plug-In(1)APT
- 2.6.2 Overview of Flashback PDB in a CDBView
- 2.2.7 Overview of PDB Lockdown ProfilesView
- An Overview of PostgreSQL & MySQL Cross ReplicationViewMySqlROS