File tree Expand file tree Collapse file tree 4 files changed +19
-23
lines changed
Expand file tree Collapse file tree 4 files changed +19
-23
lines changed Original file line number Diff line number Diff line change 1+ #! /bin/bash
2+
3+ echo " Stopping VictoriaLogs"
4+ pidof victoria-logs-prod && kill ` pidof victoria-logs-prod`
5+
6+ echo " Dropping all data"
7+ rm -rf victoria-logs-data
Original file line number Diff line number Diff line change 22
33RELEASE_VERSION=v1.10.1-victorialogs
44
5- # stop the existing victorialogs instance if any and drop its data
6- while true
7- do
8- pidof victoria-logs-prod && kill ` pidof victoria-logs-prod` || break
9- sleep 1
10- done
11- rm -rf victoria-logs-data
12-
13- # download victorialogs
145wget -N https://github.com/VictoriaMetrics/VictoriaMetrics/releases/download/${RELEASE_VERSION} /victoria-logs-linux-amd64-${RELEASE_VERSION} .tar.gz
156tar xzf victoria-logs-linux-amd64-${RELEASE_VERSION} .tar.gz
16- echo " Downloaded victorialogs."
17-
18- # start victorialogs
19- ./victoria-logs-prod -loggerOutput=stdout -retentionPeriod=20y -search.maxQueryDuration=5m > server.log &
20-
21- while true
22- do
23- curl -s --fail http://localhost:9428/select/logsql/query -d ' query=_time:2100-01-01Z' && break
24- sleep 1
25- done
26-
27- echo " Started victorialogs."
Original file line number Diff line number Diff line change @@ -27,11 +27,12 @@ echo "4) 1000m"
2727echo " 5) all"
2828read -p " Enter the number corresponding to your choice: " choice
2929
30+ ./install.sh
31+
3032benchmark () {
3133 local size=$1
3234
33- # install is needed here in order to drop the previously ingested data
34- ./install.sh
35+ ./start.sh
3536
3637 ./load_data.sh " $DATA_DIRECTORY " " $size " " $SUCCESS_LOG " " $ERROR_LOG "
3738
@@ -44,6 +45,8 @@ benchmark() {
4445 ./count.sh | tee " ${OUTPUT_PREFIX} _bluesky_${size} m.count"
4546 # ./query_results.sh | tee "${OUTPUT_PREFIX}_bluesky_${size}m.query_results"
4647 ./run_queries.sh | tee " ${OUTPUT_PREFIX} _bluesky_${size} m.results_runtime"
48+
49+ ./drop_tables.sh # also stops VictoriaLogs
4750}
4851
4952case $choice in
Original file line number Diff line number Diff line change 1+ #! /bin/bash
2+
3+ # Do we run already?
4+ pidof victoria-logs-prod > /dev/null && exit 1
5+
6+ echo " Starting VictoriaLogs"
7+ ./victoria-logs-prod -loggerOutput=stdout -retentionPeriod=20y -search.maxQueryDuration=5m > server.log &
You can’t perform that action at this time.
0 commit comments