cancel
Showing results for 
Search instead for 
Did you mean: 

EPAS 10 cluster on RHEL 6 or RHEL 7 QuickStart

EDB Team Member

Objective

Quickly (less than five minutes) install and run a default EPAS 10 cluster on RHEL 6 or RHEL 7

 

Prerequisites

Running instance of RHEL/CentOS 6/7 with root access

 

Components

There are three primary components to EPAS:

  1. EPAS 10 Installation (/var/lib/edb/as10/)

  2. EPAS 10 Cluster Directories (user configurable, but defaults to /var/lib/edb/as10/data)

    1. pg_hba.conf - Postgres Host Based Access file specifices who can connect to the cluster
    2. postgresql.conf - Postgres main configuration file with all other configuration settings for the cluster
  3. # # Congratulations! You have successfully installed, configured, and connected to your first EPAS 10 cluster.


##Here is a quick, complete example for installing EDB Postgres v10 on RHEL/CentOS 6/7:

#
# Install the new EDB Repo
#
yum install -y http://yum.enterprisedb.com/edbrepos/edb-repo-latest.noarch.rpm
yum install -y epel-release
#
# Configure the edb.repo username/password
#

#
# Enable EPAS 10, dependencies, and tools repositories
#
export YUM_USER=
export YUM_PASSWORD=


##Here is a quick, complete example for installing EDB Postgres v10 on RHEL/CentOS 6/7:
#
# Install the new EDB Repo
#
yum install -y http://yum.enterprisedb.com/edbrepos/edb-repo-latest.noarch.rpm
yum install -y epel-release
#
# Configure the edb.repo username/password
#
#
# Enable EPAS 10, dependencies, and tools repositories
#

sed -i "s/<username>:<password>/$YUM_USER:$YUM_PASSWORD/g" /etc/yum.repos.d/edb.repo
sed -i "\/edbas10/,/gpgcheck/ s/enabled=0/enabled=1/" /etc/yum.repos.d/edb.repo
sed -i "\/enterprisedb-dependencies/,/gpgcheck/ s/enabled=0/enabled=1/" /etc/yum.repos.d/edb.repo
sed -i "\/enterprisedb-tools/,/gpgcheck/ s/enabled=0/enabled=1/" /etc/yum.repos.d/edb.repo
#
# Install EPAS 10
#
#yum install -y edb-as10-server-core ##if you want to install just the core-database
yum install -y edb-as10-server
#
# Start the EPAS server and initialize a new Postgres
# data directory using the appropriate mechanism
# for the operating system
#
if [ `cat /etc/redhat-release | grep "release 7" | wc -l` = 1 ]
 then
  /usr/edb/as10/bin/edb-as-10-setup initdb
  su - enterprisedb -c "sed -i \"s/ident/md5/g\" /var/lib/edb/as10/data/pg_hba.conf" \
  && echo "host all all 0.0.0.0/0 md5" >>pg_hba.conf
  systemctl start edb-as-10
elif [ `cat /etc/redhat-release | grep "release 6" | wc -l` = 1 ]
 then
  service edb-as-10 initdb
  su - enterprisedb -c "sed -i \"s/ident/md5/g\" /var/lib/edb/as10/data/pg_hba.conf" \
  && echo "host all all 0.0.0.0/0 md5" >>pg_hba.conf
 service edb-as-10 start
fi


su - enterprisedb -c "psql -d postgres -c 'alter user enterprisedb identified by enterprisedb'"

# Change to "enterprisedb" user created by RPM installers above, and
# to test the cluster install
#

#
su - enterprisedb
/usr/edb/as10/bin/psql -d edb
select version();
select * from dual;
exit

 

 

Summary

This guide is intended to get you up and started with a default installation of EPAS 9.6 as quickly as possible.  This is just the beginning though.  Please stay tuned for more tutorials and demos of specific features available in EPAS 9.6.