Ok, before I really break something....
I Think I have the plug nearly set up. Upon running:
<path>/snapcreator --action quiesce --policy daily --profile POSTGRES
--config POSTGRES --verbose
It tries to run the command:
/bin/su - postgres -c "/usr/bin/psql -d fecru -U postgres --nopassword --single-transaction --file <path>/files/blah.sc
and it fails with return code 0: ERROR: WAL archiving is not active
I have RHEL6, using the POSTGRES rpms from the distro.
I set "archive_mode = on" in /var/lib/pgsql/data/postgresql.conf (and
also in /etc/sysconfig/pgsql/postgresql.conf for kicks)
Looks like I also need to set archive_command?
I am going to try archive_command = 'cp "%p" /mnt/server/archivedir/"%f"'
Does anyone have any other helpful tips when trying to use this plugin?
Ok, I am closer.
I now see something like this:
<date time code> INFO: Quiescing databases
<date time code> INFO: Quiescing database fecru
<date time code> INFO: Quiescing database jira
<date time code> ERROR: Command [/bin/su - postgres -c "/usr/bin/psql -d jira -U postgres --no-password --single-transaction --file <path>/files/blah.sc"] failed with return code  and message [psql:/<path>/files/blah.sc:1: ERROR: a backup is alread in progress
/var/lib/pgsql (nfsv4 mount) is where the database files are.I was told there are 3 databases: fecru, confluence and jira.
Yet, when I put any one of them into "backup" mode (i.e. quiesce) Postgres does not allow me to do the others. Does that mean then, that by placing one of the databases in backup mode, they all get in backup mode?
I am not all to familiar with Postgres. I have a line in the POSTGRES.conf file for the databases:
One for each of the databases. I am sure if I widdle that down to just any one of the three, it will be fine. I am curious though, about about the "other" databases?
If I put fecru in to archive mode, does jira & confluence also get put in that state automatically?
1. Try with one database like fecru in blah.sc
Some questions on your idea:
psql -d fecri ---> doesn't this select *only* the fecru database?
when looking at /var/lib/pgsql/data/base I see six directories.
There just happen to be six databases. The three I am dealing with, plus template0, template1 and postgres.
When archive mode is "turned on", wouldn't it be for just the one database, since that is what I selected?
Even if I tried what you asked, How can I tell that the writes to the second database are happening either on the filesystem or in the WAL (write-ahead-log)?
NetApp Wins One Silver and One Bronze Stevie® Award in 2022 Stevie Awards for Sales and Customer Service