gpt4 book ai didi

java - 构建 spark 时出现内存问题

转载 作者:行者123 更新时间:2023-12-03 22:54:38 24 4
gpt4 key购买 nike

我已经在 Ubuntu 12.o4 客户端操作系统上安装了 Scala、sbt 和 hadoop 1.0.3。引用链接 - http://docs.sigmoidanalytics.com/index.php/How_to_Install_Spark_on_Ubuntu-12.04 ,我尝试构建 Spark 并遇到与保留空间相关的错误。

这是我要运行的:

hduser@vignesh-desktop:/usr/local/spark-1.1.0$ SPARK_HADOOP_VERSION=1.1.0 sbt/sbt assembly

输出错误如下:

Using /usr/lib/jvm/java-6-openjdk-i386/ as default JAVA_HOME.
Note, this will be overridden by -java-home if it is set.
Error occurred during initialization of VM
Could not reserve enough space for object heap
Could not create the Java virtual machine.

最佳答案

我通过使用 sbt 命令传递 mem 属性来解决这个问题,如下所示(对于 4 GB RAM 系统)

SPARK_HADOOP_VERSION=1.1.0 sbt/sbt assembly -mem 1024

关于java - 构建 spark 时出现内存问题,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/26703921/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com