-
-
Save altmas5/30ddc6c975cf2e135b6fb7b358c33eed to your computer and use it in GitHub Desktop.
Clean all data in graylog2 without deleting settings, with full restart
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
systemctl stop elasticsearch.service | |
systemctl stop graylog-server.service | |
rm -rf /var/lib/elasticsearch/nodes/0/indices/* | |
# IF YOU HAVE AUTH USE THIS LINE - mongo graylog2 --eval "db.auth('graylog2', 'PASSWORD'); db.message_counts.remove();" | |
mongo graylog2 --eval "db.message_counts.remove();" | |
systemctl start elasticsearch.service | |
systemctl start graylog-server.service |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment