First, the system environment
The installation configuration of Kylin is not as simple as it is described in the official documentation, because the Hadoop,hive,hbase,kylin version must be compatible, or there will be a variety of strange errors. The following software versions can successfully run Kylin.
16.041.82.6. 4 5.7. + 2.1. 0 0.98. -1.5. 4.1
The above version of the software is downloaded here.
Before installing the Kylin, install Hadoop,hive,hbase first.
Second, installation steps
1, installation Kylin
First download the Kylin and install it into the/usr/local directory
sudo tar -xzf apache-kylin-1.5. 4.1-bin. tar. gz-c/usr/local~/download $ cd/usr/localsudomv apache-kylin-1.5 . 4.1-bin/ kylinsudochown -R Hadoop kylin/ #hadoop为我的用户名, Change to your user name
Edit ~/.BASHRC, configure environment variables for Kylin
Export kylin_home=/usr/local/kylinexport PATH= $PATH: $KYLIN _home/bin
After the configuration is complete, source/.BASHRC makes the environment variable effective. The hadoop,hive,hbase has been installed before, so my ~/.BASHRC is as follows:
2, Configuration Kylin
Configure the database name for Kylin using hive
cd/usr/local/kylin/Confvim kylin.properties
Modify Kylin.job.hive.database.for.intermediatetable to Kylin_middle
Then create the database in hive Kylin_middle
$ hive> CREATE DATABASE kylin_middle;
Then create the directory Kylin on HDFs and copy it to the current user, my current user is Hadoop
Hadoop FS-mkdir /-chown -R Hadoop/kylin
Then execute Kylin's check-env. SH , this may cause an error
This needs to replace the SH in the script with bash, the command is as follows:
Cd/usr/local/kylin/bin
Sed's/' sh/' bash/g' *. SH
And then check-env.sh found that the problem disappeared. If there is no problem, Kylin can run, before running, you must first open the Hadoop,hbase:
$ START-DFS. SH $ start-yarn. SH $ Mr-jobhistory-daemon. SH start historyserver$ start-base. SH $ kylin. SH start
Installation and configuration of Kylin under Ubuntu16.04