Re: problems with moving a database

Поиск
Список
Период
Сортировка
От A.Bhuvaneswaran
Тема Re: problems with moving a database
Дата
Msg-id Pine.LNX.4.44.0305141054310.923-100000@Bhuvan.bksys.co.in
обсуждение исходный текст
Ответ на problems with moving a database  (Oliver Kullmann <O.Kullmann@Swansea.ac.uk>)
Ответы Re: problems with moving a database  (Oliver Kullmann <O.Kullmann@Swansea.ac.uk>)
Список pgsql-admin
> pg_dump -a -R -O -x DB1

Here pg_dump with -a, dumps only the data. Is it what you want? Does the
database exist in machine 2? If not, you should not use -a option. Rather,
use

$ pg_dump dbname -uf dbname.sql

which is enough to dump entire database.

>
> Now I get
>
> > psql -dDB2 -U oliver < DB1.dmp
> ERROR:  pg_class: Permission denied.

I highly suspect that it would be due to the non-super user trying to
access super user privileges. In your case, it would have happened like in
your laptop, the database owner is the super user and in your pc, the
database owner is not the super user. Check it. Note, pg_dump does update
pg_class to enable/disable the triggers.

regards,
bhuvaneswaran


В списке pgsql-admin по дате отправления:

Предыдущее
От: Travis Whitton
Дата:
Сообщение: Grant Question
Следующее
От: Oliver Kullmann
Дата:
Сообщение: Re: problems with moving a database