Re: Copy one database to another server

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

 



On Thu, May 2, 2013 at 3:01 PM, Huan Ruan <huan.ruan.it@xxxxxxxxx> wrote:
  • create a new db using the current one as a template. Easy to do and speed is acceptable. A bit downtime is ok, but it's only on the current server. Is there a way to move it to anther server?

  • FWIW, I recently set up a 160GB clone by simply piping from pg_dump over the network into psql, alleviating the need to dump to disk. In my case, the server did not have enough space to hold the pg_dump, so I had to stream it.

    pg_dump -Fp your_db | psql -h new_server -U postgres your_new_db

    You could also search the archives for caveats and other (and safer) ways to do this.

    [Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]

      Powered by Linux