1
0
mirror of https://github.com/postgrespro/pg_probackup.git synced 2024-11-24 08:52:38 +02:00
Commit Graph

56 Commits

Author SHA1 Message Date
stalkerg
6c94ea7fb1 Correct help texts. 2016-11-16 21:32:26 +03:00
stalkerg
188bbdd593 Rename project to pg_probackup. 2016-11-16 20:34:21 +03:00
stalkerg
054226d2db Remove recovery-target- substring from restore option. 2016-11-16 19:41:16 +03:00
stalkerg
7ba03021c5 Refactor delete command and add delwal command. 2016-11-16 17:38:11 +03:00
stalkerg
a9040229a5 Get current timeline from wal dir.
Also add recovery_target = 'immediate' for some case.
2016-11-16 15:14:50 +03:00
stalkerg
44ac5f4c1b Hide not reliable options: --check, --keep-data-generations, --keep-data-days 2016-11-10 12:49:30 +03:00
stalkerg
c1f1627c0b Rewrite delete backup logic. 2016-11-09 17:29:48 +03:00
stalkerg
78362a52d6 Move all backups to "backups" subdir. 2016-11-07 17:35:53 +03:00
stalkerg
24c840392f Use --stream option only for backup. Add STREAM to show command. 2016-11-01 17:25:46 +03:00
stalkerg
c0b9b02752 Fix docs and use recovery time for show command. 2016-10-31 18:57:15 +03:00
stalkerg
d3f3110316 Stop creating pg_xlog dir in BACKUP because it is rudiment. 2016-10-27 11:47:16 +03:00
stalkerg
b0a63b6790 Add -S, --slot option for backup with --stream 2016-10-25 20:21:27 +03:00
stalkerg
fb40b3e5a7 Remove validation option and do it after any backup. 2016-10-25 19:02:30 +03:00
stalkerg
af0e674cbb Add automatic detect of replica and remove same option. 2016-10-25 14:38:51 +03:00
stalkerg
f0703e527c Remove ARCLOG_PATH option. 2016-10-18 20:22:53 +03:00
stalkerg
8daffeeb6d Detect ptrack support and remove disable ptrack option. 2016-10-18 16:25:13 +03:00
stalkerg
b6ceb7ff2e Gen rangedate param only for show, validate and delete command. 2016-10-13 16:20:53 +03:00
stalkerg
9f038eeb5e Add support backup from replica. 2016-09-29 17:33:21 +03:00
stalkerg
6ce7163a8a Add simple progress bar with option --progress. 2016-09-02 20:16:00 +03:00
stalkerg
3eb1013baa Exclude pg_log by default and add option for start beckup. 2016-09-02 18:31:06 +03:00
stalkerg
23f4eaa8e5 Add --disable-ptrack-clear for postgres without ptrack. 2016-09-01 18:29:13 +03:00
stalkerg
9471875b15 Add stream mode for save WAL during backup process. 2016-05-26 15:56:32 +03:00
stalkerg
ccd4f48017 Fix check ptrack control file. 2016-05-12 12:51:36 +03:00
stalkerg
075c37ba68 Fix backup if we do full backup. 2016-05-11 21:49:26 +03:00
stalkerg
091fe0ada2 Fix backup many segments of relation (big relations) with ptrack.
Add fail test for show problem in lost pages in backup process.
2016-05-01 22:05:18 +03:00
stalkerg
558d4a3427 Remove noisy NOTICE messages when calling pg_stop_backup
Those per se are not that annoying, but the random messages generated
by the backend while pg_arman is waiting for segments to be archived
are annoying. This commit gets rid of them by using client_min_messages
set to warning on the connection used.

Report by Yury Zhuravlev.
2016-03-28 13:47:49 +03:00
Zhuravlev Uriy aka stalkerg
205d0a0c03 Update test for new options help. 2016-03-02 12:12:04 +03:00
Zhuravlev Uriy aka stalkerg
fed13c298e Add multithread beckup. 2016-02-29 20:23:48 +03:00
Zhuravlev Uriy aka stalkerg
9c475eccbf First version of ptrack support. 2016-02-27 21:07:55 +03:00
Michael Paquier
5c37daca69 Sanitize error checks
All the ERROR_* fields are removed in favor of a more simple layer
made of ERROR, FATAL, PANIC. The two last ones are not actually used
yet, thought there should be some code paths that would need more
polishing on this matter.

The error message emitted before leaving should be fine to let the
user know what is happening.
2016-01-19 12:41:30 +09:00
Michael Paquier
f2c523b1ee Remove un-needed WAL segments from archive at backup deletion
During the execution of the "delete" command, the oldest start LSN is saved
and used to determine what is the oldest WAL segment that needs to be kept
for the existing backups. Like pg_archivecleanup, the implemented logic
ignores the timeline part of the WAL segment name, ensuring that a segment
from a parent timeline will not be removed prematurely. This logic could
be made more complicated regarding this matter, but in order to take backups
from a node on a given timeline this is far enough.
2016-01-18 16:11:47 +09:00
Michael Paquier
04c4c7b865 Make regression tests more verbose
The tests now rely on --verbose to print out useful information in the
logs that can be used for debugging purposes. In case of a failure in
some of the tests an overall cleanup is not done, this is particularly
useful for PGDATA which could still be used for extra failure analysis.
2016-01-15 13:29:19 +09:00
Michael Paquier
f94c5ab447 Sanitize logging facility
--debug and --verbose had actually the same meaning as they were aimed
at giving to the user information regarding how the process is running,
hence both options are merged into --verbose and use elog(LOG) to decide
if a given message should be printed out depending on the verbosity of
the call. This makes a couple of routines more readable as they do not
depend on any boolean checks.

