https://www.cloudera.com/documentation/manager/5-0-x/Cloudera-Manager-Installation-Guide/cm5ig_install_path_B.html

前期准备工作不多说了

先给每个节点配置镜像源,我这里以节点2为例

[cloudera-manager]
# Packages for Cloudera Manager, Version , on RedHat or CentOS x86_64
name=Cloudera Manager
baseurl=https://archive.cloudera.com/cm5/redhat/6/x86_64/cm/5.13.0/
gpgkey =https://archive.cloudera.com/cm5/redhat/6/x86_64/cm/RPM-GPG-KEY-cloudera
gpgcheck =

卸载centos6.5自带的jdk后就安装jdk,也是3个节点都安装

在节点1安装server

sudo yum install cloudera-manager-daemons cloudera-manager-server

在每个节点都安装agent

sudo yum install cloudera-manager-agent cloudera-manager-daemons

在每个节点 vim /etc/cloudera-scm-agent/config.ini

下载rpm包到电脑上

上传到cm1节点

sudo yum --nogpgcheck localinstall cloudera-cdh-5-0.x86_64.rpm

sudo rpm --import http://archive.cloudera.com/cdh5/redhat/6/x86_64/cdh/RPM-GPG-KEY-cloudera

sudo yum install avro-tools crunch flume-ng hadoop-hdfs-fuse hadoop-hdfs-nfs3 hadoop-httpfs 
hbase-solr hive-hbase hive-webhcat hue-beeswax hue-hbase hue-impala hue-pig hue-plugins hue-rdbms
hue-search hue-spark hue-sqoop hue-zookeeper impala impala-shell kite llama mahout oozie pig pig-udf-datafu search sentry solr-mapreduce spark-python sqoop sqoop2 whirr

安装完之后,在cm1节点启动server服务

在3个节点都启动agent服务

但是没有能打开

查看日志

