草庐IT

hadoop - Cloudera Docker 镜像......一切都出错了

coder 2024-01-06 原文

我正在运行 16 GB 的 Macbook pro 和 El Capitan 操作系统。我使用

安装了 cloudera docker 镜像
docker pull cloudera/quickstart:latest
docker run --privileged=true --hostname=quickstart.cloudera -t -i 9f3ab06c7554 /usr/bin/docker-quickstart

图像启动正常,我可以看到大多数服务正在启动

Started Hadoop historyserver:                              [  OK  ]
starting nodemanager, logging to /var/log/hadoop-yarn/yarn-yarn-nodemanager-quickstart.cloudera.out
Started Hadoop nodemanager:                                [  OK  ]
starting resourcemanager, logging to /var/log/hadoop-yarn/yarn-yarn-resourcemanager-quickstart.cloudera.out
Started Hadoop resourcemanager:                            [  OK  ]
starting master, logging to /var/log/hbase/hbase-hbase-master-quickstart.cloudera.out
Started HBase master daemon (hbase-master):                [  OK  ]
starting rest, logging to /var/log/hbase/hbase-hbase-rest-quickstart.cloudera.out
Started HBase rest daemon (hbase-rest):                    [  OK  ]
starting thrift, logging to /var/log/hbase/hbase-hbase-thrift-quickstart.cloudera.out
Started HBase thrift daemon (hbase-thrift):                [  OK  ]
Starting Hive Metastore (hive-metastore):                  [  OK  ]
Started Hive Server2 (hive-server2):                       [  OK  ]
Starting Sqoop Server:                                     [  OK  ]
Sqoop home directory: /usr/lib/sqoop2

还有一些失败

