mirror of
https://github.com/Chia-Network/chia-blockchain.git
synced 2026-09-12 02:24:38 -05:00
* New database table to store headers * Loading blockchain only loads headers into memory instead of header blocks (header + proofs), speeds up the startup, and reduces normal operation memory usage by 80% * Fix deadlock issues with store class * Make memory store access synchronous, to reduce use of locks, this improves performance of block and unfinished block processing * Remove locks from reads of DB, only lock for writes * Cleaner configuration system with argparse * Log to file by default, configurable to stdout * Proof of space binary and create_plots scripts allow passing in temp and final directories
27 lines
419 B
Bash
Executable File
27 lines
419 B
Bash
Executable File
_kill_servers() {
|
|
PROCS=`ps -e | grep -E 'chia_|vdf_server' | awk '!/grep/' | awk '{print $1}'`
|
|
if [ -n "$PROCS" ]; then
|
|
echo "$PROCS" | xargs -L1 kill
|
|
fi
|
|
}
|
|
|
|
_kill_servers
|
|
|
|
BG_PIDS=""
|
|
_run_bg_cmd() {
|
|
"$@" &
|
|
BG_PIDS="$BG_PIDS $!"
|
|
}
|
|
|
|
|
|
_term() {
|
|
echo "Caught TERM or INT signal, killing all servers."
|
|
for PID in $BG_PIDS; do
|
|
kill -TERM "$PID"
|
|
done
|
|
_kill_servers
|
|
}
|
|
|
|
trap _term TERM
|
|
trap _term INT
|