On Wed, Sep 11, 2002 at 03:37:57PM -0400, Francisco J Reyes wrote:
> I have 1 FreeBSD machine and 1 Linux, Red Hat, machine.
> I will need to periodically do a pg_dumpall from the Linux machine to the
> FreeBSD machine.
>
> This has been a problem because on Linux the superuser ID is postgres and
> on FreeBSD it is pgsl.
>
> When I try to restore to the FreeBSD machine it crashes because it can not
> connect to the postgres user ID. I replaced all occurrences of postgres
> with pgsql to get the load to work, but it was very time consuming (2.9 GB
> file).
I'd suggest using sed to do the replace on the fly. They other possibility
is to do a grep -v '\connect'. This will remove all the connect requests
from the input stream. This means that the owner of each object will not be
what it used to be, but with GRANTs set up correctly you won't even notice.
--
Martijn van Oosterhout <kleptog@svana.org> http://svana.org/kleptog/
> There are 10 kinds of people in the world, those that can do binary
> arithmetic and those that can't.