Home PostgreSQL Aubit4gl Install Setup

Installing PostgreSQL

OpenSSA is optimised for PostgreSQL version 8.1.x
Download and install the latest version from www.postgreSQL.org

Following are steps to be taken to install on a Fedora Core 4 or 5 platform.

Assuming that the downloaded source tarball is saved in /usr/local/download diredctory, and PostgreSQL to be installed in default location /usr/local/pgsql.

  1. Login as "root" and add a postgreSQL master user pgsql and create the installation directory.
    adduser -u 70 -d /usr/local/pgsql pgsql
  2. Expand the downloaded PostgreSQL tarball
    cd /usr/local
    tar xzf /usr/local/download/postgresql-8.1.4.tar.gz
    or if bzip2 version is downloaded
    tar xjf /usr/local/download/postgresql-8.1.4.tar.bz2
  3. Compiling and install PostgreSQL
    cd postgreSQL-8.1.4
    make install
  4. Set up environment: add following line at end of /etc/bashrc ...
    export PGDATA=/usr/local/pgsql/data
    and source it
    . /etc/bashrc
  5. Add the bold lines in /etc/profile ... last line is optional, but ease execution ...
    if [ "$EUID" = "0" ]; then
    	pathmunge /sbin
    	pathmunge /usr/sbin
    	pathmunge /usr/local/sbin
    pathmunge /usr/local/pgsql/bin after
    pathmunge /usr/local/aubit4gl/bin after
    pathmunge . after
    and source it
    . /etc/profile
  6. Create a new file /etc/ld.so.conf.d/pgsql.conf with following line
    and activate it
  7. Initialize database, for first time installation only, you will wipe out all existing databases.
    su - pgsql
  8. Start database backend, still login as user pgsql
    /usr/local/pgsql/bin/pg_ctl start -D /usr/local/pgsql/data \
    	-s -l /usr/local/pgsql/data/serverlog
  9. Alternatively, download and save this script to /etc/rc.d/init.d
    To enable the script in system startup/shutdown
    cd /etc/rc.d/init.d
    chmod 755 pgsql.sh
    chkconfig --add pgsql.sh
  10. To start PostgreSQL manually by root,
    service pgsql.sh start
    /etc/rc.d/init.d/pgsql.sh start
  11. While login as user pgsql, create a supervisor role for root and/or your userid.
    Enter name of role to add: root
    Shall the new role be a superuser? (y/n) y
  12. Check available database
    psql -l
  13. Proceed to install Aubit4gl and OpenSSA