forked from seokjeongeum/OpAdviserPrivate
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path123.sh
executable file
·33 lines (32 loc) · 1.06 KB
/
123.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
#!/bin/bash
chmod +x ./cluster.sh
./cluster.sh
workload="tpcc"
cd /
rm -rf oltpbench && \
git clone https://github.com/seokjeongeum/oltpbench.git
cd /oltpbench && \
ant bootstrap && \
ant resolve && \
ant build && \
chmod 777 /oltpbench/*
mysql -ppassword -e"drop database ${workload};"
mysql -ppassword -e"create database ${workload};"
/oltpbench/oltpbenchmark -b $workload -c /oltpbench/config/sample_${workload}_config.xml --create=true --load=true
cd ~/OpAdviserPrivate
export PYTHONPATH="."
workload="tpcc"
for optimize_method in "DDPG" "GA" "MBO" "SMAC"; do
lowercase="${optimize_method,,}"
for knob_num in 10 190; do
python3 scripts/optimize.py \
--config=scripts/cluster.ini \
--knob_config_file=scripts/experiment/gen_knobs/moreworkloads/${workload}_shap.json \
--knob_num=$knob_num \
--dbname=${workload} \
--workload=oltpbench_${workload} \
--oltpbench_config_xml=/oltpbench/config/sample_${workload}_config.xml \
--task_id="${workload}_${lowercase}_${knob_num}" \
--optimize_method="$optimize_method"
done
done