mirror of
https://bitbucket.org/jsuto/piler.git
synced 2024-12-24 19:30:12 +01:00
Added reindex.sh to util
Signed-off-by: Janos SUTO <sj@acts.hu>
This commit is contained in:
parent
b786174884
commit
a1b71bddf2
23
util/reindex.sh
Executable file
23
util/reindex.sh
Executable file
@ -0,0 +1,23 @@
|
||||
#!/bin/bash
|
||||
|
||||
set -o nounset
|
||||
set -o errexit
|
||||
set -o pipefail
|
||||
|
||||
INSTALL_PREFIX=/usr/local
|
||||
THRESHOLD=100000000
|
||||
|
||||
start_id=1
|
||||
stop_id=5000000
|
||||
|
||||
while [[ $start_id -lt $stop_id ]]; do
|
||||
y=$(( start_id + 9999 ))
|
||||
echo $start_id $y
|
||||
"${INSTALL_PREFIX}/bin/reindex" -f $start_id -t $y -p
|
||||
"${INSTALL_PREFIX}/libexec/piler/indexer.delta.sh"
|
||||
start_id=$(( start_id + 10000 ))
|
||||
|
||||
if [[ "$(stat -c %s /var/piler/sphinx/dailydelta1.spp)" -gt "$THRESHOLD" ]]; then
|
||||
"${INSTALL_PREFIX}/libexec/piler/indexer.main.sh"
|
||||
fi
|
||||
done
|
Loading…
Reference in New Issue
Block a user