Update: These instructions have been tested and work fine in the latest version of Ubuntu (8.04, Hardy Heron).
[phpPgAdmin](http://www.phppgadmin.org/) is a web based GUI for administrating a [PostgreSQL](http://www.postgresql.org/) database server.
Here’s some quick notes on getting it installed easily on Ubuntu 7.10…
In the terminal enter the following:
$ sudo apt-get install phppgadmin
This will set up and install all of the phpPgAdmin packages. It will also set-up and configure Apache and php5 for you too if you haven’t installed these already.
Next we need to create a symlink to phpPgAdmin so that Apache can find it:
$ sudo ln -s /etc/phppgadmin/apache.conf /etc/apache2/conf.d/phppgadmin.conf
Now if you navigate to [http://localhost/phppgadmin](http://localhost/phppgadmin) you should be greeted with the phpPgAdmin screen. If your user account has a PostgreSQL account however, you will be logged in automagically.
Optionally, if you would like to be able to use the phpPgAdmin interface as the default ‘postgres’ administration account,[^1] you will need to do the following[^2]…
$ sudo gedit /usr/share/phppgadmin/conf/config.inc.php
Now find and change the following line
$conf[‘extra_login_security’] = true;
to
$conf[‘extra_login_security’] = false;
Save and close gedit. Now all you need to do is restart Apache.
$ sudo /etc/init.d/apache2 reload
Now if you head on over to [http://localhost/phppgadmin](http://localhost/phppgadmin) all should be ready for you.
[^1]: I am assuming here that you have set-up your PostgreSQL server using my [set-up instructions](/2007/11/05/install-posgresql-on-ubuntu-710/) and therefore have a password protected ‘postgres’ account and that logins require passwords.
[^2]: Please make sure you have read the above footnote and understand the security implications of allowing this type of access to your database server - if you have not secured your administration accounts, do it now!
Recent Comments