Re: pgbackrest creating new directories (messing up cron jobs).

From: Stephen Frost <sfrost(at)snowman(dot)net>
To: mimble9(at)danwin1210(dot)me
Cc: pgsql-novice(at)lists(dot)postgresql(dot)org
Subject: Re: pgbackrest creating new directories (messing up cron jobs).
Date: 2020-03-10 22:37:53
Message-ID: 20200310223753.GO3195@tamriel.snowman.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-novice

Greetings,

* mimble9(at)danwin1210(dot)me (mimble9(at)danwin1210(dot)me) wrote:
> >> This is annoying as I have a cron job set up to focus on files in the
> >> 0000000100000000 directory.
> >
> > What is the cronjob doing..? You really shouldn't be hacking around
> > with things in the repo- there's commands available like archive-get to
> > extract out WAL files from the repo.
>
> The cronjob is using 'mutt' to mail me the .gz files at a set period.
>
> It says:
>
> cd /var/lib/pgbackrest/archive/main/10/0000000100000000/
> echo "" | mutt -s "Ttile" test(at)example(dot)com -a *.gz

Isn't that going to mail you the same WAL over and over again if you set
it up as a cronjob..? Is that really what you want?

> Of course, once 0000000100000000 becomes 0000000100000001, this no longer
> works.

That doesn't seem like the worst of the problems here.

> Is there, perhaps, a better way to achieve my goal?

Well, you could use archive-get with pgbackrest to pull out the files by
requesting each segment number, but I'm not sure what the idea here is
exactly- *why* are you email'ing them?

Thanks,

Stephen

In response to

Responses

Browse pgsql-novice by date

  From Date Subject
Next Message mimble9 2020-03-11 00:08:05 Re: pgbackrest creating new directories (messing up cron jobs).
Previous Message mimble9 2020-03-10 22:23:39 Re: pgbackrest creating new directories (messing up cron jobs).