作曲家更新显示此错误:VirtualAlloc()失败:[0x00000008] [英] Composer update show this error: VirtualAlloc() failed: [0x00000008]

查看:149
本文介绍了作曲家更新显示此错误:VirtualAlloc()失败:[0x00000008]的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

作曲家昨天可以找到,但是今天我尝试安装后:
作曲家需要--prefer-dist himiklab / yii2-recaptcha-widget *

Composer worked find yesterday, but today after I trying install: composer require --prefer-dist "himiklab/yii2-recaptcha-widget" "*"

运行composer update命令时显示错误:

While run composer update command it show me error:

VirtualAlloc()失败:[0x00000008]
VirtualAlloc()失败:[0x00000008] PHP致命错误:第84行上的phar:// C:/ProgramData/ComposerSetup/bin/composer.phar/src/Composer/DependencyResolver/RuleSet.php内存不足(已分配956301312)(试图分配201326600字节)

VirtualAlloc() failed: [0x00000008] VirtualAlloc() failed: [0x00000008] PHP Fatal error: Out of memory (allocated 956301312) (tried to allocate 201326600 bytes) in phar://C:/ProgramData/ComposerSetup/bin/composer.phar/src/Composer/DependencyResolver/RuleSet.php on line 84

严重错误:phar:// C:/ProgramData/ComposerSetup/bin/composer.phar/src/Composer/中的内存不足(已分配956301312)(试图分配201326600字节)第84行上的DependencyResolver / RuleSet.php

Fatal error: Out of memory (allocated 956301312) (tried to allocate 201326600 bytes) in phar://C:/ProgramData/ComposerSetup/bin/composer.phar/src/Composer/DependencyResolver/RuleSet.php on line 84

我尝试在其他项目上更新composer,效果很好。经过一些研究后,我在php.ini文件中增加了memory_limit:4096M(也为-1)。然后我尝试在Computer-> Properties中增加虚拟内存,但仍然显示错误。

I try update composer on my other projects, it is worked fine. After some researching I increased memory_limit: 4096M(also -1) in php.ini file. Then I tried to increase virtual memory in Computer->Properties, but still show error.

我尝试运行下一个命令:
composer update -vvv-个人资料,生成附有图片的图片
编辑器错误

I try to run next command: composer update -vvv --profile, result in attached image Composer error

任何帮助将不胜感激。

推荐答案

您可能正在使用32位PHP。即使您将memory_limit更改为-1(无限制),该版本也无法为Composer分配足够的内存。

You are probably using 32bit PHP. This version cannot allocate enough memory for composer even if you change the memory_limit to -1 (unlimited).

请在Composer中使用64位PHP摆脱这些内存问题。

Please use 64 bit PHP with the Composer to get rid of these memory problems.

这篇关于作曲家更新显示此错误:VirtualAlloc()失败:[0x00000008]的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