The "_()" have been removed from the code, those are aimed at being used
for translation but having them mandatorily in each log message is just
useless noise. If needed, pgut.c should be updated in consequence to
have a more portable facility.

At the same time this commit takes care of putting into correct shape
some code paths more in-line with PostgreSQL policy. There are surely
more of this kind of ugly stuff but at this stage things are more simple
and more manageable.
2016-01-14 16:36:39 +09:00
Michael Paquier
3ac6d13329 Remove --compress-data/-Z
Performance of compression is quite questionable on many objects like
that and makes the routines aimed at managing file copy, backup and restore
more complicated than they should be.

This commit results in a largely simplified code in data.c, which will
be helpful when integrating differential backup using WAL file lookup.
2016-01-14 15:19:38 +09:00
Michael Paquier
c5c07d8613 Fix failure in a couple of regression tests
The method used here is to enforce the archiving of the last segment
available to ensure that recovery works up to the point defined by
the tests.
2016-01-13 16:06:17 +09:00
Michael Paquier
6de8b16403 Incorporate new test facility in pg_arman
This new facility has the advantage on not relying on static data when
generating the tests making the whole facility more robust. This is
basically taken from the upstream project pg_rman and adapted for the
sake of this pet project, so most of the credit go to Kyotaro Horiguchi
and Amit Langote regarding this facility. However I have adapted a bunch
of things and fixed a lot of redundancy and code duplication.
2016-01-13 14:57:51 +09:00
Michael Paquier
db249c800e Replace incremental backup by page-level differential backup
This will allow the introduction of file-level differential backup.
2014-01-30 15:58:55 +09:00
Michael Paquier
3fc8d00bb4 Fix regression test failures caused by recent project renaming
Just a configuration file that missed the shot as well as an outdated
output for options.
2014-01-27 12:14:58 +09:00
Michael Paquier
c8ebcc9c41 Rename project to pg_arman
This is officially a fork!
2014-01-27 12:02:56 +09:00
Michael Paquier
820485d225 Strip off archive backup mode
This mode is not actually necessary if we consider that the core of
pg_rman is the obtention of differential and full backups, the server
being afterwards in charge to recover necessary WAL segments from the
archive.

Regression tests and documentation are updated in accordance to the
changes.
2014-01-24 22:37:55 +09:00
Michael Paquier
5988e6bd10 Remove server backup feature
In order to keep only the core of pg_rman for incremental/differential
backup, this looks necessary and makes the code more simple. Including
server log files in a backup could be subject to discussion as well,
as for example a Postgres base backup does not include them, just
because in this case server instance is not aware of the log files.
2014-01-24 20:37:13 +09:00
Michael Paquier
7eb06cbc64 Add backup option --validate
This permits to validate a backup that has just been taken. Other
backups taken previously are ignored.
2014-01-17 22:42:27 +09:00
Michael Paquier
09745505aa Make regression tests pass on OSX
Diffs were generated because of wc that puts some spaces before the
output which is in this case a number of lines. This does not impact
regression tests on Linux/Unix.
2014-01-13 12:46:58 +09:00
Michael Paquier
1c3512fadf Fix old backup removal for specified number of days
Backups could be removed even if generation number was set to infinite
without caring of the day threashold calculated. Backups are removed
if they either satisfy the generation or the day threshold.
2014-01-10 08:42:54 +09:00
Michael Paquier
37c3be1168 Refactor write/read calculation size of backups
This commit simplifies the way backup sizes are saved internally by
reusing the same variable for incremental and full backup, which were
using separated and exclusively used variables, resulted in a couple
of bytes wasted all the time. This was also reflected by a useless
column in the output table of subcommand "show".
2014-01-10 04:11:27 +09:00
Michael Paquier
8efe5c9da4 Change version number to 1.3dev 2013-12-18 19:25:26 +08:00
Michael Paquier
a8f98e9e27 Update project and bug report URLs
As this project has been forked to github...
2013-12-18 19:24:27 +08:00
Michael Paquier
0938c645bb Update regression output after latest commit
Missed that actually...
2013-12-16 00:35:14 +09:00
Michael Paquier
4b0f88e4d5 Remove standby-site option
The documentation found on internet is rather unclear about the role
and the goal of this feature, which looks more like a kludge to cover
the fact that most of the system XLOG functions do not work on standby
nodes. Now that this restriction has been removed by using the control
file to look for the current timestamp, this feature is not needed.
2013-12-13 04:14:29 +09:00
Michael Paquier
9e35dd0d47 Adapt output of regressions with new options and "show" output
Because of that two regression tests were failing:
- option
- show_validate
2013-12-13 00:57:54 +09:00