当前位置: 首页 > news >正文

Doris集群搭建

Doris集群搭建

1、简介

搭建三节点存算一体Doris集群

FEBE混合部署

版本号2.1.9

节点ip作用
node310.1.0.21FE,BE
node410.1.0.18FE,BE
node410.1.0.19FE,BE

2、配置

配置每个节点IpJava环境

2.1、FE

# Licensed to the Apache Software Foundation (ASF) under one# or more contributor license agreements. See the NOTICE file# distributed with this work for additional information# regarding copyright ownership. The ASF licenses this file# to you under the Apache License, Version 2.0 (the# "License"); you may not use this file except in compliance# with the License. You may obtain a copy of the License at## http://www.apache.org/licenses/LICENSE-2.0## Unless required by applicable law or agreed to in writing,# software distributed under the License is distributed on an# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY# KIND, either express or implied. See the License for the# specific language governing permissions and limitations# under the License.####################################################################### The uppercase properties are read and exported by bin/start_fe.sh.## To see all Frontend configurations,## see fe/src/org/apache/doris/common/Config.java#####################################################################CUR_DATE=`date+%Y%m%d-%H%M%S`# Log dirLOG_DIR=${DORIS_HOME}/log# For jdk 8JAVA_OPTS="-Xmx16384m -XX:+UseMembar -XX:SurvivorRatio=8 -XX:MaxTenuringThreshold=7 -XX:+PrintGCDateStamps -XX:+PrintGCDetails -XX:+UseConcMarkSweepGC -XX:+UseParNewGC -XX:+CMSClassUnloadingEnabled -XX:-CMSParallelRemarkEnabled -XX:CMSInitiatingOccupancyFraction=80 -XX:SoftRefLRUPolicyMSPerMB=0 -Xloggc:$DORIS_HOME/log/fe.gc.log.$DATE"# For jdk 17, this JAVA_OPTS will be used as default JVM optionsJAVA_OPTS_FOR_JDK_17="-Dfile.encoding=UTF-8 -Djavax.security.auth.useSubjectCredsOnly=false -Xmx8192m -Xms8192m -XX:+UseG1GC -XX:+HeapDumpOnOutOfMemoryError -XX:HeapDumpPath=$LOG_DIR-Xlog:gc*,classhisto*=trace:$LOG_DIR/fe.gc.log.$CUR_DATE:time,uptime:filecount=10,filesize=50M --add-opens=java.base/java.nio=ALL-UNNAMED --add-opens java.base/jdk.internal.ref=ALL-UNNAMED --add-opens java.base/sun.nio.ch=ALL-UNNAMED --add-opens java.xml/com.sun.org.apache.xerces.internal.jaxp=ALL-UNNAMED"# Set your own JAVA_HOMEJAVA_HOME=/opt/java#### the lowercase properties are read by main program.### store metadata, must be created before start FE.# Default value is ${DORIS_HOME}/doris-meta# meta_dir = ${DORIS_HOME}/doris-meta# Default dirs to put jdbc drivers,default value is ${DORIS_HOME}/jdbc_drivers# jdbc_drivers_dir = ${DORIS_HOME}/jdbc_drivershttp_port=8030rpc_port=9020query_port=9030edit_log_port=9010arrow_flight_sql_port=-1# Choose one if there are more than one ip except loopback address.# Note that there should at most one ip match this list.# If no ip match this rule, will choose one randomly.# use CIDR format, e.g. 10.10.10.0/24 or IP format, e.g. 10.10.10.1# Default value is empty.priority_networks=10.1.0.21# Advanced configurations# log_roll_size_mb = 1024# INFO, WARN, ERROR, FATALsys_log_level=INFO# NORMAL, BRIEF, ASYNCsys_log_mode=ASYNC# sys_log_roll_num = 10# sys_log_verbose_modules = org.apache.doris# audit_log_dir = $LOG_DIR# audit_log_modules = slow_query, query# audit_log_roll_num = 10# meta_delay_toleration_second = 10# qe_max_connection = 1024# qe_query_timeout_second = 300# qe_slow_log_ms = 5000

2.2、BE

8040端口冲突,Yarn占用,修改为8041

配置storage_root_path存储位置