in org.springframework.beans.factory.support.DefaultListableBeanFactory@1fe903d5: defining beans [commandLineConfigurationBean,entityManagerFactoryBean,com.cloudera.server.cmf.TrialState,com.cloudera.server.cmf.TrialManager,com.cloudera.cmf.crypto.LicenseLoader]; root of factory hierarchy
-- ::, ERROR main:com.cloudera.server.cmf.Main: Server failed.
org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'com.cloudera.server.cmf.TrialState': Cannot resolve reference to bean 'entityManagerFactoryBean' while setting constructor argument; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'entityManagerFactoryBean': FactoryBean threw exception on object creation; nested exception is javax.persistence.PersistenceException: [PersistenceUnit: cmf.server] Unable to build EntityManagerFactory
at org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveReference(BeanDefinitionValueResolver.java:)
at org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveValueIfNecessary(BeanDefinitionValueResolver.java:)
at org.springframework.beans.factory.support.ConstructorResolver.resolveConstructorArguments(ConstructorResolver.java:)
at org.springframework.beans.factory.support.ConstructorResolver.autowireConstructor(ConstructorResolver.java:)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.autowireConstructor(AbstractAutowireCapableBeanFactory.java:)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBeanInstance(AbstractAutowireCapableBeanFactory.java:)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:)
at org.springframework.beans.factory.support.AbstractBeanFactory$.getObject(AbstractBeanFactory.java:)
at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:)
at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:)
at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:)
at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:)
at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:)
at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:)
at com.cloudera.server.cmf.Main.bootstrapSpringContext(Main.java:)
at com.cloudera.server.cmf.Main.<init>(Main.java:)
at com.cloudera.server.cmf.Main.main(Main.java:)
Caused by: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'entityManagerFactoryBean': FactoryBean threw exception on object creation; nested exception is javax.persistence.PersistenceException: [PersistenceUnit: cmf.server] Unable to build EntityManagerFactory
at org.springframework.beans.factory.support.FactoryBeanRegistrySupport.doGetObjectFromFactoryBean(FactoryBeanRegistrySupport.java:)
at org.springframework.beans.factory.support.FactoryBeanRegistrySupport.getObjectFromFactoryBean(FactoryBeanRegistrySupport.java:)
at org.springframework.beans.factory.support.AbstractBeanFactory.getObjectForBeanInstance(AbstractBeanFactory.java:)
at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:)
at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:)
at org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveReference(BeanDefinitionValueResolver.java:)
... more
Caused by: javax.persistence.PersistenceException: [PersistenceUnit: cmf.server] Unable to build EntityManagerFactory
at org.hibernate.ejb.Ejb3Configuration.buildEntityManagerFactory(Ejb3Configuration.java:)
at org.hibernate.ejb.Ejb3Configuration.buildEntityManagerFactory(Ejb3Configuration.java:)
at org.hibernate.ejb.HibernatePersistence.createEntityManagerFactory(HibernatePersistence.java:)
at javax.persistence.Persistence.createEntityManagerFactory(Persistence.java:)
at com.cloudera.enterprise.CommonMain.setupHibernate(CommonMain.java:)
at com.cloudera.server.cmf.bootstrap.EntityManagerFactoryBean.getObject(EntityManagerFactoryBean.java:)
at com.cloudera.server.cmf.bootstrap.EntityManagerFactoryBean.getObject(EntityManagerFactoryBean.java:)
at org.springframework.beans.factory.support.FactoryBeanRegistrySupport.doGetObjectFromFactoryBean(FactoryBeanRegistrySupport.java:)
... more
Caused by: org.hibernate.service.classloading.spi.ClassLoadingException: HHH010003: JDBC Driver class not found: com.mysql.jdbc.Driver
at org.hibernate.service.jdbc.connections.internal.C3P0ConnectionProvider.configure(C3P0ConnectionProvider.java:)
at org.hibernate.service.internal.StandardServiceRegistryImpl.configureService(StandardServiceRegistryImpl.java:)
at org.hibernate.service.internal.AbstractServiceRegistryImpl.initializeService(AbstractServiceRegistryImpl.java:)
at org.hibernate.service.internal.AbstractServiceRegistryImpl.getService(AbstractServiceRegistryImpl.java:)
at org.hibernate.engine.jdbc.internal.JdbcServicesImpl.buildJdbcConnectionAccess(JdbcServicesImpl.java:)
at org.hibernate.engine.jdbc.internal.JdbcServicesImpl.configure(JdbcServicesImpl.java:)
at org.hibernate.service.internal.StandardServiceRegistryImpl.configureService(StandardServiceRegistryImpl.java:)
at org.hibernate.service.internal.AbstractServiceRegistryImpl.initializeService(AbstractServiceRegistryImpl.java:)
at org.hibernate.service.internal.AbstractServiceRegistryImpl.getService(AbstractServiceRegistryImpl.java:)
at org.hibernate.cfg.Configuration.buildTypeRegistrations(Configuration.java:)
at org.hibernate.cfg.Configuration.buildSessionFactory(Configuration.java:)
at org.hibernate.ejb.EntityManagerFactoryImpl.<init>(EntityManagerFactoryImpl.java:)
at org.hibernate.ejb.Ejb3Configuration.buildEntityManagerFactory(Ejb3Configuration.java:)
... more
Caused by: org.hibernate.service.classloading.spi.ClassLoadingException: Unable to load class [com.mysql.jdbc.Driver]
at org.hibernate.service.classloading.internal.ClassLoaderServiceImpl.classForName(ClassLoaderServiceImpl.java:)
at org.hibernate.service.jdbc.connections.internal.C3P0ConnectionProvider.configure(C3P0ConnectionProvider.java:)
... more
Caused by: java.lang.ClassNotFoundException: Could not load requested class : com.mysql.jdbc.Driver
at org.hibernate.service.classloading.internal.ClassLoaderServiceImpl$AggregatedClassLoader.findClass(ClassLoaderServiceImpl.java:)
at java.lang.ClassLoader.loadClass(ClassLoader.java:)
at java.lang.ClassLoader.loadClass(ClassLoader.java:)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:)
at org.hibernate.service.classloading.internal.ClassLoaderServiceImpl.classForName(ClassLoaderServiceImpl.java:)
... more
[root@cm1 cloudera-scm-server]# pwd
/var/log/cloudera-scm-server
[root@cm1 cloudera-scm-server]# cat cloudera-scm-server.log

没有安装数据库的驱动

sudo yum install mysql-server

我们登录进mysql

create database amon DEFAULT CHARACTER SET utf8;
grant all on amon.* TO 'amon'@'%' IDENTIFIED BY 'amon_password';
grant all on *.* TO 'amon'@'cm1' IDENTIFIED BY 'amon_password';
grant all on amon.* TO 'amon'@'localhost' IDENTIFIED BY 'amon_password'; create database rman DEFAULT CHARACTER SET utf8;
grant all on rman.* TO 'rman'@'%' IDENTIFIED BY 'rman_password';
grant all on *.* TO 'rman'@'cm1' IDENTIFIED BY 'rman_password';
grant all on rman.* TO 'rman'@'localhost' IDENTIFIED BY 'rman_password'; create database nav DEFAULT CHARACTER SET utf8;
grant all on nav.* TO 'nav'@'%' IDENTIFIED BY 'nav_password';
grant all on *.* TO 'nav'@'cm1' IDENTIFIED BY 'nav_password';
grant all on nav.* TO 'nav'@'localhost' IDENTIFIED BY 'nav_password'; create database hive DEFAULT CHARACTER SET utf8;
grant all on hive.* TO 'hive'@'%' IDENTIFIED BY 'hive_password';
grant all on *.* TO 'hive'@'cm1' IDENTIFIED BY 'hive_password';
grant all on hive.* TO 'hive'@'localhost' IDENTIFIED BY 'hive_password';

create database scm DEFAULT CHARACTER SET utf8;
grant all on scm.* TO 'scm'@'%' IDENTIFIED BY 'scm_password';
grant all on *.* TO 'scm'@'cm1' IDENTIFIED BY 'scm_password';
grant all on scm.* TO 'scm'@'localhost' IDENTIFIED BY 'scm_password';

create database oozie DEFAULT CHARACTER SET utf8;
grant all on oozie.* TO 'oozie'@'localhost' IDENTIFIED BY 'oozie_password';
grant all on *.* TO 'oozie'@'cm1' IDENTIFIED BY 'oozie_password';
grant all on oozie.* TO 'oozie'@'%' IDENTIFIED BY 'oozie_password';

create database hue DEFAULT CHARACTER SET utf8;
grant all on hue.* TO 'hue'@'localhost' IDENTIFIED BY 'hue_password';
grant all on *.* TO 'hue'@'cm1' IDENTIFIED BY 'hue_password';
grant all on hue.* TO 'hue'@'%' IDENTIFIED BY 'hue_password';
flush privileges;

flush privileges;

mysql> create database amon DEFAULT CHARACTER SET utf8;
Query OK, row affected (0.00 sec) mysql> grant all on amon.* TO 'amon'@'%' IDENTIFIED BY 'amon_password';
Query OK, rows affected (0.00 sec) mysql> grant all on *.* TO 'amon'@'cm1' IDENTIFIED BY 'amon_password';
Query OK, rows affected (0.00 sec) mysql> grant all on amon.* TO 'amon'@'localhost' IDENTIFIED BY 'amon_password';
Query OK, rows affected (0.00 sec) mysql> create database rman DEFAULT CHARACTER SET utf8;
Query OK, row affected (0.00 sec) mysql> grant all on rman.* TO 'rman'@'%' IDENTIFIED BY 'rman_password';
Query OK, rows affected (0.00 sec) mysql> grant all on *.* TO 'rman'@'cm1' IDENTIFIED BY 'rman_password';
Query OK, rows affected (0.00 sec) mysql> grant all on rman.* TO 'rman'@'localhost' IDENTIFIED BY 'rman_password';
Query OK, rows affected (0.00 sec) mysql> create database nav DEFAULT CHARACTER SET utf8;
Query OK, row affected (0.00 sec) mysql> grant all on nav.* TO 'nav'@'%' IDENTIFIED BY 'nav_password';
Query OK, rows affected (0.00 sec) mysql> grant all on *.* TO 'nav'@'cm1' IDENTIFIED BY 'nav_password';
Query OK, rows affected (0.00 sec) mysql> grant all on nav.* TO 'nav'@'localhost' IDENTIFIED BY 'nav_password';
Query OK, rows affected (0.00 sec) mysql> create database metastore DEFAULT CHARACTER SET utf8;
Query OK, row affected (0.00 sec) mysql> grant all on hive.* TO 'hive'@'%' IDENTIFIED BY 'hive_password';
Query OK, rows affected (0.00 sec) mysql> grant all on *.* TO 'hive'@'cm1' IDENTIFIED BY 'hive_password';
Query OK, rows affected (0.00 sec) mysql> grant all on *.* TO 'hive'@'cm1' IDENTIFIED BY 'hive_password';
Query OK, rows affected (0.00 sec) mysql>flush privileges;

在节点1执行

sudo /usr/share/cmf/schema/scm_prepare_database.sh mysql scm scm scm_password

把服务重启一下server (节点1)  agent(3个节点)

打开这个地址http://192.168.86.141:7180/

下一步如果安装失败了

而且出现这情况

就这样解决

如果是出现cloudemanager安装时出现8475 MainThread agent ERROR Heartbeating to 出门cm1:7180 failed这样的问题

就这样解决

遇到这情况就重新运行一下

用find / -name cm_guid查找 cm_guid文件

然后把他删除了(3个节点都这样)

遇到这种问题

查看agent日志

Failed to connect to previous supervisor

