File tree Expand file tree Collapse file tree 3 files changed +51
-3
lines changed Expand file tree Collapse file tree 3 files changed +51
-3
lines changed Original file line number Diff line number Diff line change
1
+ #! /bin/bash
2
+
3
+ INSTDIR=` pwd` /tmp_install
4
+ export LD_LIBRARY_PATH=$INSTDIR /lib:$LD_LIBRARY_PATH
5
+ export PATH=$INSTDIR /bin:$PATH
6
+
7
+ pkill -U ` whoami` -9 -e postgres
8
+ pkill -U ` whoami` -9 -e pgbench
9
+
10
+ M=` pwd` /PGDATA
11
+ U=` whoami`
12
+
13
+ rm -rf $M || true
14
+ mkdir $M
15
+
16
+ rm -rf logfile.log || true
17
+
18
+ mk
19
+ initdb -D $M
20
+
21
+ # echo "work_mem = 2GB" >> $M/postgresql.conf
22
+ # echo "shared_buffers = 2GB" >> $M/postgresql.conf
23
+ pg_ctl -w -D $M -l logfile.log start
24
+ createdb $U
25
+ pgbench -i -s 300
26
+ pgbench -T 60 -c 15 -j 15 -P 5 --select-only -n $U
27
+
Original file line number Diff line number Diff line change
1
+ #! /bin/bash
2
+
3
+ # ##############################################################################
4
+ #
5
+ # Use pgbench to scale OLTP load with FDW + partitioning machinery
6
+ #
7
+ # ##############################################################################
8
+
9
+ PGINSTALL=` pwd` /tmp_install/
10
+
11
+ export LD_LIBRARY_PATH=$PGINSTALL /lib:$LD_LIBRARY_PATH
12
+ export PATH=$PGINSTALL /bin:$PATH
13
+
14
+ export PGDATABASE=shardman
15
+ export PGHOST=localhost
16
+ export PGUSER=` whoami`
17
+
18
+ pgbench -p 5432 -T 60 -P 5 -c 5 -j 5 --select-only -n &
19
+ pgbench -p 5433 -T 60 -P 5 -c 5 -j 5 --select-only -n &
20
+ pgbench -p 5434 -T 60 -P 5 -c 5 -j 5 --select-only -n &
21
+
Original file line number Diff line number Diff line change @@ -47,9 +47,9 @@ initdb -D $D3 -E UTF8 --locale=C
47
47
echo " shared_preload_libraries = 'postgres_fdw'" >> $D1 /postgresql.conf
48
48
echo " shared_preload_libraries = 'postgres_fdw'" >> $D2 /postgresql.conf
49
49
echo " shared_preload_libraries = 'postgres_fdw'" >> $D3 /postgresql.conf
50
- echo " shared_buffers = 10GB" >> $D1 /postgresql.conf
51
- echo " shared_buffers = 10GB" >> $D2 /postgresql.conf
52
- echo " shared_buffers = 10GB" >> $D3 /postgresql.conf
50
+ # echo "shared_buffers = 10GB" >> $D1/postgresql.conf
51
+ # echo "shared_buffers = 10GB" >> $D2/postgresql.conf
52
+ # echo "shared_buffers = 10GB" >> $D3/postgresql.conf
53
53
echo " listen_addresses = '*'" >> $D1 /postgresql.conf
54
54
echo " listen_addresses = '*'" >> $D2 /postgresql.conf
55
55
echo " listen_addresses = '*'" >> $D3 /postgresql.conf
You can’t perform that action at this time.
0 commit comments