当前位置:  编程技术>php

php 启动时报错的解决方法

    来源: 互联网  发布时间:2014-10-08

    本文导语:  php 启动报错:   代码示例: [root@abc lnmp]# service php-fpm start Starting php-fpm eAccelerator: Could not allocate 67108864 bytes, the maximum size the kernel allows is 33554432 bytes. Lower the amount of memory request or increase the limit in /proc/sys/kernel/shmmax. [04-Dec-2013...

php 启动报错:
 

代码示例:
[root@abc lnmp]# service php-fpm start
Starting php-fpm eAccelerator: Could not allocate 67108864 bytes, the maximum size the kernel allows is 33554432 bytes. Lower the amount of memory request or increase the limit in /proc/sys/kernel/shmmax.
[04-Dec-2013 19:06:44] NOTICE: PHP message: PHP Warning: [eAccelerator] Can not create shared memory area in Unknown on line 0
[04-Dec-2013 19:06:44] NOTICE: PHP message: PHP Fatal error: Unable to start eAccelerator module in Unknown on line 0
failed

查看linux系统中的配置文件 sysctl.conf:
 

代码示例:
[root@abc lnmp]# vi /etc/sysctl.conf
# Kernel sysctl configuration file for Red Hat Linux
#
# For binary values, 0 is disabled, 1 is enabled. See sysctl(8) and
# sysctl.conf(5) for more details.
# Controls IP packet forwarding
net.ipv4.ip_forward = 0
# Controls source route verification
net.ipv4.conf.default.rp_filter = 1
# Do not accept source routing
net.ipv4.conf.default.accept_source_route = 0
# Controls the System Request debugging functionality of the kernel
kernel.sysrq = 0
# Controls whether core dumps will append the PID to the core filename.
# Useful for debugging multi-threaded applications.
kernel.core_uses_pid = 1
# Controls the use of TCP syncookies
net.ipv4.tcp_syncookies = 1
# Disable netfilter on bridges.
net.bridge.bridge-nf-call-ip6tables = 0
net.bridge.bridge-nf-call-iptables = 0
net.bridge.bridge-nf-call-arptables = 0
fs.file-max=65535
net.ipv4.tcp_max_syn_backlog = 65536
net.core.netdev_max_backlog = 32768
net.core.somaxconn = 32768
net.core.wmem_default = 8388608
net.core.rmem_default = 8388608
net.core.rmem_max = 16777216
net.core.wmem_max = 16777216
net.ipv4.tcp_timestamps = 0
net.ipv4.tcp_synack_retries = 2
net.ipv4.tcp_syn_retries = 2
net.ipv4.tcp_tw_recycle = 1
#net.ipv4.tcp_tw_len = 1
net.ipv4.tcp_tw_reuse = 1
net.ipv4.tcp_mem = 94500000 915000000 927000000
net.ipv4.tcp_max_orphans = 3276800
# TIME_OUT后等待时间
#net.ipv4.tcp_fin_timeout = 30
#net.ipv4.tcp_keepalive_time = 120
net.ipv4.ip_local_port_range = 1024 65535
kernel.shmmax = 128000000

加上最后一句话 kernel.shmmax = 128000000
然后应用:sysctl -p
 

代码示例:
[root@abc lnmp]# service php-fpm start
Starting php-fpm done
[root@abc lnmp]# /usr/bin/memcachedstart

    
 
 

您可能感兴趣的文章:

  • PHP执行Curl时报错提示CURL ERROR: Recv failure: Connection reset by peer的解决方法
  • php 启动时报错的简单解决方法
  • php编译时报错,急!急!急!
  • 原来在ubuntu装个了个eclipse,可以正常启动,后来又下了个支持php的eclipse...发现php的eclipse无法启动
  • linux下如何启动php、mylql等?如何卸载apache、php、mysql?
  • 数据库 iis7站长之家
  • PHP启动报错 php提示SNMP错误的解决方法
  • Linux下php5.4启动脚本
  • 我的apache启动有问题.apache+mysql+php运行时也有问题,怎么回事,请各位帮帮忙
  • 以前用PHP+MYSQL+AHACHE已配置好,现在要运行JSP,整合TOMCAT和APACHE后,APACHE怎么都不启动了?问题出在那里呢??
  • 在PHP中运行Linux命令并启动SSH服务的例子
  • php 启动报错如何解决
  • php-fpm启动参数配置详解
  • php-fpm 启动参数配置详解
  •  
    本站(WWW.)旨在分享和传播互联网科技相关的资讯和技术,将尽最大努力为读者提供更好的信息聚合和浏览方式。
    本站(WWW.)站内文章除注明原创外,均为转载、整理或搜集自网络。欢迎任何形式的转载,转载请注明出处。












  • 相关文章推荐
  • 修改配置真正解决php文件上传大小限制问题(nginx+php)
  • Starting PHP with FastCGI ??? 请熟悉PHP和LINUX的高手帮忙解决这个问题,谢谢!!!
  • 修改配置真正解决php文件上传大小限制问题(apache+php)
  • 安装好的Redhat Linux 8.0,带Apache和php支持,安装上Mysql后,运行正常,但检测提示php不支持Mysql,如何解决?
  • php网页标题中文乱码如何解决
  • 开源PHP电商解决方案 Sylius
  • PHP错误Parse error: syntax error, unexpected end of file in test.php on line 12解决方法
  • iis加载不到php.ini的解决方法
  • php出现Class 'XsltProcessor' not found问题的解决方法
  • PHP上传文件过大$_FILES为空的解决方法
  • php绘图中显示不出图片的原因及解决
  • PHP文件型缓存解决方案 Secache
  • php4.1.2版本更新问题,解决的给100分
  • php中$美元符号与Zen Coding冲突问题解决方法分享
  • php网页标题中文乱码的有效解决方法
  • Python和php通信乱码问题解决方法
  • PHP上传文件大小限制二种解决方法
  • php syntax error, unexpected $end 错误怎么解决
  • php的webservice的wsdl的XML无法显示问题的解决方法
  • 解决php json_encode中文转码、乱码问题
  • php pdo编码乱码问题的解决方法
  • PHP 5.4.19 和 PHP 5.5.3 发布及下载地址
  • IIS7配置PHP图解(IIS7+PHP_5.2.17/PHP_5.3.5)
  • PHP去除html标签,php标记及css样式代码参考
  • php输入流php://input使用示例(php发送图片流到服务器)
  • PHP 'ext/soap/php_xml.c'不完整修复存在多个任意文件泄露漏洞
  • PHP转换器 HipHop for PHP
  • php通过socket_bind()设置IP地址代码示例
  • PHP 框架 Pop php
  • php安装完成后如何添加mysql扩展
  • PHP的JavaScript框架 PHP.JS


  • 站内导航:


    特别声明:169IT网站部分信息来自互联网,如果侵犯您的权利,请及时告知,本站将立即删除!

    ©2012-2021,,E-mail:www_#163.com(请将#改为@)

    浙ICP备11055608号-3