Android Studio 莫名其妙的故障弄了一个下午了求大神打救

问题描述:

Error:Unable to start the daemon process.
This problem might be caused by incorrect configuration of the daemon.
For example, an unrecognized jvm option is used.
Please refer to the user guide chapter on the daemon at https://docs.gradle.org/3.3/userguide/gradle_daemon.html

Please read the following process output to find out more:

附上gradle.properties:

Project-wide Gradle settings.

IDE (e.g. Android Studio) users:

Gradle settings configured through the IDE will override

any settings specified in this file.

For more details on how to configure your build environment visit

http://www.gradle.org/docs/current/userguide/build_environment.html

Specifies the JVM arguments used for the daemon process.

The setting is particularly useful for tweaking memory settings.

org.gradle.jvmargs=-Xmx1536m

When configured, Gradle will run in incubating parallel mode.

This option should only be used with decoupled projects. More details, visit

http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects

org.gradle.parallel=true

1.改org.gradle.jvmargs=-Xmx512m;
2.删除.gradle;
3.降低jdk版本或者gradle版本;
4.重装android studio;
5.关了防火墙和卸载所有杀毒软件;
然而上面的方法一点鸟用都没有,相信我。
这个是因为防火墙拦截了,这种情况要关防火墙和卸载杀毒软件,但还是有可以会拦截,所以最好的方法是重装系统。(我自己折腾了两天,最后用了两个小时重装系统好了)

从字面意思理解是虚拟机配置不正确
org.gradle.jvmargs=-Xmx1536m
你的电脑是多大内存的,
虚拟机内存调小一点试试1024m或其他,
没遇到过这种错误,不保证一定好用。

org.gradle.jvmargs=-Xmx1536m改改试试,关闭再打开

android studio 设置里可以修改默认的内存,调大一点试试。

这个是因为防火墙拦截了,这种情况要关防火墙和卸载杀毒软件,但还是有可以会拦截,所以最好的方法是重装系统。