-O to remove owner

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

 



I am currently running these to commands in scripts to backup the postgresql databases.

/usr/bin/pg_dumpall -ch 127.0.0.1 -U postgres | gzip > "$backup_dir/postgresql-all-$timeslot-databases.gz"

/usr/bin/pg_dump $i -ch 127.0.0.1 -U postgres | gzip > "$backup_dir/postgresql-$i-$timeslot-database.gz"

I would like to remove all owners from all objects so when I do a restore all objects are owned by postgres. Can I just tack on -O after -U postgres?

/usr/bin/pg_dumpall -ch 127.0.0.1 -U postgres -O | gzip > "$backup_dir/postgresql-all-$timeslot-databases.gz"

Marc


[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