File tree Expand file tree Collapse file tree 2 files changed +6
-2
lines changed Expand file tree Collapse file tree 2 files changed +6
-2
lines changed Original file line number Diff line number Diff line change 1
1
#! /bin/bash
2
2
3
3
TRIES=3
4
+ HOSTNAME=" <tablespace-db-hostname>"
5
+ PASSWORD=" <tablespace-db-password>"
4
6
5
7
cat queries.sql | while read query; do
6
8
sync
7
9
echo 3 | sudo tee /proc/sys/vm/drop_caches
8
10
9
11
echo " $query " ;
10
12
for i in $( seq 1 $TRIES ) ; do
11
- psql ' host=<hostname> port=5432 dbname=csdb user=csuser password=<password> sslmode=require' -c ' \timing' -c " $query " | grep ' Time'
13
+ psql " host=$HOSTNAME port=5432 dbname=csdb user=csuser password=$PASSWORD sslmode=require" -c ' \timing' -c " $query " | grep ' Time'
12
14
done ;
13
15
done ;
Original file line number Diff line number Diff line change 1
1
#! /bin/bash
2
2
3
3
TRIES=3
4
+ HOSTNAME=" <tablespace-db-hostname>"
5
+ PASSWORD=" <tablespace-db-password>"
4
6
5
7
cat queries.sql | while read query; do
6
8
sync
7
9
echo 3 | sudo tee /proc/sys/vm/drop_caches
8
10
9
11
echo " $query " ;
10
12
for i in $( seq 1 $TRIES ) ; do
11
- psql ' host=<hostname> port=5432 dbname=csdb user=csuser password=<password> sslmode=require' -c ' \timing' -c " $query " | grep ' Time'
13
+ psql " host=$HOSTNAME port=5432 dbname=csdb user=csuser password=$PASSWORD sslmode=require" -c ' \timing' -c " $query " | grep ' Time'
12
14
done ;
13
15
done ;
You can’t perform that action at this time.
0 commit comments