oracle和OS内核参数匹配问题(2)

2019-09-01 09:37

ORA-27146 \

[NOTE:115235.1] Resolving ORA-7279 or ORA-27146 errors when starting instance

If you want a very specific explanation of causes for the above errors, refer to: [NOTE:15566.1] TECH Unix Semaphores and Shared Memory Explained

However, while their exact cause varies, all these error messages indicate that your init.ora is configured to grab more semaphores than the OS has available.

If you configure your OS as indicated in the following sections, you will not get any of the errors indicated above.

成功配置信号量的步骤

The Basic Steps to Semaphore Success:

---------------------------------------------------------------------------------- 1. Understand The Basic Concept Behind Semaphores

2. Understand How Many Semaphores Your Oracle Instance(s) Will Attempt to Grab From The Operating System.

3. Configure Your OS Kernel To Accomodate all Your Oracle Instance(s) And also Allow For Future Growth.

[STEP 1] How are semaphores released by the OS for use by an application? ----------------------------------------------------------------------------------

There are 3 OS kernel parameters that work together to limit semaphore allocation. When an application requests semaphores, the OS releases them in 'sets'. Illustrated here as 2 sets: +---+ +---+

| | | | | | | | +---+ +---+

Controlled by SEMMNI -->OS limit on the Number of Identifiers or sets. Each set contains a tunable number of individual semaphores. Illustrated here as 2 semaphores per semaphore set: +---+ +---+ | S | | S | S | | S | +---+ +---+

Controlled by SEMMSL -->The number of semaphores in an identifier or set.(Semaphore List)

Ultimately however, the OS can limit the total number of semaphores available from the OS. Controlled by:

SEMMNS --> The total Number of Semaphores allowed system wide.

For instance: Let's say SEMMNI = 100000000 and SEMMSL= 100000000 while SEMMNS=10

Even though SEMMNI is 100000000 and SEMMSL is 100000000, the max # of semaphores available on your system will only be 10, because SEMMNS is set to 10.

Inversely: Let's say SEMMNI = 10 and SEMMSL = 10 while SEMMNS=

100000000000000000000000000 Because SEMMNI is 10 and SEMMSL is 10, the max # of semaphores avail on your system will only be 100 or (10 X 10), despite what SEMMNS is set too.

THIS NOTION CAN BE SUMMARIZED BY THE FOLLOWING STATEMENT:

The max # of semaphores that can be allocated on a system will be the lesser of:

(semmsl * semmni) or semmns.

On HP: semmsl is hardcoded to 500. [NOTE:74367.1] HP-UX SEMMSL Kernel Parameter

SEMMNI, SEMMSL & SEMMNS are the basic names for OS semaphore kernel parameters,the full name may vary depending on your OS. Consult your OS specific Oracle Install guide.

[NOTE:116638.1] Understanding and Obtaining Oracle Documentation)

[STEP 2] How many semaphores will my Oracle instance(s) require? ---------------------------------------------------------------------------------- With Oracle7: The number of semaphores required by an instance is equal to the setting the 'processes' parameter in the init.ora for the instance.

With Oracle8, Oracle8i and Oracle9i: The number of semaphores required by an instance is equal to 2 times the setting of the 'processes' parameter in the init.ora for the instance. Keep in mind, however, that Oracle only momentarily grabs 2 X 'processes' then releases half at instance startup. This measure was apparently introduced to ensure Oracle could not exhaust a system of semaphores.

Oracle may also grab a couple of additional semaphores per instance for internal use.

[STEP 3] Configure your OS kernel to accomodate all your Oracle instances. ----------------------------------------------------------------------------------

There seems to be some confusion of how to deal with lack of semaphore errors. The popular theory being that if Oracle cannot find enough semaphores on a system, increase semmns. This is not always the case, as illustrated in [STEP 1]. Once you have determined your semaphore requirements for Oracle and

compensated for future growth, contact your System Administrator or OS vendor for assistance in modifying the OS kernel.

What should I set 'semmni', 'semmsl' & 'semmns' to?

----------------------------------------------------------------------------------

Oracle Support typically does not recommend specific values for semaphore kernel parameters. Instead, use the information provided in this document to set the parameters to values that are appropriate for your operating environment.

For more info please look at the following note : [NOTE:15654.1] TECH: Calculating Oracle's SEMAPHORE Requirements

快速解决信号量问题

Quick fix for resolving lack of semaphore errors:

---------------------------------------------------------------------------------- Reduce the number of semaphores Oracle requires from the OS.

The first and most simple fix is to modify the init.ora to reduce the

number of semaphores or the amount of shared memory Oracle will try to grab at instance startup.

Keep in mind, with Oracle8, we grab 2 X 'processes' then release half. This measure was apparently introduced to ensure Oracle could not exhaust a system of semaphores.

如何查找OS配置的信号量

How can I find out how my OS kernel is configured for semaphores? ----------------------------------------------------------------------------------

The files that are used to tune kernel parameters varies depending on your Operating System. Consult your system administrator or OS vendor, because viewing the system file may not show accurate information about the runtime values.

However, an important point to remember is that if a typographical error is made while editing these files, the OS will defer to a default value which is usually to low to accomodate Oracle. So it's a good idea to check runtime values with utilities like '/etc/sysdef'.

I've tuned my OS kernel parameters, but I am still having semaphore problems.... ---------------------------------------------------------------------------------- 常见问题!!

This may mean that you made a typographical error or did not rebuild your Operating System kernel correctly(if a typographical error is made while editing these files, the OS will defer to a default value which is usually to low to accomodate Oracle).

On Solaris, check current OS kernel values with this command: > /etc/sysdef|grep -i semm

If these values do not reflect what you put in your 'system' file, you likely made a typographically error.

On HP, be sure the OS kernel was rebuilt correctly and that the OS was booted off the correct file. Contact your System Administrator or HP for more information. 在Linux系统上

进入目录/proc/sys/kernel;用cat命令或more命令查看semaphore当前参数的值: cat sem

命令运行后将会出现如下的结果:


oracle和OS内核参数匹配问题(2).doc 将本文的Word文档下载到电脑 下载失败或者文档不完整,请联系客服人员解决!

下一篇:2000-2016年中国海洋大学612生物化学A考研真题及答案解析 汇编

相关阅读
本类排行
× 注册会员免费下载(下载后可以自由复制和排版)

马上注册会员

注:下载文档有可能“只有目录或者内容不全”等情况,请下载之前注意辨别,如果您已付费且无法下载或内容有问题,请联系我们协助你处理。
微信: QQ: