Created
May 16, 2013 10:08
-
-
Save huksley/5590722 to your computer and use it in GitHub Desktop.
Clean all data in graylog2 without deleting settings, with full restart
This file contains 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 | |
service elasticsearch stop | |
service graylog2-server stop | |
killall -9 java | |
service apache2 stop | |
rm -Rf /opt/elasticsearch/data/* | |
# 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();" | |
service elasticsearch start | |
service graylog2-server start | |
service apache2 start |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment