Search Postgresql Archives

Re: creation permissions when moving from 7.2 -> 7.4

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Kevin DeGraaf <kevin@kevindegraaf.net> writes:
>   Restoring from [ajp.tar] ...
>   pg_restore: [archiver (db)] could not execute query: ERROR:
>   permission denied to create database

> Given that (a) I'm using PGUSER=postgres and (b) my pg_hba.conf should be
> sufficiently liberal anyway, I'm wondering why this is not working.

I think you've got the other user not permitted to create databases?
I believe 7.4's pg_dump creates a script that handles this case
correctly, but 7.2's doesn't.  (A hint for next time is that it's
usually best to use the latest available pg_dump.)

> Also, template0 failed due to a null tar file, and template1 failed due to
> it already existing.  Would I be correct in assuming that the globals.sql
> step takes care of the necessary items in template1, and that I can leave
> template0 alone altogether?

template0 is do-not-touch.  You need only worry about template1 if you
created stuff in it to have copied to other databases by CREATE
DATABASE.  (The most common thing of that sort is procedural languages;
you'd be best advised to use "createlang" to reinsert them anyway.)

			regards, tom lane

---------------------------(end of broadcast)---------------------------
TIP 3: if posting/reading through Usenet, please send an appropriate
      subscribe-nomail command to majordomo@postgresql.org so that your
      message can get through to the mailing list cleanly

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux