Re: pg_dumpall between Linux and FreeBSD.

From: frbn <frbn(at)efbs-seafrigo(dot)fr>
To: Francisco J Reyes <francisco(at)natserv(dot)net>
Cc: pgsql General List <pgsql-general(at)postgresql(dot)org>
Subject: Re: pg_dumpall between Linux and FreeBSD.
Date: 2002-09-13 17:22:22
Message-ID: 3D821ECE.5000305@efbs-seafrigo.fr
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Francisco J Reyes a écrit:
> 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).
>
> Any suggestions on how to easily move data between these two systems?
> I have only a handfull databases so doing individual pg_dumps may work,
> but my fear is that if someone in my team makes a new DB (ie for new
> development) that they may not tell me and I may not find out about it
> until the machine has crashed and they come asking for a restore. :-)

vipw

change the username *ONLY* (don't touch the IDs)

vi /etc/group

change its groupname, if your user has its own group

that should be ok.

keep in mind that scripts doing such as 'su - pgsql' need an update too. (sed is your friend)

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Williams, Travis L, NPONS 2002-09-13 17:47:46 Can't run configure
Previous Message Nigel J. Andrews 2002-09-13 17:01:47 Re: problem in select