ITPub博客

首页 > 数据库 > Oracle > ORA-27125: unable to create shared memory segment

ORA-27125: unable to create shared memory segment

原创 Oracle 作者:yangi1314 时间:2015-08-11 23:42:51 0 删除 编辑
环境:
OS:RHEL 6.5
DB:oracle 10.2.0.1

ORA
-27125: unable to create shared memory segment
Linux-x86_64 Error: 1: Operation not permitted

故障现象:
数据库无法正常启动
  1. SQL> startup
  2. ORA-27125: unable to create shared memory segment
  3. Linux-x86_64 Error: 1: Operation not permitted
故障分析:
发现这和linux的hugepage有关,操作系统的版本是RHEL 6.5,可能在创建共享段时需要用到hugepage,有权限限制。

解决办法:
查看oracle的用户组:
  1. [oracle@test ~]$ id
  2. uid=501(oracle) gid=502(dba) groups=502(dba) context=unconfined_u:unconfined_r:unconfined_t:s0-s0:c0.c1023
用root执行下面的命令,将dba组添加到系统内核中
  1. [root@test ~]# echo 502 > /proc/sys/vm/hugetlb_shm_group
再次启动数据库,启动正常。
  1. [root@test ~]# su - oracle
  2. [oracle@test ~]$ sqlplus / as sysdba
  3.  
  4. SQL*Plus: Release 10.2.0.1.0 - Production on Tue Aug 11 21:16:32 2015
  5.  
  6. Copyright (c) 1982, 2005, Oracle. All rights reserved.
  7.  
  8. Connected to an idle instance.
  9.  
  10. SQL> startup
  11. ORACLE instance started.
  12.  
  13. Total System Global Area 2097152000 bytes
  14. Fixed Size 2022080 bytes
  15. Variable Size 469763392 bytes
  16. Database Buffers 1610612736 bytes
  17. Redo Buffers 14753792 bytes
  18. Database mounted.
  19. Database opened.
上面的添加方法在重启操作系统后,此权限会消失,需要在/etc/sysctl.conf文件添加如下命令才能永久生效:
  1. vm.hugetlb_shm_group = 502
(502此数字为dba组的编号,可以使用id oracle命令查看)

来自 “ ITPUB博客 ” ,链接:https://blog.itpub.net/205377/viewspace-1768768/ ,如需转载,请注明出处,否则将追究法律责任。

请登录后发表评论 登录
全部评论

注册时间:2013-07-11

  • 博文量
    63
  • 访问量
    251487