Debian – How to install PhpPgAdmin


Mimetypes-text-x-sql-iconAlways handy with a web based database tool. Here is how to install and access PhpPgAdmin on a Debian variant.

First to install the package.
apt-get install phppgadmin

Now your web panel is installed. Then you need to access it. If you are on a different computer than you install the PhpPgAdmin you will need to edit the config file to be able to access it. Here is what you need to do.

Comment out the line 127.0.0.0/255.0.0.0 allow from :: 1/128
And uncomment the line allow from all

Now you need to set a password for the root user. PostgreeSQL call the root user for postgres.
So no need to either su or sudo the postgres user.
sudo -u postgres psql (or su postgres, then start psql)

Inside the postgree database type this to set a password
\password
Enter the password twice as usual
\q
To quit.

Now you have set a password for the root user and made it accessible from everywhere.
I have installed it on 192.168.1.86, so I would need to type into my web browser
192.168.1.86/phppgadmin

Now use the postgres as user, and enter with your password. You might want to consider to restrict access to your database once everything is set up.

That´s it really.

Happy databasing!

Have any Question or Comment?

Leave a Reply