Installing PostgreSQL on MEPIS (KDE) *edited*

MEPIS is now built on top of Ubuntu and there are plenty of sites that show how to install PostgreSQL on Ubuntu, but not many that made it easy to do it in KDE. So here are some of my notes. First, there was a site that was very helpful in laying out the foundation of installing PostgreSQL, and that site is

First however, is open up Symantic and mark for installation “postgresql-8.1” and “pgadmin3”. Yes, there are some dependancies but the download is extremely quick.

Here’s where I stumbled in my limited Linux knowledge. The instructions say to use “sudo” but that won’t work for us on MEPIS. First, we need to become the super user by doing our su and then entering the password. If we don’t do this first, the next lines will prompt us for a password which we haven’t set yet. Next, we really get started by entering su - postgres to impersonate the “postgres” user, then we can type the command: psql template1 postgres to enter the command line interface for PostgreSQL.

We then do the ALTER USER postgres WITH PASSWORD '*password*'; command where the *password* is the password you would like for the database. \q quits the interface. Type exit to quit the impersonation of postgres.

Now, switch over to super user mode by going into “su” and enter your password. Edit the “/etc/postgresql/8.1/main/postgresql.conf” file and the “/etc/postgresql/8.1/main/pg_hba.conf” file per his instructions. I used KWrite instead of GEdit, so the command was kwrite /etc/postgresql/8.1/main/postgresql.conf & and kwrite /etc/postgresql/8.1/main/pg_hba.conf &

Exit back to your normal user level.

After editing the config files and restarting PostgreSQL, you can fire up PGAdmin3 by entering /usr/bin/pgadmin3 I created a shortcut on my desktop to the application as I know that I’ll be using that shortcut a lot.

I’m just beginning with PostgreSQL, but I think it will serve me nicely for many years into the future.

Leave a Reply