客服微信
TDSQL开机服务启动步骤
1. 开机后手动启动oss服务
1) 查看oss端口已启动,但oss服务不能访问
[ ]
LISTEN 0 5 192.168.80.21:8080
2) 启动oss后台nginx服务[tdsql2、tdsql3]
/usr/local/nginx/sbin/nginx #访问该节点oss服务正常
3) 访问赤兔,确保OSS可以访问
http://192.168.80.21/tdsqlpcloud
2. 启动hdfs
1) 启动hfs服务[tdsql4]
su - tdsql
hdfs --daemon start namenode
hdfs --daemon start datanode
2) 确保备份目录可以查看到
[tdsql@tdsql4 ~]$ hdfs dfs -ls /
Found 1 items
drwxr-xr-x - tdsql supergroup 0 2020-12-03 10:59 /tdsqlbacku
3) 也可以通过web访问hdfs服务
http://192.168.80.23:9870
3. 启动kafka
1) 启动kafka
cd /data/application/kafka/bin
./kafka-server-start.sh -daemon ../config/server.properties
cd
注:如果内存过小,kafka不能启动,需要修改kafka启动脚本参数后再启动
kafka[tdsql1-3]
[root@tdsql1 ~]# vim /data/application/kafka/bin/kafka-server-start.sh
if [ "x$KAFKA_HEAP_OPTS" = "x" ]; then
# export KAFKA_HEAP_OPTS="-Xmx6G -Xms6G" #将内存调小,此处设置为2G
export KAFKA_HEAP_OPTS="-Xmx2G -Xms2G"
fi
2) 查看服务已经启动
[root@tdsql3 bin]# ps -ef | grep kafka
...
root 90668 1 99 09:26 pts/0 00:00:07 /data/home/tdsql/jdk/bin/java -Xmx2G -Xms2G -server -XX:+UseG1GC -XX:MaxGCPauseMillis=20 -XX:InitiatingHeapOccupancyPercent=35 -XX:+ExplicitGCInvokesConcurrent -Djava.awt.headless=true -Xloggc:/data/application/kafka/bin/../logs/kafkaServer-gc.log -verbose:gc -XX:+PrintGCDetails -XX:+PrintGCDateStamps -XX:+PrintGCTimeStamps -Dcom.sun.management.jmxremote -Dcom.sun.management.jmxremote.authenticate=false
4. 启动es & kibana
1) tdsql用户启动服务:
su - tdsql
cd /data/application/es-install/es/master/tools;nohup ./start-elasticsearch.sh &
cd /data/application/es-install/es/data/tools;nohup ./start-elasticsearch.sh &
exit
2) root用户启动服务:
cd /data/application/es-install/logstash/tools;nohup ./start-logstash.sh &
cd /data/application/es-install/es-cleaner;nohup ./start-es-cleaner.sh &
cd /data/application/es-install/kibana-5.6.4-linux-x86_64/bin;nohup ./kibana &
3) 检查进程已启动
ps -ef |grep elasticsearch | grep -v 'grep' |wc -l
输出为:4
ps -ef |grep logstash | grep -v 'grep' |wc -l
输出为:2
ps -ef |grep es-cleaner | grep -v 'grep' |wc -l
输出为:1
ps -ef |grep 'node/bin/node' | grep -v 'grep' |wc -l
输出为:1
4) 查看kibana服务[tdsql4]
http://192.168.80.23
5. 帮助
以上素材来源于: 郭一军,许玉冲,胡毅,李海峰等。
*禁止转载,可转发(转发原创文章请注明出处)