Re: archive_commnad parameter question - Mailing list pgsql-general

From Adrian Klaver
Subject Re: archive_commnad parameter question
Date
Msg-id 38a9c7ef-a301-39b9-3766-85f67a6c4e17@aklaver.com
Whole thread Raw
In response to archive_commnad parameter question  (Allie Crawford <CrawfordMA@ChurchofJesusChrist.org>)
List pgsql-general
On 4/19/21 2:09 PM, Allie Crawford wrote:
> Hello,
> 
> I am new in PostgreSQL and I am trying to understand what the “test” 
> word is representing in the archive_command configuration that the 
> PostgreSQL documentation is showing as the format on how to set up this 
> parameter
> 
> archive_command = 'test ! -f /mnt/server/archivedir/%f && cp %p 
> /mnt/server/archivedir/%f'  # Unix
> 
> Does anybody know what is “test” representing in this parameter 
> configuration?

Per the docs:

"This is an example, not a recommendation, and might not work on all 
platforms."

test in this case refers to a shell command:

https://www.computerhope.com/unix/bash/test.htm

So this only works in environments that have that command.

> 
> Thank in advance for your help on this.
> 
> Regards,
> 
> Allie
> 


-- 
Adrian Klaver
adrian.klaver@aklaver.com



pgsql-general by date:

Previous
From: Allie Crawford
Date:
Subject: archive_commnad parameter question
Next
From: Gavan Schneider
Date:
Subject: Re: archive_commnad parameter question