Message style improvements
authorPeter Eisentraut <[email protected]>
Tue, 27 Aug 2024 14:54:10 +0000 (16:54 +0200)
committerPeter Eisentraut <[email protected]>
Tue, 27 Aug 2024 14:54:10 +0000 (16:54 +0200)
src/bin/pg_amcheck/pg_amcheck.c
src/bin/pg_amcheck/t/003_check.pl
src/bin/pg_combinebackup/pg_combinebackup.c
src/bin/pg_combinebackup/reconstruct.c
src/bin/pg_dump/pg_dumpall.c
src/bin/pg_rewind/pg_rewind.c

index a1ad41e7664710b52e66a18bc391de08f9c76d05..0c05cf58bcee1e09040534f527e5d5a90810cca0 100644 (file)
@@ -621,8 +621,8 @@ main(int argc, char *argv[])
             */
            if ((vmaj == 1 && vmin < 4) || vmaj == 0)
            {
-               pg_log_warning("--checkunique option is not supported by amcheck "
-                              "version \"%s\"", amcheck_version);
+               pg_log_warning("option %s is not supported by amcheck version %s",
+                              "--checkunique", amcheck_version);
                dat->is_checkunique = false;
            }
            else
index 4b16bda6a4865c64db7e7559a225d092b086fac3..d99b094dba8076d6ff2a8a0d85c867c24c6af64f 100644 (file)
@@ -564,7 +564,7 @@ $node->command_checks_all(
    0,
    [$no_output_re],
    [
-       qr/pg_amcheck: warning: --checkunique option is not supported by amcheck version "1.3"/
+       qr/pg_amcheck: warning: option --checkunique is not supported by amcheck version 1.3/
    ],
    'pg_amcheck smoke test --checkunique');
 done_testing();
index 9ded5a2140e902bf3af59d5249ee006de1082aeb..5e2f4f4b3ddbd84280ca62e6071af78c99690398 100644 (file)
@@ -337,7 +337,7 @@ main(int argc, char *argv[])
         * won't have the WAL ranges for the resulting manifest.
         */
        if (manifests[n_prior_backups] == NULL)
-           pg_fatal("can't generate a manifest because no manifest is available for the final input backup");
+           pg_fatal("cannot generate a manifest because no manifest is available for the final input backup");
    }
    else
        mwriter = NULL;
@@ -655,7 +655,7 @@ check_control_files(int n_backups, char **backup_dirs)
    if (data_checksum_mismatch)
    {
        pg_log_warning("only some backups have checksums enabled");
-       pg_log_warning_hint("disable, and optionally reenable, checksums on the output directory to avoid failures");
+       pg_log_warning_hint("Disable, and optionally reenable, checksums on the output directory to avoid failures.");
    }
 
    return system_identifier;
@@ -766,9 +766,9 @@ help(const char *progname)
    printf(_("  -o, --output=DIRECTORY    output directory\n"));
    printf(_("  -T, --tablespace-mapping=OLDDIR=NEWDIR\n"
             "                            relocate tablespace in OLDDIR to NEWDIR\n"));
-   printf(_("      --clone               clone (reflink) instead of copying files\n"));
+   printf(_("      --clone               clone (reflink) files instead of copying\n"));
    printf(_("      --copy                copy files (default)\n"));
-   printf(_("      --copy-file-range     copy using copy_file_range() syscall\n"));
+   printf(_("      --copy-file-range     copy using copy_file_range() system call\n"));
    printf(_("      --manifest-checksums=SHA{224,256,384,512}|CRC32C|NONE\n"
             "                            use algorithm for manifest checksums\n"));
    printf(_("      --no-manifest         suppress generation of backup manifest\n"));
@@ -1070,7 +1070,7 @@ process_directory_recursively(Oid tsoid,
                     */
                    bmpath = psprintf("%s/%s", input_directory,
                                      "backup_manifest");
-                   pg_log_warning("\"%s\" contains no entry for \"%s\"",
+                   pg_log_warning("manifest file \"%s\" contains no entry for file \"%s\"",
                                   bmpath, manifest_path);
                    pfree(bmpath);
                }
index a08ca221457cf079e8fd17fc5cc30eb6c48ae293..db3f968d271210c5c850b58748c495be1ecc9bc4 100644 (file)
@@ -449,7 +449,7 @@ make_incremental_rfile(char *filename)
    /* Read and validate magic number. */
    read_bytes(rf, &magic, sizeof(magic));
    if (magic != INCREMENTAL_MAGIC)
-       pg_fatal("file \"%s\" has bad incremental magic number (0x%x not 0x%x)",
+       pg_fatal("file \"%s\" has bad incremental magic number (0x%x, expected 0x%x)",
                 filename, magic, INCREMENTAL_MAGIC);
 
    /* Read block count. */
index 882dbf8e8657ab4e0e165843b41243e974019906..e3ad8fb295683bce66a9c1a5715de5f8a27d0544 100644 (file)
@@ -658,7 +658,7 @@ help(void)
    printf(_("  --disable-triggers           disable triggers during data-only restore\n"));
    printf(_("  --exclude-database=PATTERN   exclude databases whose name matches PATTERN\n"));
    printf(_("  --extra-float-digits=NUM     override default setting for extra_float_digits\n"));
-   printf(_("  --filter=FILENAME            exclude databases specified in FILENAME\n"));
+   printf(_("  --filter=FILENAME            exclude databases based on expressions in FILENAME\n"));
    printf(_("  --if-exists                  use IF EXISTS when dropping objects\n"));
    printf(_("  --inserts                    dump data as INSERT commands, rather than COPY\n"));
    printf(_("  --load-via-partition-root    load partitions via the root table\n"));
index 323c35646c90deedd234a2c713bdd53b5b915230..1027d235dc1d05f20b0771feab9107c2cb3bbdc0 100644 (file)
@@ -1104,7 +1104,7 @@ getRestoreCommand(const char *argv0)
 
    restore_command = pipe_read_line(postgres_cmd->data);
    if (restore_command == NULL)
-       pg_fatal("unable to read restore_command from target cluster");
+       pg_fatal("could not read restore_command from target cluster");
 
    (void) pg_strip_crlf(restore_command);