# Licensed to the Apache Software Foundation (ASF) under one# or more contributor license agreements. See the NOTICE file# distributed with this work for additional information# regarding copyright ownership. The ASF licenses this file# to you under the Apache License, Version 2.0 (the# "License"); you may not use this file except in compliance# with the License. You may obtain a copy of the License at## http://www.apache.org/licenses/LICENSE-2.0## Unless required by applicable law or agreed to in writing,# software distributed under the License is distributed on an# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY# KIND, either express or implied. See the License for the# specific language governing permissions and limitations# under the License.CUR_DATE=`date+%Y%m%d-%H%M%S`# Log dirLOG_DIR="${DORIS_HOME}/log/"# For jdk 8JAVA_OPTS="-Dfile.encoding=UTF-8 -Xmx2048m -DlogPath=$LOG_DIR/jni.log -Xloggc:$DORIS_HOME/log/be.gc.log.$CUR_DATE-Djavax.security.auth.useSubjectCredsOnly=false -Dsun.security.krb5.debug=true -Dsun.java.command=DorisBE -XX:-CriticalJNINatives -Darrow.enable_null_check_for_get=false"# For jdk 9+, this JAVA_OPTS will be used as default JVM optionsJAVA_OPTS_FOR_JDK_9="-Dfile.encoding=UTF-8 -Xmx2048m -DlogPath=$DORIS_HOME/log/jni.log -Xlog:gc:$LOG_DIR/be.gc.log.$CUR_DATE-Djavax.security.auth.useSubjectCredsOnly=false -Dsun.security.krb5.debug=true -Dsun.java.command=DorisBE -XX:-CriticalJNINatives --add-opens=java.base/java.nio=ALL-UNNAMED -Darrow.enable_null_check_for_get=false"# For jdk 17+, this JAVA_OPTS will be used as default JVM optionsJAVA_OPTS_FOR_JDK_17="-Dfile.encoding=UTF-8 -Xmx2048m -DlogPath=$LOG_DIR/jni.log -Xlog:gc:$LOG_DIR/be.gc.log.$CUR_DATE-Djavax.security.auth.useSubjectCredsOnly=false -Dsun.security.krb5.debug=true -Dsun.java.command=DorisBE -XX:-CriticalJNINatives --add-opens=java.base/java.net=ALL-UNNAMED --add-opens=java.base/java.nio=ALL-UNNAMED -Darrow.enable_null_check_for_get=false"# since 1.2, the JAVA_HOME need to be set to run BE process.JAVA_HOME=/opt/java# https://github.com/apache/doris/blob/master/docs/zh-CN/community/developer-guide/debug-tool.md#jemalloc-heap-profile# https://jemalloc.net/jemalloc.3.htmlJEMALLOC_CONF="percpu_arena:percpu,background_thread:true,metadata_thp:auto,muzzy_decay_ms:5000,dirty_decay_ms:5000,oversize_threshold:0,prof:true,prof_active:false,lg_prof_interval:-1"JEMALLOC_PROF_PRFIX="jemalloc_heap_profile_"# ports for admin, web, heartbeat servicebe_port=9060webserver_port=8041heartbeat_service_port=9050brpc_port=8060arrow_flight_sql_port=-1# HTTPS configuresenable_https=false# path of certificate in PEM format.ssl_certificate_path="$DORIS_HOME/conf/cert.pem"# path of private key in PEM format.ssl_private_key_path="$DORIS_HOME/conf/key.pem"# Choose one if there are more than one ip except loopback address.# Note that there should at most one ip match this list.# If no ip match this rule, will choose one randomly.# use CIDR format, e.g. 10.10.10.0/24 or IP format, e.g. 10.10.10.1# Default value is empty.priority_networks=10.1.0.21# data root path, separate by ';'# You can specify the storage type for each root path, HDD (cold data) or SSD (hot data)# eg:storage_root_path=/opt/doris2Data,medium:SSD# storage_root_path = /home/disk1/doris,medium:SSD;/home/disk2/doris,medium:SSD;/home/disk2/doris,medium:HDD# /home/disk2/doris,medium:HDD(default)## you also can specify the properties by setting '<property>:<value>', separate by ','# property 'medium' has a higher priority than the extension of path## Default value is ${DORIS_HOME}/storage, you should create it by hand.# storage_root_path = ${DORIS_HOME}/storage# Default dirs to put jdbc drivers,default value is ${DORIS_HOME}/jdbc_drivers# jdbc_drivers_dir = ${DORIS_HOME}/jdbc_drivers# Advanced configurations# INFO, WARNING, ERROR, FATALsys_log_level=INFO# sys_log_roll_mode = SIZE-MB-1024# sys_log_roll_num = 10# sys_log_verbose_modules = *# log_buffer_level = -1# palo_cgroups# aws sdk log level# Off = 0,# Fatal = 1,# Error = 2,# Warn = 3,# Info = 4,# Debug = 5,# Trace = 6# Default to turn off aws sdk log, because aws sdk errors that need to be cared will be output through Doris logsaws_log_level=0## If you are not running in aws cloud, you can disable EC2 metadataAWS_EC2_METADATA_DISABLED=true
ALTER SYSTEM ADD FOLLOWER "10.1.0.18:9010"; ALTER SYSTEM ADD FOLLOWER "10.1.0.19:9010";
//填写主节点ip start_fe.sh --helper 10.1.0.21:9010 --daemon start_fe.sh --helper 10.1.0.21:9010 --daemon
mysql -h 10.1.0.21 -P 9030 -uroot
ALTERSYSTEMADDBACKEND"10.1.0.21:9050";ALTERSYSTEMADDBACKEND"10.1.0.18:9050";ALTERSYSTEMADDBACKEND"10.1.0.19:9050";
SETPASSWORD=PASSWORD('zhenshi');

