PostgreSQL is a powerful, open source object-relational database system.

learn more… | top users | synonyms

24
votes
3answers
19k views

How do I migrate my postgres data from 8.4 to 9.1?

I have upgraded my ubuntu development machine from 11.04 to 11.10. In the process my postgres was also upgraded from 8.4 to 9.1. But I seem to have lost all my data. If I look, I can see that my data ...
18
votes
7answers
32k views

How to install PostgreSQL on Ubuntu 13.04?

How to install PostgreSQL in Ubuntu 13.04? I followed by this tutorial, How to install postgreSQL 9-2 - UbuntuGeek.com But in logs it says: the package is deprecated and no longer will be used ...
17
votes
3answers
29k views

How do I upgrade to Postgres 9.2?

Just recently, I've read that PostgreSQL 9.2 is released. My Ubuntu 12.04 has PostgreSQL 9.1.5 installed. How can I update to 9.2 version? I tried apt-get update and apt-get upgrade but no updates for ...
16
votes
2answers
22k views

How to fix PostgreSQL installation

I upgraded from Maverick to Natty recently and everything went fine except during the dist-upgrade something went wrong with PostgreSQL. I've since tried reinstalling, removing, and even purging it ...
10
votes
2answers
33k views

Installing pgadmin 3 for Ubuntu 11.10 and postgresql 9.1

I've installed pgadmin3 on a remote ubuntu client and succesfully connected to the postgres db using: sudo apt-get install pgadmin3 Problem is that when connecting to the postgres 9.1 server it ...
9
votes
1answer
3k views

Postgres doesn't have hstore extension

I was trying to run the following command but i threw me any error. template1=# CREATE EXTENSION hstore ERROR: could not open extension control file ...
9
votes
6answers
7k views

What is the difference between “service restart” and “service reload”

I'm trying to understand the difference between service restart [someservice] and service reload [someservice]. I understand that "restart" restarts the service whereas "reload" reloads the ...
9
votes
1answer
3k views

How do I set which PostgreSQL version is to be used by default?

I have 2 different versions of PostgreSQL installed on my system (Ubuntu Lucid): /var/lib/postgresql/8.4 /var/lib/postgresql/9.0 By default, when I run a PostgreSQL command such as createdb or ...
8
votes
3answers
33k views

How do I find the path to pg_hba.conf from the shell?

I would like to obtain the path to pg_hba.conf from the shell. The path varies between versions of PostgreSQL. For instance, for 8.4 and 9.1: /etc/postgresql/8.4/main/pg_hba.conf ...
7
votes
2answers
9k views

rails & libpq-dev nasty dependencies

I don't know if this question belongs here, but I'll take a shot. Hi. I'm running ubuntu 11.10 dual-boot with windows vista on my machine. On Ubuntu, I've installed RVM, rails gem, & PostgreSQL ...
7
votes
5answers
12k views

Problem Installing and configuring PostgreSQL

I am a newbie here and to the server administration. A couple of days back I have registered a server with Hetzner with Ubuntu 11.04. I intend to work with PostgreSQL, for which I have installed ...
7
votes
2answers
4k views

PostgreSQL 9.1 adminpack install

everywhere I see guides for postgre, it seems to be on version 8.4. In that case the instruction is: sudo -u postgres psql < /usr/share/postgresql/8.4/contrib/adminpack.sql that location doesn't ...
7
votes
2answers
3k views

What is the easiest way to install PostGIS?

What is the easiest way to install postgis on Ubuntu Server 11.10? apt-get install ...
6
votes
2answers
3k views

Where can I get a Postgres 9.0 package?

I want to use Postgres 9.0 in Ubuntu. Does anybody know any repository that already has the debian package for Postgres 9.0? Do you think I should wait for the next Ubuntu release or Postgres 9.0 is ...
6
votes
3answers
2k views

How to manually restart services affected by apt upgrades?

How can I issue apt upgrades without automatically stopping/starting daemons? I'd like to manually restart services. To cite a specific example: I'll revisit a long-running machine and run sudo ...
6
votes
1answer
2k views

How do i install postgresql-8.3?

I get > sudo apt-get install postgresql-8.3 Reading package lists... Done Building dependency tree Reading state information... Done Package postgresql-8.3 is not available, but is referred ...
5
votes
2answers
3k views

apt-get upgrade stuck on postgresql dependency

