学Linux,上红联!
Linux系统教程
您的位置: Linux系统教程 > Linux技巧 >

Couldn't start cloudera-scm-server的解决办法(图文详解)

时间:2017-06-26来源:cnblogs.com/zlslch 作者:好记性不如烂笔头!
bigdata@ubuntucmbigdata1:~$ sudo /etc/init.d/mysql start
start: Job is already running: mysql
bigdata@ubuntucmbigdata1:~$ sudo /etc/init.d/mysql stop
mysql stop/waiting
bigdata@ubuntucmbigdata1:~$ sudo /etc/init.d/mysql start
mysql start/running, process 2169
bigdata@ubuntucmbigdata1:~$ sudo /opt/cm-5.6.0/etc/init.d/cloudera-scm-server start
Starting cloudera-scm-server:  * Couldn't start cloudera-scm-server
bigdata@ubuntucmbigdata1:~$ java -version
java version "1.8.0_60"
Java(TM) SE Runtime Environment (build 1.8.0_60-b27)
Java HotSpot(TM) 64-Bit Server VM (build 25.60-b23, mixed mode)
bigdata@ubuntucmbigdata1:~$ vim /etc/profile
bigdata@ubuntucmbigdata1:~$ java -version
java version "1.8.0_60"
Java(TM) SE Runtime Environment (build 1.8.0_60-b27)
Java HotSpot(TM) 64-Bit Server VM (build 25.60-b23, mixed mode)
bigdata@ubuntucmbigdata1:~$
bigdata@ubuntucmbigdata1:/opt/cm-5.6.0/log/cloudera-scm-server$ pwd
/opt/cm-5.6.0/log/cloudera-scm-server
bigdata@ubuntucmbigdata1:/opt/cm-5.6.0/log/cloudera-scm-server$ ll
total 12
drwxr-xr-x 2 bigdata bigdata 4096  6月 25 19:52 ./
drwxr-xr-x 5 bigdata bigdata 4096  2月 12  2016 ../
-rw-r--r-- 1 root    root     730  6月 25 21:08 cloudera-scm-server.out
bigdata@ubuntucmbigdata1:/opt/cm-5.6.0/log/cloudera-scm-server$ cat cloudera-scm-server.out 
Error: JAVA_HOME is not set and Java could not be found
Please download the latest Oracle JDK from the Oracle Java web site
http://www.oracle.com/technetwork/java/javase/index.html
Cloudera Manager requires Java 1.6 or later.
NOTE: This script will find Oracle Java whether you install using
the binary or the RPM based installer.
bigdata@ubuntucmbigdata1:/opt/cm-5.6.0/log/cloudera-scm-server$ 
 
解决办法
一个是OS的环境变量,一个是脚本运行时候的设置
bigdata@ubuntucmbigdata1:/opt/cm-5.6.0/etc/init.d$ sudo vim cloudera-scm-server
export JAVA_HOME=/usr/java/jdk.1.7.0_80
它的下载链接
http://download.oracle.com/otn/java/jdk/7u80-b15/jdk-7u80-linux-x64.tar.gz
bigdata@ubuntucmbigdata1:~$ sudo /opt/cm-5.6.0/etc/init.d/cloudera-scm-server start
Starting cloudera-scm-server:  * cloudera-scm-server started
bigdata@ubuntucmbigdata1:~$
 
本文永久更新地址:/linux/31731.html
顶上去
(0)
0%
踩下去
(0)
0%
------分隔线----------------------------