About the virtual machines and network details, see this blog post
Run on both servers:
yum install postgresql95-server postgresql95-contrib pgpool-II-95
package main | |
import ( | |
"log" | |
"time" | |
"github.com/go-pg/pg" | |
) | |
const maxWorkers = 5 |
About the virtual machines and network details, see this blog post
Run on both servers:
yum install postgresql95-server postgresql95-contrib pgpool-II-95
. /etc/os-release
sudo sh -c "echo 'deb http://download.opensuse.org/repositories/devel:/kubic:/libcontainers:/stable/xUbuntu_${VERSION_ID}/ /' > /etc/apt/sources.list.d/devel:kubic:libcontainers:stable.list"
wget -nv https://download.opensuse.org/repositories/devel:kubic:libcontainers:stable/xUbuntu_${VERSION_ID}/Release.key -O Release.key
sudo apt-key add - < Release.key
sudo apt-get update -qq
sudo apt-get -qq -y install buildah
``
-- tested in PostgreSQL 8.4.4 | |
DROP VIEW IF EXISTS vw_all_table_locks CASCADE; | |
CREATE VIEW vw_all_table_locks AS | |
SELECT | |
pg_namespace.nspname as schemaname, | |
pg_class.relname as tablename, | |
pg_locks.mode as lock_type, | |
age(now(),pg_stat_activity.query_start) AS time_running | |
FROM pg_class | |
JOIN pg_locks on pg_locks.relation = pg_class.oid |
#!/bin/bash -ex | |
export PGBIN=/usr/pgsql-9.3/bin | |
export PGUSER=postgres | |
export PGDATABASE=bench | |
export DATADIR=/dados/pgbench | |
export CLUSTER_LOG=/tmp/benchmark.log | |
export TOTAL_CPUS=$(grep 'cpu cores' /proc/cpuinfo | uniq | awk '{print $NF}') |
From: https://www.stereolabs.com/docs/docker/building-arm-container-on-x86/
Install the necessary packages:
sudo dnf install qemu qemu-user-binfmt qemu-user-static
Run qemu setup:
--- | |
- hosts: localhost | |
connection: local | |
vars: | |
gather_facts: False | |
vars: | |
keypair: "my-keypair-name" | |
instance_type: m4.large | |
security_group: | |
- "vpc-group-1" |
version: '3.1' | |
volumes: | |
prometheus_data: {} | |
grafana_data: {} | |
services: | |
prometheus: | |
image: prom/prometheus | |
volumes: |