I ran sudo apt-get upgrade on my 12.04 server, and I have become stuck with a PostgreSQL dependency. The console output (of sudo apt-get -f install) is below: dpkg: dependency problems prevent ...
5
votes
2answers
7k views

Where is a postgresql 9.1 database stored in ubuntu 12.04?

I installed and created a Postgresql database on ubuntu. I then created the database using the following command: sudo su postgres createdb mydatabase However, I can't figure out where the database ...
5
votes
1answer
2k views

Postgres-xc won't uninstall (Fails on Stopping Co-ordinators)

I was doing some rails development and accidentally installed postres-xc instead of the normal postgres package. I immediately went to remove postgres-xc, but apt-get will not uninstall it. I also ...
5
votes
1answer
627 views

Why isn't the new “postgres” user I created showing up in User Accounts?

I just did a fresh install of Ubuntu 12.04 on a Dell Inspiron 1545, then downloaded & installed all the latest updates. Now when I create a new user postgres in the "User Accounts..." window, it ...
4
votes
2answers
3k views

How to uninstall PostgreSQL installed from .run file?

I am a new Ubuntu 12.04 user and I'm using 64bit. This morning I installed Posgresql 9.2 from the graphical installer (not from Ubuntu repository) . Now I want to uninstall it, but I don't know how. ...
4
votes
2answers
340 views

Why is there a shell given to user for PostgreSQL?

cat /etc/passwd |grep postgre postgres:x:115:127:PostgreSQL administrator,,,:/var/lib/postgresql:/bin/bash apt-cache show postgresql Package: postgresql Priority: optional Section: database ...
4
votes
2answers
1k views

pgadmin III doesn't work due to “The server lacks instrumentation functions.”

When pgAdmin III is used to open a PostgreSQL database the following message appears. There does not seem to be any obvious package listed in the Ubuntu Software Center for this. The server lacks ...
4
votes
3answers
6k views

pgadmin3: Unable to initialize gtk, is DISPLAY set properly? [closed]

I'm having some trouble getting pgadmin3 to run on a remote server. I'm logging in to the server using SSH with the -X option. When I first installed pgadmin3, I was able to launch it using the ...
3
votes
3answers
17k views

How do I install pgAdmin III for postgreSQL 9.2?

I have a Windows server that runs postgresql 9.2. I want to hit it using pgAdmin III from my Ubuntu 12.10 workstation box. I installed pgAdmin III from synaptic and also tried direct download from ...
3
votes
2answers
8k views

How can I update pgadmin3 to v1.14?

I installed Ubuntu 11.10 yesterday. From the repos I installed postgresql and pgadmin3. postgresql 9.1 is the current version but it seems pgadmin3 v1.12 is not properly compatible with 9.1. How can ...
3
votes
1answer
611 views

Installing postgres removes rabbitmq and vice versa. How to make both stay?

I need both rabbitmq-server and postgresql to be installed on my machine and apt-get installing one removes the other. Here is the output from install commands: $ sudo apt-get install postgresql ...
3
votes
4answers
13k views

Uninstall Postgresql 9.1.1

I have Postgresql 9.1.1 in my Ubuntu 12.04 which got installed due to automatic upgrades and whenever I uninstall it using the command: sudo apt-get --purge remove postgresql-9.1.1 I get an error ...
3
votes
1answer
139 views

How to run postbooks server in Ubuntu?

I installed post-book accounting software from Ubuntu software center in 14.04 LTS. Also installed post-book demo database and PostgreSQL. But I cannot able to run the post-book server. How can I ...
3
votes
1answer
61 views

juju override defaults in service

Working on the postgresql charm a bit, and I'm wondering if there is a way to supply overrides for default values in a "juju-way". In my charm that will be consuming the services provided by ...
3
votes
1answer
593 views

I don't want to store passwords in an unencrypted file

I'm using Ubuntu 12.04 LTS on my developer machine and just realized that psql stores passwords in '~/.pgpass'. Furthermore this file is unencrypted. So anyone who has super user rights (i.e. is in ...
3
votes
1answer
5k views

Postgres - could not create shared memory segment: Invalid argument

Shmmax, Shmall, I just can't win ;) I've tried changing around my /etc/sysctl.d/30-postgresql-shm.conf file a fair bit uncommenting and changing the kernel.shmmax and kernel.shmall a bit but it ...
3
votes
2answers
1k views

How do I downgrade PostgreSQL?