Failure to start Spark history-server (spark-history-server[FAILED]n value: 1
Starting Hadoop HBase regionserver daemon: starting regionserver, logging to /var/log/hbase/hbase-hbase-regionserver-quickstart.cloudera.out
hbase-regionserver.
Starting hue:                                              [FAILED]

但是一旦启动完成,如果我尝试运行任何东西都会失败

例如尝试运行 spark-shell

[root@quickstart /]# spark-shell
Java HotSpot(TM) 64-Bit Server VM warning: INFO: os::commit_memory(0x00000000b0000000, 357892096, 0) failed; error='Cannot allocate memory' (errno=12)
#
# There is insufficient memory for the Java Runtime Environment to continue.
# Native memory allocation (malloc) failed to allocate 357892096 bytes for committing reserved memory.
# An error report file with more information is saved as:
# //hs_err_pid3113.log

或尝试运行配置单元 shell

[root@quickstart /]# hive
Unable to determine Hadoop version information.
'hadoop version' returned:
Hadoop 2.6.0-cdh5.5.0 Subversion http://github.com/cloudera/hadoop -r fd21232cef7b8c1f536965897ce20f50b83ee7b2 Compiled by jenkins on 2015-11-09T20:37Z Compiled with protoc 2.5.0 From source with checksum 98e07176d1787150a6a9c087627562c This command was run using /usr/jars/hadoop-common-2.6.0-cdh5.5.0.jar
[root@quickstart /]#

我的问题是我该怎么做才能成功运行 spark-shell 和 hive shell?

最佳答案

由于您是在 Mac 上运行 Docker,因此 Docker 在 VirtualBox 下运行,而不是直接使用 Mac 的内存。 (在 Windows 中也会发生同样的事情)。

您可能不会在 Linux 主机上遇到这些错误,因为那里没有虚拟化 Docker。

我认为 Cloudera quickstart vm 建议 8Gb 内存来运行所有服务,而 docker vm 只有 512Mb。

解决方案是停止 docker-machine 实例,打开 VirtualBox,并将“默认”VM 的内存大小增加到必要的数量。

关于hadoop - Cloudera Docker 镜像......一切都出错了,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/34384396/

有关hadoop - Cloudera Docker 镜像......一切都出错了的更多相关文章

  1. ruby-on-rails - 无法在centos上安装therubyracer(V8和GCC出错) - 2

    我正在尝试在我的centos服务器上安装therubyracer,但遇到了麻烦。$geminstalltherubyracerBuildingnativeextensions.Thiscouldtakeawhile...ERROR:Errorinstallingtherubyracer:ERROR:Failedtobuildgemnativeextension./usr/local/rvm/rubies/ruby-1.9.3-p125/bin/rubyextconf.rbcheckingformain()in-lpthread...yescheckingforv8.h...no***e

  2. ruby - 安装libv8(3.11.8.13)出错,Bundler无法继续 - 2

    运行bundleinstall后出现此错误:Gem::Package::FormatError:nometadatafoundin/Users/jeanosorio/.rvm/gems/ruby-1.9.3-p286/cache/libv8-3.11.8.13-x86_64-darwin-12.gemAnerroroccurredwhileinstallinglibv8(3.11.8.13),andBundlercannotcontinue.Makesurethat`geminstalllibv8-v'3.11.8.13'`succeedsbeforebundling.我试试gemin

  3. hadoop安装之保姆级教程(二)之YARN的配置 - 2

    1.1.1 YARN的介绍 为克服Hadoop1.0中HDFS和MapReduce存在的各种问题⽽提出的,针对Hadoop1.0中的MapReduce在扩展性和多框架⽀持⽅⾯的不⾜,提出了全新的资源管理框架YARN. ApacheYARN(YetanotherResourceNegotiator的缩写)是Hadoop集群的资源管理系统,负责为计算程序提供服务器计算资源,相当于⼀个分布式的操作系统平台,⽽MapReduce等计算程序则相当于运⾏于操作系统之上的应⽤程序。 YARN被引⼊Hadoop2,最初是为了改善MapReduce的实现,但是因为具有⾜够的通⽤性,同样可以⽀持其他的分布式计算模

  4. ruby - 为什么在 Ruby 中一切都是 Class 的实例? - 2

    这个问题在这里已经有了答案:Rubymetaclassconfusion(4个答案)关闭7年前。我对Ruby对象模型不太了解。首先,Ruby中的一切都是Class的实例吗??这些都产生true:pObject.instance_of?(Class)pClass.instance_of?(Class)pModule.instance_of?(Class)pBasicObject.instance_of?(Class)classHello;endpHello.instance_of?(Class)我不太明白这怎么可能,如果Object是Class的父类(superclass),它怎么可能都

  5. 大数据之Hadoop数据仓库Hive - 2

    目录:一、简介二、HQL的执行流程三、索引四、索引案例五、Hive常用DDL操作六、Hive常用DML操作七、查询结果插入到表八、更新和删除操作九、查询结果写出到文件系统十、HiveCLI和Beeline命令行的基本使用十一、Hive配置一、简介Hive是一个构建在Hadoop之上的数据仓库,它可以将结构化的数据文件映射成表,并提供类SQL查询功能,用于查询的SQL语句会被转化为MapReduce作业,然后提交到Hadoop上运行。特点:简单、容易上手(提供了类似sql的查询语言hql),使得精通sql但是不了解Java编程的人也能很好地进行大数据分析;灵活性高,可以自定义用户函数(UDF)和

  6. Ubuntu下Hadoop的单机安装 - 2

            云计算实验中要求我们在Linux系统安装Hadoop,故来做一个简单的记录。· 注:我的操作系统环境是Ubuntu-20.04.3,安装的JDK版本为jdk1.8.0_301,安装的Hadoop版本为hadoop2.7.1。(不确定其他版本是否会出现版本兼容问题)Hadoop安装步骤如下:        一、更新apt和安装vim编辑器        二、配置本机无密码登录SSH        三、安装JAVA环境        四、下载安装Hadoop        五、伪分布式搭建一、更新apt和安装vim编辑器1、更新aptsudoapt-getupdate2、安装vim

  7. ruby - celluloid gem 安装出错 - 2

    最近我将我的Rails版本更新到4.2.3并将ruby​​版本更新到ruby-2.2.3。之后,当我bundle它时会出现以下错误:$bundleFetchinggemmetadatafromhttp://rubygems.org/..........Fetchingversionmetadatafromhttp://rubygems.org/...Fetchingdependencymetadatafromhttp://rubygems.org/..Couldnotfindcelluloid-0.16.1inanyofthesources你能帮帮我吗? 最

  8. MAC系统安装Hadoop - 2

    一、设置免密登录1、系统偏好设置-----共享----勾选远程登录,所有用户2、打开终端,输入命令ssh-keygen-trsa,一直回车即可2.查看生成的公钥和私钥    cd~/.ssh    ls会看到~/.ssh目录下有两个文件:①私钥:id_rsa②公钥:id_rsa.pub3.将公钥内容写入到~/.ssh/authorized_keys中    cat~/.ssh/id_rsa.pub>>~/.ssh/authorized_keys4.测试在terminal终端输入 sshlocalhost如果出现以下询问输入yes,不需要输入密码就能登录,说明配置成功Areyousureyouw

  9. ruby - 如果在 Ruby 中一切都是对象,为什么这不起作用? - 2

    考虑到在Ruby编程语言中一切都被称为对象,我有把握地假设向方法传递参数是通过引用完成的。然而,下面这个小例子让我感到困惑:$string="String"defchanger(s)s=1endchanger($string)puts$string.classString=>nil如您所见,原始对象未被修改,我想知道原因,以及如何实现所需的行为,即。获取方法以实际更改其参数引用的对象。 最佳答案 Ruby的工作方式是按值传递和按引用传递的组合。事实上,Ruby使用引用传递值。您可以在以下线程中阅读更多内容:Passbyreferen

  10. ruby-on-rails - Ruby on Rails - 捆绑安装期间出错 - 2

    我一直在谷歌下面搜索这个错误,但我无法解决这个错误:Gem::Ext::BuildError:ERROR:Failedtobuildgemnativeextension./usr/bin/ruby2.1extconf.rbmkmf.rbcan'tfindheaderfilesforrubyat/usr/lib/ruby/include/ruby.hextconffailed,exitcode1Gemfileswillremaininstalledin/home/dyego/.bundler/tmp/9200/gems/sqlite3-1.3.9forinspection.Results

随机推荐