Error occurred during initialization of VM Could not reserve enough space for 2097152KB object heap
ionic build Android后的报错问题
ionic 升级了splashscreen和statusbar的插件后,执行ionic build android会一直报打包错误。原因是过低的Android-platform版本不支持新的 splashscreen和statusbar插件
解决 办法是: ionic platform add android@6.1.2 添加Android平台前加上版本号就行
然而,又有了新的问题:Error occurred during initialization of VM Could not reserve enough space for 2097152KB object heap

1、这时候报虚拟内存不足-----------因为我的电脑是32位的Win7 ,经测试,64位的没有这个错误。一般报这个内存不足,java的做法就是去eclipse的option修改jre的参数值就行了。
2、但ionic的做法有点不一样:在 ionic platform add android@6.1.2 后,在 platforms\android\cordova\lib\builders 的文件夹下会有一个文件 GradleBuilder.js 。
3、用记事本打开这个文件,在内容中找到 args.push('-Dorg.gradle.jvmargs=-Xmx2048m');把这个2048m调小,具体看你的机器,我调的为256m;
4、如果没有找到 args.push('-Dorg.gradle.jvmargs=-Xmx258m'); 那么在 GradleBuilder.prototype.getArgs 的函数里面的return前加上这句代码就行。
5、最后执行ionic build android就可以跟之前一样的打包了
Error occurred during initialization of VM Could not reserve enough space for 2097152KB object heap的更多相关文章
- Error occurred during initialization of VM Could not reserve enough space for object heap
Error occurred during initialization of VM Could not reserve enough space for object heap Java虚拟机(JV ...
- fisheye Error occurred during initialization of VM Could not reserve enough space for object heap 问题解决!
参考文章:https://answers.atlassian.com/questions/9397/not-enough-heap-space-to-run-fisheye fisheye下载好了之后 ...
- Logstash测试的时候,报Error occurred during initialization of VM,Could not reserve enough space for object heap
今天配置Logstash的时候,启动输入logstash ‐e 'input { stdin { } } output { stdout {} }'就开始报错了,Error occurred duri ...
- Error occurred during initialization of VM Could not reserve enough space fo
通过es的elasticsearch.bat 启动.发现错误:Error occurred during initialization of VM Could not reserve enough s ...
- android Error occurred during initialization of VM Could not reserve enough space for object heap Could not create the Java virtual machine.
在当前工程目录中 gradle.properties 添加org.gradle.jvmargs=-XX\:MaxHeapSize\=256m -Xmx256m http://stackoverflow ...
- 问题3-Error occurred during initialization of VM Could not reserve enough space for object heap
初步断定是内存方面的问题 于是决定修改配置文件 D:\study\eclipse\eclipse\eclipse.ini -startupplugins/org.eclipse.equinox.lau ...
- jboss服务启动失败报:Error occurred during initialization of VM
今天下午突然间公司的GTV管理平台上不去了 访问确实,提示找不到页面 登录终端查看服务进程. ps -ef | grep jboss 发现没有这个进程.怎么办,启动被. 输入nohup /home/c ...
- 异常 - 虚拟机初始化错误 - Error occurred during initialization of VM
目录 1 环境配置信息 1.1 服务器配置信息 1.2 Tomcat启动参数 2 问题描述 3 问题解决 4 关于vm.overcommit_memory参数 4.1 vm.overcommit_me ...
- Android studio Error occurred during initialization of VM
Unable to start the daemon process. This problem might be caused by incorrect configuration of the d ...
随机推荐
- FFmpeg开发实战(五):FFmpeg 抽取音视频的视频数据
如何使用FFmpeg抽取音视频的视频数据,代码如下: // FFmpegTest.cpp : 此文件包含 "main" 函数.程序执行将在此处开始并结束. // #include ...
- IP地址个数的计算原理
IP注释: IP地址(Internet Protocol Address),缩写为IP Adress,是一种在Internet上的给主机统一编址的地址格式,也称为网络协议(IP协议)地址. 它为互联网 ...
- Django中使用geetest实现滑动验证
下载第三方模块 导入模块social-auth-app-django 和geetest 提前去官网下载gt.js或者引入http://static.geetest.com/static/tools/g ...
- vue框架中的Axios封装
function axios(options) { let promise = new Promise((resolve, reject) => { var xhr ...
- mysql-proxy负载均衡
1.下载mysql-proxy包 2.解压并启动 tar zxvf mysql-proxy....tar mv mysql-proxy... /user/local/proxy cd /usr/loc ...
- 【Redis篇】Redis集群安装与初始
一.前述 本文将单台节点不同端口模拟集群方式. 二.具体搭建 前提是安装好redis具体可参考http://www.cnblogs.com/LHWorldBlog/p/8463269.html 1 ...
- 关闭mac的SIP + 一定有用的删除mac自带ABC的方法
如果你被这ABC输入法弄得很是不开心.那就看看吧!!!亲测一定有效. mac 关闭系统完整性保护 SIP(System Integrity Protection) 重启系统 按住 command+R ...
- Spring Boot 2.0 教程 | 配置 Undertow 容器
欢迎关注个人微信公众号: 小哈学Java, 文末分享阿里 P8 资深架构师吐血总结的 <Java 核心知识整理&面试.pdf>资源链接!! 文章首发于个人网站 https://ww ...
- .NET Core实战项目之CMS 第六章 入门篇-Vue的快速入门及其使用
写在前面 上面文章我给大家介绍了Dapper这个ORM框架的简单使用,大伙会用了嘛!本来今天这篇文章是要讲Vue的快速入门的,原因是想在后面的文章中使用Vue进行这个CMS系统的后台管理界面的实现.但 ...
- Unity 点乘&叉乘 应用实例
一 前言 1.概述 主要概述了点乘,叉乘的实用例子,没有讲述什么原理性的,偏向应用层.点乘叉乘数学原理性的东西比较“难记”,网上很多.实用举例,网上算是比较少吧.故,来总结一番. 2.可以解决的问题 ...