You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

1.9 KiB

PoWA for PostgreSQL

https://powa.readthedocs.io

##############################################################################

Install on PostgreSQL Servers

Using upstream postresql's repos, not Debian's repos.

apt install postgresql-10-powa postgresql-10-pg-qualstats postgresql-10-pg-stat-kcache postgresql-10-hypopg

Add permissions for PoWA node

Configure postgres:

vim /etc/postgresql/10/main/postgresql.conf

Change:

shared_preload_libraries to (keeping citus):

shared_preload_libraries='citus,pg_stat_statements,powa,pg_stat_kcache,pg_qualstats'

Create databases, run on each pg1 pg2 pg3 pg4 server:

psql CREATE DATABASE powa ; \c powa CREATE EXTENSION pg_stat_statements; CREATE EXTENSION btree_gist; CREATE EXTENSION powa; CREATE EXTENSION pg_qualstats; CREATE EXTENSION pg_stat_kcache; CREATE EXTENSION hypopg; CREATE ROLE powa SUPERUSER LOGIN PASSWORD 'password' ;

##############################################################################

Install on Web Node

Set up Debian Stretch node

Install postgres repos:

echo 'deb http://apt.postgresql.org/pub/repos/apt/ stretch-pgdg main' > /etc/apt/sources.list.d/pgdg.list wget --quiet -O - https://www.postgresql.org/media/keys/ACCC4CF8.asc | sudo apt-key add - apt update apt dist-upgrade apt install postgresql-client-10

There isn't a package of powa-web for Debian.

Install dependencies:

apt install python python-psycopg2 python-sqlalchemy python-tornado

wget -O powa-web-3.1.4.tar.gz https://github.com/powa-team/powa-web/archive/3.1.4.tar.gz tar -zxvf powa-web-3.1.4.tar.gz cd powa-web-3.1.4 cp ./powa-web.conf-dist ./powa-web.conf ./powa-web

XXX setup user, startup scripts, etc.

##############################################################################

Admin Web Client

On workstation create tunnel:

ssh -N -C -L 58888:localhost:8888 powa

On workstation, in browser:

http://localhost:58888/ ##############################################################################