In my ubuntu 12.04 x64 I installed PostgreSQL 8.4. It got automatically upgraded to 9.1.1. Due to some inconsistencies, I want to downgrade it to 8.4. How can I do this using the terminal?
3
votes
1answer
704 views

Which Ubuntu version for PostgreSQL 9?

For a database server that will be running in its own VPS: Is it better-supported to install the latest Ocelot 11.10 release with the standard package for postgresql9, or to install 10.04 LTS with ...
3
votes
2answers
1k views

postgresql broken after 14.04 despite succesful pg_upgrade [SOLVED]

I'm running an Ubuntu VPS where i'm am upgrading to 14.04. everything has gone smoothly so far. Except the PostgreSQL migration from 9.1 to 9.3. The server hosts a Django 1.6 site and the traceback ...
3
votes
1answer
2k views

pg_connect(): Unable to connect to PostgreSQL server

I have read multiple articles detailing this fix for this exact issue. I have tried all kinds of variations of editing the pg_hba.conf file but no luck I still get the following error in my Apache log ...
2
votes
3answers
5k views

Uninstall postgresql from Ubuntu

I simply don't understand what's going on. sudo apt-get remove postgresql results in: Reading package lists... Done Building dependency tree Reading state information... Done Package ...
2
votes
1answer
4k views

Trying to install Postgres 9.3 in a non-LTS version of Ubuntu, how do I go?

I'm trying to install Postgres 9.3 with the instructions here. But the install is failing. [ubuntu:~]$ lsb_release -c Codename: raring [ubuntu:~]$ [ubuntu:~]$ cat ...
2
votes
2answers
108 views

Will apt-get dist-upgrade blow away my PostgreSQL server setup?

I'm about to upgrade my webserver, my site relies heavily on PostgreSQL database and settings. I started apt-get dist-upgrade, and it says it wants to upgrade Postgres. I cancelled, but will it wipe ...
2
votes
3answers
4k views

pg_ctl: command not found, what package has this command?

I have installed pgadmin using the ubuntu software center and am trying to access a local database (recently downloaded from the internet). I have tried to run the pg_ctl command (running as postgres) ...
2
votes
1answer
1k views

I'm trying to install postgresql on 12.04, and it's just not working

I've got a new installation and I'm trying to get Postgresql working. The database was installed and I started a restoration from a dump on another machine, but that ran into problems because I had ...
2
votes
2answers
2k views

Installing postgres on 13.04: no valid OpenPGP data found [closed]

Following the UbuntuGeek instructions for installing Postgres on Ubuntu 13.04 (and reinforced here), I'm getting stuck at this command: wget --quiet -O - ...
2
votes
2answers
1k views

Cannot open port

I've been struggling to open the port 5432 for remote PostgreSQL access. Which I installed on a Ubuntu 10.04 desktop machine. Here is the shell log: xybrek@ubuntu:~$ sudo ufw allow 5432 [sudo] ...
2
votes
2answers
6k views

How do I install older PostgreSQL (8.4) in Ubuntu 12.04?

Well, it's the whole question. I installed 9.1 before, but I need older version now and I haven't yet found out how to do that.
2
votes
1answer
464 views

Remotely access postgresql database

I need to access a postgresql database from a remote machine on a VPS at DigitalOcean running 12.10 and postgresql 9.1. How do I do this? I noticed port 5432 is closed, how do I open this?
2
votes
3answers
1k views

Unmet dependencies. Try using -f

I'm running into the following error when I'm installing any package on 12.04. Reading package lists... Done Building dependency tree Reading state information... Done You might want to run ...
2
votes
1answer
4k views

Run a PostgreSQL instance locally

I'm trying to follow this tutorial, but at the beginning it says to run a postgresql instance "locally" instead of as a daemon using the following commands. $ initdb pg $ postgres -D pg & $ ...
2
votes
1answer
4k views

Packages having unmet dependencies: Broken Packages

When I try to install postgresql i get the following error: sudo apt-get install postgresql-client Some packages could not be installed. This may mean that you have requested an impossible ...
2
votes
1answer
644 views

How do i configure postgis

PostGIS has been installed on ubuntu server 11.10... Now how do i create a database, admin user, etc.. where does it get installed ls -l /etc/...?
2
votes
1answer
776 views

Error starting up postgresql in 12.10

The following NEW packages will be installed: libpq5 postgresql-9.1 postgresql-client-9.1 postgresql-client-common postgresql-common 0 upgraded, 5 newly installed, 0 to remove and 2 not upgraded. ...