DEV Community

Muhammad Zeeshan
Muhammad Zeeshan

Posted on

Install PostgreSQL 16beta1 and AGE, along with possible error Solution's

Introduction

Apache AGE, which is an extension of PostgreSQL. It's a graphical representation of relational database. Currently it(AGE) supports PostgreSQL version 12 and 13. We are also working on its capability to support PG15 and 16. In this, we will be installing it for PostgreSQL 16beta1 and on linux operating system.

Create Directories

mkdir age16
cd age16
mkdir pg
cd pg

Enter fullscreen mode Exit fullscreen mode

Install required Dependencies

sudo apt-get install build-essential libreadline-dev zlib1g-dev flex bison

Enter fullscreen mode Exit fullscreen mode

After installing required dependencies. Now we will first install PostgreSQL 16beta1 and then AGE.

PostgreSQL

wget https://ftp.postgresql.org/pub/source/v16beta1/postgresql-16beta1.tar.gz && tar -xvf postgresql-16beta1.tar.gz && rm -f postgresql-16beta1.tar.gz

Enter fullscreen mode Exit fullscreen mode

This command will download and extract postgresql 16beta1.

If it successful it will be shown like this.

https://dev-to-uploads.s3.amazonaws.com/uploads/articles/y43hxs02qdqbmj0yp1bq.png

We have downloaded and extracted it successfully. Now move inside beta16 directory and install postgresql.

cd postgresql-16beta1
# configure by setting flags
./configure --enable-debug --enable-cassert --prefix=$(pwd) CFLAGS="-ggdb -Og -fno-omit-frame-pointer"

#install 
make install

Enter fullscreen mode Exit fullscreen mode

There could be an error of this type.

ERROR: `bison' is missing on your system. It is needed to create the
file `src/backend/parser/cypher_gram.c'. You can either get bison from a GNU mirror site
Enter fullscreen mode Exit fullscreen mode

To resolve this error you can visit this link.

Installing it will take a bit of time. After successful installation it will show a windows like this.

PostgreSQL installed

Now go back to main directory,

cd ../
cd ../
Enter fullscreen mode Exit fullscreen mode

AGE

Clone and install AGE from sources latest repository.

git clone https://github.com/panosfol/age
Enter fullscreen mode Exit fullscreen mode

This will clone and create a repo age. Go to age directory.

cd age
Enter fullscreen mode Exit fullscreen mode

Now checkout to latest branch and install age from that.

git checkout PG16
Enter fullscreen mode Exit fullscreen mode

install

make PG_CONFIG=/home/username/age16/pg/postgresql-16beta1/bin/pg_config install
Enter fullscreen mode Exit fullscreen mode

To check username, run whoami and replace it in the above command.

Now you can check if its successfully installed or not.

make PG_CONFIG=/home/username/age16/pg/postgresql-16beta1/bin/pg_config installcheck

Enter fullscreen mode Exit fullscreen mode

Currently its showing 19/24 test cases failed.

Install Check

You have successfully installed it now can work on it and contribute to this.

References

1. https://github.com/panosfol/age/tree/PG16

2. https://ftp.postgresql.org/pub/source/v16beta1/

Top comments (1)

Collapse
 
pekopeko profile image
Peko Peko

Link to the stackoverflow is dead