在线安装CM集群的更多相关文章

  1. 在线安装TIDB集群

     在线安装TiDB集群 服务器准备 说明:TiDB8需要能够连接外网,以便下载各类安装包 TiDB4非必须,但最好是有一台,因为后续测试Mysql数据同步或者进行性能比较时,都要用到 TiKV最好是采 ...

  2. centos7.0 安装redis集群

    生产环境下redis基本上都是用的集群,毕竟单机版随时都可能挂掉,风险太大.这里我就来搭建一个基本的redis集群,功能够用但是还需要完善,当然如果有钱可以去阿里云买云数据库Redis版的,那个还是很 ...

  3. CentOS7 搭建Ambari-Server,安装Hadoop集群(一)

    2017-07-05:修正几处拼写错误,之前没发现,抱歉! 第一次在cnblogs上发表文章,效果肯定不会好,希望各位多包涵. 编写这个文档的背景是月中的时候,部门老大希望我们能够抽时间学习一下Had ...

  4. linux下redis的安装和集群搭建

    一.redis概述 1.1.目前redis支持的cluster特性: 1):节点自动发现. 2):slave->master 选举,集群容错. 3):Hot resharding:在线分片. 4 ...

  5. [k8s]kubespray(ansible)自动化安装k8s集群

    kubespray(ansible)自动化安装k8s集群 https://github.com/kubernetes-incubator/kubespray https://kubernetes.io ...

  6. CentOS7 Cloudera Manager6 完全离线安装 CDH6 集群

    本文是在CentOS7.4 下进行CDH6集群的完全离线部署.CDH5集群与CDH6集群的部署区别比较大. 说明:本文内容所有操作都是在root用户下进行的. 文件下载 首先一些安装CDH6集群的必须 ...

  7. Kubernetes全栈架构师(Kubeadm高可用安装k8s集群)--学习笔记

    目录 k8s高可用架构解析 Kubeadm基本环境配置 Kubeadm系统及内核升级 Kubeadm基本组件安装 Kubeadm高可用组件安装 Kubeadm集群初始化 高可用Master及Token ...

  8. 基于yum安装CDH集群

    一.环境准备 准备至少3台设备:CentOS7系统: 如果是在实验环境下,给虚拟机的内存至少4G,根建议1T,数据盘1T,由于是虚拟机,所以根分区和数据盘放心大胆的给:如果是在生产环境则多多益善:我这 ...

  9. 安装ClouderaManager以及使用ClouderaManager安装分布式集群的若干细节

    目录 前言 整体介绍 分步安装介绍 总结 一.前言        周末干了近四十个小时中间只休息了五个小时终于成功安装了ClouderaManager以及分布式集群,其中各种辛酸无以言表,唯有泪两行. ...

随机推荐

  1. SUPERSOCKET 客户端

    SUPERSOCKET.CLIENTENGINE 简单使用 2015年5月27日 HYJIACAN 发表回复 阅读 11,105 次 江大没有给ClientEngine的Demo,一直没有找到其它的. ...

  2. day10 内容大纲

    01 去年内容回顾 01 去年内容回顾 *args **kwargs: 万能参数,动态参数 * 魔性用法: 函数的定义时,* ** 聚合. 函数的执行时,* ** 打散. 形参顺序: 位置参数,*ar ...

  3. 【转存】Vue组件选项props

    原帖地址 前面的话 组件接受的选项大部分与Vue实例一样,而选项props是组件中非常重要的一个选项.在 Vue 中,父子组件的关系可以总结为 props down, events up.父组件通过  ...

  4. Spring技术内幕总结 - AOP概述

    AOP是Aspect-Oriented Programming(面向方面/切面编程)的简称.Aspect是一种新的模块化机制,用来描述分散在对象.类或函数中的横切关注点.分离关注点使解决特定领域问题的 ...

  5. taro 开发注意点

    taro 开发注意点: 注意点 原因 如果要支持 React Native 端,必须采用 Flex 布局,并且样式选择器仅支持类选择器,且不支持 组合器 Taro RN 端是基于 Expo,因此不支持 ...

  6. PyCharm中的Console自动换行

    菜单栏-> File -> Settings -> Editor -> General -> Console,选中右侧Use soft wraps in console前 ...

  7. $("#form1"). serialize()提交表单

    一.jQuery ajax()使用serialize()提交form数据 jQuery的serialize()方法通过序列化表单值,创建URL编码文本字符串,我们就可以选择一个或多个表单元素,也可以直 ...

  8. Elasticsearch集成HanLP分词器

    1.通过git下载分词器代码. 连接如下:https://gitee.com/hualongdata/hanlp-ext hanlp官网如下:http://hanlp.linrunsoft.com/ ...

  9. hadoop 2.7.1安装和配置

    一.安装环境 硬件:虚拟机 操作系统:Centos 6.4 64位 IP:192.168.241.128主机名:admin安装用户:root 二.安装JDK 安装JDK1.7或者以上版本.这里安装jd ...

  10. C++用 _findfirst 和 _findnext 查找文件

    一.这两个函数均在io.h里面.   二.首先了解一下一个文件结构体: struct _finddata_t {     unsigned    attrib;     time_t      tim ...