[OPEN-ILS-GENERAL] How do I go back to a clean EG/postgres schema?
Yamil Suarez
ysuarez at berklee.edu
Fri Feb 10 16:24:37 EST 2012
On Feb 10, 2012, at 1:50 PM, Bill Erickson wrote:
> On Fri, Feb 10, 2012 at 12:38:36PM -0500, Dan Scott wrote:
>> Password, user name, host name, port, and database name get
>> pulled from
>> opensrf.xml if not supplied, so they would be unnecessary in this
>> case
>> too.
>
> Even better! Thanks, Dan.
>
> -b
Thank you both, but I have two follow up questions.
1) In the eg_db_config.pl I set two sets of passwords and usernames,
which one coudl be skipped. I assume if I left them in there would be
now real harm?
2) Is the content listed in the official docs for backing up a small
EG DB instance still recommended by those more experienced than me?
http://docs.evergreen-ils.org/2.1/html/backingup.html
-----------------------------------------
Backing up the Evergreen Database
Most of the critical data for an Evergreen system – patrons,
bibliographic records, holdings, transactions, bills – is stored in
the PostgreSQL database. You can therefore use normal PostgreSQL
backup procedures to backup this data. For example, the simplest
method of backing up the Evergreen database is to use the pg_dump
command to create a live backup of the database without having to
interrupt any Evergreen services. Here is an example pg_dump command
which will dump a local Evergreen database into a the file
evergreen_db.backup:
pg_dump -U evergreen -h localhost -f evergreen_db.backup evergreen
To restore the backed up database into a new database, create a new
database using the template0 database template and the UTF8 encoding,
and run the psql command, specifying the new database as your target:
createdb -T template0 -E UTF8 -U evergreen -h localhost new_evergreen
psql -U evergreen -h localhost -f evergreen_db.backup new_evergreen
This method of backup is only suitable for small Evergreen instances.
Larger sites should consider implementing continuous archiving (also
known as “log shipping”) to provide more granular backups with lower
system overhead. More information on backing up PostgreSQL databases
can be found in the official PostgreSQL documentation.
---------------------------------------------
Thanks again,
Yamil
More information about the Open-ils-general
mailing list