Fix: omnipitr-monitor had a bug with parsing timestamps from logs (in cases of “negative" timezones)

Fix: sanity-check.sh now returns correct status when exiting, so you can verify if everything is OK by simply checking $?, and not reading its output (helpful for automation scripts)

Fix: temp directories are made using PID in path, so you can now have (for example) two separate PG clusters on the same machine, each running omnipitr-restore, without them stepping on each others toes

New: added –version to all programs, so you can easily check which version you have installed

New: added –help option to all programs, so you can see the documentation without manually finding docs, and running perldoc on them

All of above are pretty cosmetic, but there are two bigger changes too. First of them – –remove-before option to omnipitr-restore. Let's imagine you have normal replication, but for whatever reason slave is lagging. Maybe Pg on slave machine was disabled, or maybe master is just so much faster. In any way – slave is lagging. And this means that walarchive is growing (I'm talking about xlog-file based replication, not streaming).

Walarchive would be growing, because omnipitr-archive delivers new xlogs, but omnipitr-restore will remove them only when it will catchup. Now, with this new option, omnipitr-restore always first checks if there is anything to delete, and if yes – removes single “batch" of files (according to –remove-at-a-time option).

This is not enabled by default, mostly not to change behaviour from previous versions, but also – because “remove-before" is slightly slower – before providing file, it has to run pg_controldata, and optionally remove some (3 by default) files.

The overhead is (in my opinion) minimal, but it is there, so it can't be enabled by default. But – if you're ever in position where walarchive grew too much, and slave was lagging – this is an option for you.

The other larger news is ability to provide config files. This has been added to all programs, but I think it's most important for omnipitr-restore (where changing options required restart of slave because options were in recovery.conf file read only on Pg start).

The file has very simple format:

one option per line

options are given just like in command line, with the exception that you don't need to quote values

both short and long version of switches are acceptable (-v/–verbose)

empty lines are ignored

lines starting with # are treated as comments

This means that instead of having (for example) in your postgresql.conf:

It might still be useful to integrate with though – either by running pg_basebackup or just using libpq.T he support for nonexclusive backups probably being the main reason. The “libpq only” isn’t really a big feature in an “OmniPTR envirnonemnt”, I think, but the nonexclusive backups might be.