Hey,
Yep automatic schedule is not supported - it will be supported in FR23 which is not out yet The link I referenced was just to explain automatic schedule for log backups in general.
FR23 will be out mid March 2021.
With regards to the script - it may be the best option to tie you over until FR23 is available and you upgrade to it. There’s a few different ways you could do this and you’ll need to decide if you run the qoperation in asynchronous or synchronous mode which will most likely decide how simple / advanced your script needs to be! Some pseudo code for a script would be:
Script executed (from archive_command):
Check if a file pid.file exists
If pid.file exists get the output of this file and check if that process is running
If process is running exit the script
If process is not running then create new pid.file with the current running PID
If pid.file does not exist then create pid.file with the current running PID
Run CV postgresql incremental (log) backup synchronously (waits for it to complete)
Remove pid.file
The script would be executed after the ‘cp’ in the archive_command we specifically say to use - we search the archive_command for the directory you specify on the PostreSQL instance which is how we will check the logs are actually being backed up properly (and archived before backing up). You’ll also want to make sure you understand how archive_command works in PostgreSQL - if a return code of 0 isn’t returned from the output of whatever you put in archive_command then PostgreSQL will treat the archiving of the WAL file as failed and will keep retrying.
I hope this helps somewhat