|
|
@ -73,7 +73,8 @@ XXX set up user postgres to ssh to all nodes ?
|
|
|
|
|
|
|
|
|
|
|
|
https://www.postgres-xl.org/documentation/pgxc-ctl.html
|
|
|
|
https://www.postgres-xl.org/documentation/pgxc-ctl.html
|
|
|
|
|
|
|
|
|
|
|
|
Run:
|
|
|
|
Log into pgxl1, run:
|
|
|
|
|
|
|
|
sudo su - postgres
|
|
|
|
pgxc_ctl
|
|
|
|
pgxc_ctl
|
|
|
|
At PGXC promt run:
|
|
|
|
At PGXC promt run:
|
|
|
|
prepare config empty
|
|
|
|
prepare config empty
|
|
|
@ -82,7 +83,7 @@ prepare config empty
|
|
|
|
add gtm master name host port dir
|
|
|
|
add gtm master name host port dir
|
|
|
|
add gtm slave name host port dir
|
|
|
|
add gtm slave name host port dir
|
|
|
|
add gtm_proxy name host port dir
|
|
|
|
add gtm_proxy name host port dir
|
|
|
|
add coordinator master name host port pooler dir< extraServerConf extraPgHbaConf
|
|
|
|
add coordinator master name host port pooler dir extraServerConf extraPgHbaConf
|
|
|
|
add coordinator slave name host port pooler dir archDir
|
|
|
|
add coordinator slave name host port pooler dir archDir
|
|
|
|
add datanode master name host port pooler dir waldir extraServerConf extraPgHbaConf
|
|
|
|
add datanode master name host port pooler dir waldir extraServerConf extraPgHbaConf
|
|
|
|
add datanode slave name host port pooler dir waldir archDir
|
|
|
|
add datanode slave name host port pooler dir waldir archDir
|
|
|
@ -91,14 +92,17 @@ add datanode slave name host port pooler dir waldir archDir
|
|
|
|
|
|
|
|
|
|
|
|
XLDIR=/usr/local/pgsql/
|
|
|
|
XLDIR=/usr/local/pgsql/
|
|
|
|
pgxc_ctl prepare config empty
|
|
|
|
pgxc_ctl prepare config empty
|
|
|
|
|
|
|
|
|
|
|
|
pgxc_ctl add gtm master gtm_1 pg-pgxl-gtm-1 20001 "$XLDIR/gtm"
|
|
|
|
pgxc_ctl add gtm master gtm_1 pg-pgxl-gtm-1 20001 "$XLDIR/gtm"
|
|
|
|
XXX slave or proxy?
|
|
|
|
XXX slave or proxy?
|
|
|
|
pgxc_ctl add gtm slave gtm_2 pg-pgxl-gtm-2 20002 "$XLDIR/gtm"
|
|
|
|
pgxc_ctl add gtm slave gtm_2 pg-pgxl-gtm-2 20001 "$XLDIR/gtm"
|
|
|
|
pgxc_ctl add gtm_proxy gtm_2 pg-pgxl-gtm-2 20002 "$XLDIR/gtm"
|
|
|
|
pgxc_ctl add gtm_proxy gtm_2 pg-pgxl-gtm-2 20001 "$XLDIR/gtm"
|
|
|
|
|
|
|
|
|
|
|
|
pgxc_ctl add coordinator master coord_1 pg-pgxl-coord-1 30001 31001 "$XLDIR/coord-1" none none
|
|
|
|
pgxc_ctl add coordinator master coord_1 pg-pgxl-coord-1 30001 31001 "$XLDIR/coord-1" none none
|
|
|
|
XXX master or slaves?
|
|
|
|
XXX master or slaves?
|
|
|
|
pgxc_ctl add coordinator master coord_2 pg-pgxl-coord-2 30002 31002 "$XLDIR/coord-2" none none
|
|
|
|
pgxc_ctl add coordinator master coord_2 pg-pgxl-coord-2 30001 31001 "$XLDIR/coord-2" none none
|
|
|
|
pgxc_ctl add coordinator master coord_3 pg-pgxl-coord-3 30003 31003 "$XLDIR/coord-3" none none
|
|
|
|
pgxc_ctl add coordinator master coord_3 pg-pgxl-coord-3 30001 31001 "$XLDIR/coord-3" none none
|
|
|
|
|
|
|
|
|
|
|
|
pgxc_ctl add datanode master datanode_1 pg-pgxl1 40001 41001 "$XLDIR/data-1" none none none
|
|
|
|
pgxc_ctl add datanode master datanode_1 pg-pgxl1 40001 41001 "$XLDIR/data-1" none none none
|
|
|
|
XXX master or slaves?
|
|
|
|
XXX master or slaves?
|
|
|
|
pgxc_ctl add datanode master datanode_2 pg-pgxl2 40001 41001 "$XLDIR/data-2" none none none
|
|
|
|
pgxc_ctl add datanode master datanode_2 pg-pgxl2 40001 41001 "$XLDIR/data-2" none none none
|
|
|
@ -109,13 +113,32 @@ pgxc_ctl monitor all createdb -p 30001 test
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
# Open Up firewall.
|
|
|
|
# Open Up firewall.
|
|
|
|
|
|
|
|
Open up firewall ports for postgres and others.....
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
# OmniDB
|
|
|
|
# OmniDB
|
|
|
|
git clone https://github.com/OmniDB/OmniDB
|
|
|
|
wget https://omnidb.org/dist/2.12.0/omnidb-server_2.12.0-debian-amd64.deb
|
|
|
|
|
|
|
|
dpkg -i omnidb-server_2.12.0-debian-amd64.deb
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Open firewall port 8000 and 25482
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
This file isn't used: /opt/omnidb-server/omnidb.conf
|
|
|
|
|
|
|
|
In the pre-packaged .deb, it runs as root... Config is here:
|
|
|
|
|
|
|
|
/root/.omnidb/omnidb-server/omnidb.conf
|
|
|
|
|
|
|
|
listening_address = 0.0.0.0
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Add Postgres-XL plugin:
|
|
|
|
|
|
|
|
wget https://omnidb.org/dist/plugins/omnidb-xl_1.0.0.zip
|
|
|
|
|
|
|
|
unzip omnidb-xl_1.0.0.zip
|
|
|
|
|
|
|
|
sudo cp -r plugins/ static/ /opt/omnidb-server/OmniDB_app/
|
|
|
|
|
|
|
|
sudo systemctl restart omnidb
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Log in with admin/admin and set up users/pass.
|
|
|
|
|
|
|
|
|
|
|
|
# Notes
|
|
|
|
# Notes
|
|
|
|
Maybe add build dependency python3-dev (?) for PL/Python shared library.
|
|
|
|
Maybe add build dependency python3-dev (?) for PL/Python shared library.
|
|
|
|
Maybe gettext.
|
|
|
|
Maybe gettext.
|
|
|
|
Maybe OpenSSL.
|
|
|
|
Maybe OpenSSL.
|
|
|
|
XXX change prefix ?
|
|
|
|
XXX change prefix ?
|
|
|
|
|
|
|
|
|
|
|
|