如何解决composer执行命令提示已杀死问题
发表于:2025-01-24 作者:千家信息网编辑
千家信息网最后更新 2025年01月24日,本篇内容主要讲解"如何解决composer执行命令提示已杀死问题",感兴趣的朋友不妨来看看。本文介绍的方法操作简单快捷,实用性强。下面就让小编来带大家学习"如何解决composer执行命令提示已杀死问
千家信息网最后更新 2025年01月24日如何解决composer执行命令提示已杀死问题
本篇内容主要讲解"如何解决composer执行命令提示已杀死问题",感兴趣的朋友不妨来看看。本文介绍的方法操作简单快捷,实用性强。下面就让小编来带大家学习"如何解决composer执行命令提示已杀死问题"吧!
本文由composer教程栏目给大家介绍关于执行composer require 一会儿就提示"已杀死"问题,希望对需要的朋友有所帮助!
具体问题:
执行composer require 一会儿就提示"已杀死"
composer require voku/simple_html_dom -vvvReading ./composer.jsonLoading config file ./composer.jsonChecked CA file /etc/pki/tls/certs/ca-bundle.crt: validFailed to initialize global composer: Composer could not find the config file: /home/admin/.composer/composer.jsonTo initialize a project, please create a composer.json file as described in the https://getcomposer.org/ "Getting Started" sectionReading /home/wwwroot/vendor/composer/installed.jsonLoading plugin EasyWeChatComposer\PluginLoading plugin think\composer\PluginRunning 1.7.2 (2018-08-16 16:57:12) with PHP 7.1.18 on Linux / 2.6.32-696.16.1.el6.x86_64Downloading https://repo.packagist.org/packages.jsonWriting /home/admin/.composer/cache/repo/https---repo.packagist.org/packages.json into cacheReading /home/admin/.composer/cache/repo/https---repo.packagist.org/p-provider-2013.json from cacheReading /home/admin/.composer/cache/repo/https---repo.packagist.org/p-provider-2014.json from cacheReading /home/admin/.composer/cache/repo/https---repo.packagist.org/p-provider-2015.json from cacheReading /home/admin/.composer/cache/repo/https---repo.packagist.org/p-provider-2016.json from cacheReading /home/admin/.composer/cache/repo/https---repo.packagist.org/p-provider-2017.json from cacheReading /home/admin/.composer/cache/repo/https---repo.packagist.org/p-provider-2018.json from cacheReading /home/admin/.composer/cache/repo/https---repo.packagist.org/p-provider-2019-01.json from cacheReading /home/admin/.composer/cache/repo/https---repo.packagist.org/p-provider-2019-04.json from cacheReading /home/admin/.composer/cache/repo/https---repo.packagist.org/p-provider-2019-07.json from cacheReading /home/admin/.composer/cache/repo/https---repo.packagist.org/p-provider-2019-10.json from cacheReading /home/admin/.composer/cache/repo/https---repo.packagist.org/p-provider-archived.json from cacheDownloading http://repo.packagist.org/p/provider-latest%24502b160e3dcbe13f8c125df618d18632ebbad2402f1e07d96e00bf46c3da14ac.jsonWriting /home/admin/.composer/cache/repo/https---repo.packagist.org/p-provider-latest.json into cacheReading /home/admin/.composer/cache/repo/https---repo.packagist.org/provider-voku$simple-html-dom.json from cacheUsing version ^4.7 for voku/simple_html_dom./composer.json has been updatedReading ./composer.jsonLoading config file ./composer.jsonFailed to initialize global composer: Composer could not find the config file: /home/admin/.composer/composer.jsonTo initialize a project, please create a composer.json file as described in the https://getcomposer.org/ "Getting Started" sectionReading /home/wwwroot/vendor/composer/installed.jsonLoading plugin EasyWeChatComposer\Plugin_composer_tmp0Loading plugin think\composer\Plugin_composer_tmp1Reading ./composer.lockLoading composer repositories with package informationDownloading https://repo.packagist.org/packages.jsonWriting /home/admin/.composer/cache/repo/https---repo.packagist.org/packages.json into cacheUpdating dependencies (including require-dev)Reading /home/admin/.composer/cache/repo/https---repo.packagist.org/p-provider-2013.json from cacheReading /home/admin/.composer/cache/repo/https---repo.packagist.org/p-provider-2014.json from cacheReading /home/admin/.composer/cache/repo/https---repo.packagist.org/p-provider-2015.json from cacheReading /home/admin/.composer/cache/repo/https---repo.packagist.org/p-provider-2016.json from cacheReading /home/admin/.composer/cache/repo/https---repo.packagist.org/p-provider-2017.json from cacheReading /home/admin/.composer/cache/repo/https---repo.packagist.org/p-provider-2018.json from cacheReading /home/admin/.composer/cache/repo/https---repo.packagist.org/p-provider-2019-01.json from cacheReading /home/admin/.composer/cache/repo/https---repo.packagist.org/p-provider-2019-04.json from cacheReading /home/admin/.composer/cache/repo/https---repo.packagist.org/p-provider-2019-07.json from cacheReading /home/admin/.composer/cache/repo/https---repo.packagist.org/p-provider-2019-10.json from cacheReading /home/admin/.composer/cache/repo/https---repo.packagist.org/p-provider-archived.json from cacheReading /home/admin/.composer/cache/repo/https---repo.packagist.org/p-provider-latest.json from cacheReading /home/admin/.composer/cache/repo/https---repo.packagist.org/provider-adbario$php-dot-notation.json from cacheReading /home/admin/.composer/cache/repo/https---repo.packagist.org/provider-clagiordano$weblibs-configmanager.json from cacheReading /home/admin/.composer/cache/repo/https---repo.packagist.org/provider-danielstjules$stringy.json from cacheReading /home/admin/.composer/cache/repo/https---repo.packagist.org/provider-guzzlehttp$guzzle.json from cacheReading /home/admin/.composer/cache/repo/https---repo.packagist.org/provider-mtdowling$jmespath.php.json from cacheReading /home/admin/.composer/cache/repo/https---repo.packagist.org/provider-alibabacloud$client.json from cacheReading /home/admin/.composer/cache/repo/https---repo.packagist.org/provider-symfony$polyfill-mbstring.json from cacheReading /home/admin/.composer/cache/repo/https---repo.packagist.org/provider-guzzlehttp$psr7.json from cacheReading /home/admin/.composer/cache/repo/https---repo.packagist.org/provider-guzzlehttp$promises.json from cacheReading /home/admin/.composer/cache/repo/https---repo.packagist.org/provider-psr$http-message.json from cacheReading /home/admin/.composer/cache/repo/https---repo.packagist.org/provider-ralouphie$getallheaders.json from cacheReading /home/admin/.composer/cache/repo/https---repo.packagist.org/provider-aliyuncs$oss-sdk-php.json from cacheReading /home/admin/.composer/cache/repo/https---repo.packagist.org/provider-doctrine$cache.json from cacheReading /home/admin/.composer/cache/repo/https---repo.packagist.org/provider-easywechat-composer$easywechat-composer.json from cacheReading /home/admin/.composer/cache/repo/https---repo.packagist.org/provider-symfony$options-resolver.json from cache
解决办法:
一般是内存不足导致进程被杀死。
没办法增大物理内存的话可以考虑扩容 swap 分区。
参考如下:
composer 安装或者更新时报错killed ,因为当前内存不足。
free -mmkdir -p /var/_swap_cd /var/_swap_#Here, 1M * 2000 ~= 2GB of swap memorydd if=/dev/zero of=swapfile bs=1M count=2000mkswap swapfileswapon swapfileecho "/var/_swap_/swapfile none swap sw 0 0" >> /etc/fstab#cat /proc/meminfofree -m
到此,相信大家对"如何解决composer执行命令提示已杀死问题"有了更深的了解,不妨来实际操作一番吧!这里是网站,更多相关内容可以进入相关频道进行查询,关注我们,继续学习!
问题
提示
命令
内存
内容
办法
朋友
学习
实用
更深
兴趣
实用性
实际
操作简单
教程
方法
时报
更多
栏目
物理
数据库的安全要保护哪些东西
数据库安全各自的含义是什么
生产安全数据库录入
数据库的安全性及管理
数据库安全策略包含哪些
海淀数据库安全审计系统
建立农村房屋安全信息数据库
易用的数据库客户端支持安全管理
连接数据库失败ssl安全错误
数据库的锁怎样保障安全
软件开发类公司资质证书
互联网软件开发推广
采购申请数据库设计入门经典
xss哪个服务器的游戏便宜
网翊软件开发公司
徐工集团软件开发师怎么样
亚信科技跳槽到互联网公司
python做数据库
电信itv服务器地址
复杂网络技术现状
金山区智能软件开发处理方法
天津 软件开发服务招投标
网络技术对艺术专业的影响
大数据中的关系型数据库
MPP数据库 行式 列式
今年网络安全宣传主题
数据库中实体与记录的描述
添加web服务器
云南软件开发公司排名前十强
魔兽世界九城有哪个服务器
复杂网络技术现状
服务器连接磁盘阵列
软件开发转做产品
市场网络安全培训班
外包软件开发的洽谈流程
如何进神奇宝贝服务器
未来学什么网络技术
超群软件开发
陕西网络安全应急
最好的软件开发环境