File tree Expand file tree Collapse file tree 3 files changed +7
-13
lines changed Expand file tree Collapse file tree 3 files changed +7
-13
lines changed Original file line number Diff line number Diff line change @@ -94,7 +94,7 @@ do_backup_database(parray *backup_list, pgBackupOption bkupopt)
94
94
if (pg_is_standby ())
95
95
elog (ERROR , "Backup cannot run on a standby." );
96
96
97
- elog (INFO , "database backup start" );
97
+ elog (LOG , "database backup start" );
98
98
99
99
/* Initialize size summary */
100
100
current .data_bytes = 0 ;
@@ -563,6 +563,12 @@ wait_for_archive(pgBackup *backup, const char *sql)
563
563
XLogSegNo targetSegNo ;
564
564
565
565
reconnect ();
566
+
567
+ /* Remove annoying NOTICE messages generated by backend */
568
+ res = execute ("SET client_min_messages = warning;" , 0 , NULL );
569
+ PQclear (res );
570
+
571
+ /* And execute the query wanted */
566
572
res = execute (sql , 0 , NULL );
567
573
568
574
/* Get LSN from execution result */
Original file line number Diff line number Diff line change 1
1
\! bash sql/delete.sh
2
2
###### DELETE COMMAND TEST-0001 ######
3
3
###### delete full backups ######
4
- NOTICE: pg_stop_backup complete, all required WAL segments have been archived
5
- NOTICE: pg_stop_backup complete, all required WAL segments have been archived
6
- NOTICE: pg_stop_backup complete, all required WAL segments have been archived
7
4
try to delete the oldest backup
8
5
2
9
6
1
10
7
Number of deleted backups should be 1, is it so?: 1
11
8
###### DELETE COMMAND TEST-0002 ######
12
9
###### keep backups which are necessary for recovery ######
13
- NOTICE: pg_stop_backup complete, all required WAL segments have been archived
14
- NOTICE: pg_stop_backup complete, all required WAL segments have been archived
15
- NOTICE: pg_stop_backup complete, all required WAL segments have been archived
16
- NOTICE: pg_stop_backup complete, all required WAL segments have been archived
17
10
try to delete before third backup
18
11
3
19
12
1
Original file line number Diff line number Diff line change 1
1
\! bash sql/show.sh
2
2
###### SHOW COMMAND TEST-0001 ######
3
3
###### Status DONE and OK ######
4
- NOTICE: pg_stop_backup complete, all required WAL segments have been archived
5
4
0
6
5
OK: DONE status is shown properly.
7
6
0
@@ -10,22 +9,18 @@ OK: OK status is shown properly.
10
9
###### SHOW COMMAND TEST-0002 ######
11
10
###### Status RUNNING ######
12
11
OK: RUNNING status is shown properly.
13
- NOTICE: pg_stop_backup complete, all required WAL segments have been archived
14
12
15
13
###### SHOW COMMAND TEST-0003 ######
16
14
###### Status CORRUPT ######
17
- NOTICE: pg_stop_backup complete, all required WAL segments have been archived
18
15
0
19
16
remove a file from backup intentionally
20
17
0
21
18
OK: CORRUPT status is shown properly.
22
19
23
20
###### SHOW COMMAND TEST-0004 ######
24
21
###### Status DELETED ######
25
- NOTICE: pg_stop_backup complete, all required WAL segments have been archived
26
22
0
27
23
0
28
- NOTICE: pg_stop_backup complete, all required WAL segments have been archived
29
24
0
30
25
0
31
26
0
You can’t perform that action at this time.
0 commit comments