最新下载
热门教程
- 1
- 2
- 3
- 4
- 5
- 6
- 7
- 8
- 9
- 10
Composer PHP Fatal error:Allowed memory size of
时间:2022-06-24 23:18:53 编辑:袖梨 来源:一聚教程网
今天在运行composer update时遇到的,详细的错误消息如下:
$ composer update
Loading composer repositories with package information
Updating dependencies (including require-dev)
PHP Fatal error: Allowed memory size of 536870912 bytes exhausted
(tried to allocate 32 bytes) in phar:///usr/local/Cellar/composer/
1.0.0-alpha8/libexec/composer.phar/src/Composer/DependencyResolver/
Rule.php on line 62
Fatal error: Allowed memory size of 536870912 bytes exhausted
(tried to allocate 32 bytes) in phar:///usr/local/Cellar/composer/
1.0.0-alpha8/libexec/composer.phar/src/Composer/DependencyResolver/
Rule.php on line 62
一直以为是网络原因,最近连接国外的网络不是很稳定,后来根据报错的信息Allowed memory size of 536870912 bytes exhausted提示知道可能是内存分配不够,大家知道在PHP的配置文件php.ini中有限制脚本运行内存的设置memory_limit把这个值调大一些就可以解决这个问题了。
memory_limit = 1G
当然大家也许不喜欢随随便便的改动配置文件php.ini,在帖子《Composer update runs out of memory #1898》Dynom给出了个临时的解决办法:
php -dmemory_limit=1G composer.phar update
相关文章
- 归龙潮异域疾行怎么玩 10-01
- 光遇破晓季集体复刻怎么玩 10-01
- 敲棺盖修改器在哪下载 10-01
- 想要确保云网稳定运行离不开塔台管制员还是云网智能运维员的守护 10-01
- 蚂蚁庄园10月1日答案最新 10-01
- 支付宝蚂蚁森林神奇海洋9月30日答案 10-01