3、启动FE

3.1、单独建立元数据存储位置

## Use a separate disk for FE metadatamkdir-p<doris_meta_created>## Create FE metadata directory symlinkln-s<doris_meta_created><doris_meta_original>

3.2、启动

bin/start_fe.sh --daemon

3.3、部署FE Follower节点

将node4、node5添加为Follower节点

mysql-h10.1.0.21-P9030-u rootALTERSYSTEMADDFOLLOWER"10.1.0.18:9010";ALTERSYSTEMADDFOLLOWER"10.1.0.19:9010";

3.4、启动FE Follower节点

//填写主节点node3的ip start_fe.sh --helper10.1.0.21:9010 --daemon start_fe.sh --helper10.1.0.21:9010 --daemon

4、启动BE

4.1、添加BE节点

ALTERSYSTEMADDBACKEND"10.1.0.21:9050";ALTERSYSTEMADDBACKEND"10.1.0.18:9050";ALTERSYSTEMADDBACKEND"10.1.0.19:9050";

4.2、启动BE

bin/start_be.sh --daemon

5、验证

Mysql环境输入下列指令

showfrontends \Gshowbackends \G

Web环境可打卡以下网址

  • Web UI: http://10.1.0.21:8030
  • 监控指标: http://10.1.0.21:8041/metrics
http://www.jsqmd.com/news/105580/

相关文章:

  • 终极ASMR音频资源快速下载完整指南
  • React Native Vision Camera实战:从零构建高性能AR拍摄应用
  • JAVA基于多线程机制的理解
  • 网通领域发光二极管(LED)应用全解析:从基础认知到选型要点
  • EmotiVoice技术解析:多情感语音合成背后的秘密
  • 视频体积减少94.39%,极致视频压缩软件,纯本地离线免费用!秒杀小丸工具箱,支持Win/Mac CompressO
  • BiliPlus终极指南:重新定义你的B站观看体验
  • 10 个AI写作工具,自考论文轻松搞定!
  • 直播场景中的语音创新:用EmotiVoice生成实时互动语音
  • Win系统更新常出错?一键永久彻底禁止Win更新,简单易用,小白也可轻松禁止系统更新操作,附2款工具
  • 重磅!AI应用架构师力推的企业虚拟运营方案_副本
  • EmotiVoice能否用于外语学习?模仿母语者语调的功能验证
  • 如何快速获取完整中国行政区划数据:终极管理工具指南
  • EmotiVoice语音合成多区域部署架构设计
  • 金仓数据库:不止于兼容,更以三重革新赋能企业数字化深水区
  • pose-search:人体动作分析与姿态搜索终极指南
  • EmotiVoice语音自豪感合成增强成就反馈
  • AI文字语音项目:搭建一个支持情感控制、可二次封装的TTS服务
  • Easy Effects音效优化完全指南:从入门到精通的专业预设配置
  • 41、Linux 服务器邮件过滤与安全防护指南
  • 大模型备案“拦截关键词”咋做?一份干货避坑指南
  • 调用nt!KiExitDispatcher的又一个函数nt!KeInsertQueueApc和nt!KiProcessDeferredReadyList函数分析和全局变量nt!KiIdleSummar
  • 智能检索系统进阶指南:解锁代理规划与深度推理双引擎实战
  • ComfyUI-SeedVR2视频超分插件完整安装与配置指南
  • Hslcommunication
  • SQL SERVER对每张表新增字段
  • Ditto剪贴板管理器完整使用指南:从新手到高手的快速上手教程
  • Emby美化插件终极指南:打造专属影音中心
  • EmotiVoice在脱口秀AI主持人开发中的潜力
  • Bruno技术深度解析:API测试工具的架构革新与实践