Re: Odd duplicate database - Mailing list pgsql-general

From Madison Kelly
Subject Re: Odd duplicate database
Date
Msg-id 496E4384.6080907@alteeve.com
Whole thread Raw
In response to Odd duplicate database  (Madison Kelly <linux@alteeve.com>)
Responses Re: Odd duplicate database  (Alvaro Herrera <alvherre@commandprompt.com>)
List pgsql-general
Forgot to mention, this is PostgreSQL 8.3.5 on Linux (Ubuntu 8.10, hey,
it's a devel machine!). :)

Madi

Madison Kelly wrote:
> Hi all,
>
>   My devel server has some wierdness happening. I tried to drop the
> database (reload from a copy from the production server) and I got this
> weird error:
>
> pg_dump: query returned more than one (2) pg_database entry for database
> "nexxia"
>
>   So I logged in as postgres and checked, and sure enough:
>
> template1=# \l
>         List of databases
>     Name    |  Owner   | Encoding
> ------------+----------+----------
>  deadswitch | digimer  | UTF8
>  nexxia     | digimer  | UTF8
>  nexxia     | digimer  | UTF8
>  postgres   | postgres | UTF8
>  template0  | postgres | UTF8
>  template1  | postgres | UTF8
> (6 rows)
>
>   So I tried to drop the database(s?) from the shell:
>
> template1=# DROP DATABASE nexxia ;
> DROP DATABASE
> template1=# \l
>         List of databases
>     Name    |  Owner   | Encoding
> ------------+----------+----------
>  deadswitch | digimer  | UTF8
>  nexxia     | digimer  | UTF8
>  postgres   | postgres | UTF8
>  template0  | postgres | UTF8
>  template1  | postgres | UTF8
> (5 rows)
>
> template1=# DROP DATABASE nexxia ;
> ERROR:  database "nexxia" does not exist
>
>   So I still have a phantom DB there. This is still true after stopping
> and restarting the daemon, too. When I try to connect to the database I
> get this:
>
> template1=# \c nexxia
> FATAL:  database "nexxia" does not exist
> Previous connection kept
>
>   Does this mean a connection is still open somewhere? If so, how did it
> survive the daemon restarting? More specifically, how do I clear it?
>
> Thanks!
>
> Madi
>


pgsql-general by date:

Previous
From: "Thom Brown"
Date:
Subject: Re: Change empty database from ASCII to UTF-8 encoded
Next
From: Alvaro Herrera
Date:
Subject: Re: Odd duplicate database