Showing results for 
Search instead for 
Did you mean: 

PEM 7 Agent Install on a Linux 6/7 QuickStart (less than five minutes)

EDB Team Member



Quickly (less than five minutes) install and run a default PEM 7 Agent on a Linux 6/7. 



Running instance of RHEL 6/7 with root access

Preconfigured database 

username and password from the PEM server with pem_agent role

EDB YUM repository username and password


Steps (as root user)

# Make sure umask is 0022
umask 0022

# Make sure /tmp can be executed from (if in a hardened
# environment)
# Make sure anything in the Postgres registry is valid (if exists)
cat /etc/postgres-reg.ini

# Setup YUM repository for installing EPAS as the PEM
# repository
export EDB_YUM_USERNAME=<yum user>
export EDB_YUM_PASSWORD=<yum password>

export DATABASEHOST= # USER yours here

export PEM_USER=enterprisedb #username from the PEM Server with pem_agent role
export PEM_SERVER_PASSWORD=enterprisedb #password of the user from the PEM Server 


rpm -Uvh
sed -i "s/<username>:<password>/$EDB_YUM_USERNAME:$EDB_YUM_PASSWORD/g" /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 the pre-prerequisites

yum install -y epel-release wxBase pem-agent

/usr/pem/agent/bin/pemworker --register-agent --pem-server $DATABASEHOST --pem-port 5444 --pem-user $PEM_USER

if [ `cat /etc/redhat-release | grep "release 7" | wc -l` = 1 ]
   systemctl start pemagent
elif [ `cat /etc/redhat-release | grep "release 6" | wc -l` = 1 ]
  /etc/init.d/pemagent start

#The service will confirm that it is starting the agent; when the agent is registered and started, it will be displayed on the Global #Overview dashboard and in the Objectbrowser tree control of the PEM web interface.

#To check the configuration file of your agent user the following Command

cat /usr/pem/agent/etc/agent.cfg





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