FreeBSD – shmget() failed: Cannot allocate memory

eAccelerator 설치 후 php 버전을 보려던 중 shmget() failed 메세지를 보고 구글링하다가 찾았습니다.
공유 메모리 세그먼트가 부족해서 그런듯.. 늘려주니 해결 되네요.

[root@yongbok ~]# php -v
shmget() failed: Cannot allocate memory
Failed to start up concurrent users module!
PHP 5.2.14 with Suhosin-Patch 0.9.7 (cli) (built: Nov 12 2010 22:21:09)
Copyright (c) 1997-2009 The PHP Group
Zend Engine v2.2.0, Copyright (c) 1998-2010 Zend Technologies
with eAccelerator v0.9.6.1, Copyright (c) 2004-2010 eAccelerator, by eAccelerator
with the ionCube PHP Loader v4.0.1, Copyright (c) 2002-2010, by ionCube Ltd., and
with Zend Optimizer v3.3.9, Copyright (c) 1998-2009, by Zend Technologies
with XCache v2.0.0-dev, Copyright (c) 2005-2009, by mOo

공유 메모리 세그먼트 재설정

[root@yongbok ~]# sysctl kern.ipc.shmall=16384
kern.ipc.shmall: 8192 -> 16384

부팅시 자동 설정 등록

[root@yongbok ~]# echo ‘kern.ipc.shmall=16384′ >> /etc/sysctl.conf

참고
http://forums.freebsd.org/showthread.php?t=7624

Comments

comments