Files
orange-admin/orange-demo-multi-service/zz-resource/docker-files/clear-data.sh
2021-06-06 22:53:13 +08:00

22 lines
661 B
Bash
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

#! /bin/bash
# 如果执行的是docker-compose down下次再docker-compose up启动中间件时
# kafka 可能会因为之前的强行退出而出现position错误此时可以执行当前shell
# 删除他们的数据。
# 我们更推荐docker-compose stop的方式停止服务下次启动docker-compose start。
rm -rf ./data/redis/*
rm -rf ./data/elasticsearch/*
rm -rf ./data/kafka/*
rm -rf ./data/rocketmq/*
rm -rf ./data/logstash/*
rm -rf ./data/logstash/.lock
rm -rf ./data/zookeeper/*
rm -rf ./logs/redis/*
rm -rf ./logs/elasticsearch/*
rm -rf ./logs/kafka/*
rm -rf ./logs/rocketmq/*
rm -rf ./logs/logstash/*
rm -rf ./logs/zookeeper/*