Get the App
SLTechnology News&Howtos  ›  Internet Technology  › 

[Druid] stand-alone Druid installation process

Shulou Source: shulou.com Published: 2022-06-03 03:50:13 09月30日 Update

Record the installation process of Druid stand-alone version, which is generally the same as the official website installation process, and add individual situations and solutions that are inconsistent with the official website installation.

Druid runs on zookeeper as a distributed coordination service, download and install zookeeper

wget https://archive.apache.org/dist/zookeeper/zookeeper-3.4.11/zookeeper-3.4.11.tar.gztar -zvf zookeeper-3.4.14.tar.gzln -s zookeeper-3.4.14 zookeeper

Download Druid installation package:

wget http://mirrors.tuna.tsinghua.edu.cn/apache/incubator/druid/0.15.0-incubating/apache-druid-0.15.0-incubating-bin.tar.gztar -zxf apache-druid-0.15.0-incubating-bin.tar.gzln -s apache-druid-0.15.0-incubating druid

Configure the ~/.bash_profile environment variable

vim ~/.bash_profile

export JAVA_HOME=/home/homework/jdkexport ZK_HOME=/home/homework/zookeeperexport DRUID_HOME=/home/homework/druidexport KAFKA_HOME=/home/homework/kafkaexport PATH=$PATH:$JAVA_HOME/bin:$ZK_HOME/bin:$DRUID_HOME/bin:$KAFKA_HOME/bin

Reload environment variables

source ~/.bash_profile

Start zookeeper

zkServer.sh start

ZooKeeper JMX enabled by default

Using config: /home/homework/zookeeper/bin/../ conf/zoo.cfg

Starting zookeeper ... STARTED

Start druid

[homework@test druid]$ start-micro-quickstart [Thu Aug 15 19:51:07 2019] Running command[zk], logging to[/mnt/homework/apache-druid-0.15.0-incubating/var/sv/zk.log]: bin/run-zk conf[Thu Aug 15 19:51:07 2019] Running command[coordinator-overlord], logging to[/mnt/homework/apache-druid-0.15.0-incubating/var/sv/coordinator-overlord.log]: bin/run-druid coordinator-overlord conf/druid/single-server/micro-quickstart[Thu Aug 15 19:51:07 2019] Running command[broker], logging to[/mnt/homework/apache-druid-0.15.0-incubating/var/sv/broker.log]: bin/run-druid broker conf/druid/single-server/micro-quickstart[Thu Aug 15 19:51:07 2019] Running command[router], logging to[/mnt/homework/apache-druid-0.15.0-incubating/var/sv/router.log]: bin/run-druid router conf/druid/single-server/micro-quickstart[Thu Aug 15 19:51:07 2019] Running command[historical], logging to[/mnt/homework/apache-druid-0.15.0-incubating/var/sv/historical.log]: bin/run-druid historical conf/druid/single-server/micro-quickstart[Thu Aug 15 19:51:07 2019] Running command[middleManager], logging to[/mnt/homework/apache-druid-0.15.0-incubating/var/sv/middleManager.log]: bin/run-druid middleManager conf/druid/single-server/micro-quickstart[Thu Aug 15 19:51:08 2019] Command[zk] exited (pid = 25982, exited = 1)[Thu Aug 15 19:51:08 2019] Command[zk] failed, see logfile for more details: /mnt/homework/apache-druid-0.15.0-incubating/var/sv/zk.log[Thu Aug 15 19:51:11 2019] Running command[zk], logging to[/mnt/homework/apache-druid-0.15.0-incubating/var/sv/zk.log]: bin/run-zk conf

I'm going to make a mistake when I execute this order. The requested URL/mnt/homework/apache-druid-0.15.0-incubating/var/sv/zk.log was not found on this server. The main reason is that the official website requires zookeeper to be placed in the root directory of druid as a zk folder.

Since I'm here zookeeper's installation is in a sibling directory with druid and other components. So a soft link is created in the druid installation directory, pointing to zk

cd /home/homework/druidln -s /home/homework/zookeeper zk

In this case, druid can be started.

Tags: Situation process variable environment directory stand-alone consistent content distributed cause sibling command point file folder method root directory component will report Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno MariaDB Xiaomi MySQL OPPO Reno NVidia