Skip to content

Commit 3371e4d

Browse files
committed
Change default of log_directory to 'log'
The previous default 'pg_log' might have indicated by its "pg_" prefix that it is an internal system directory. The new default is more in line with the typical naming of directories with user-facing log files. Together with the renaming of pg_clog and pg_xlog, this should clear up that difference. Author: Andreas Karlsson <andreas@proxel.se>
1 parent a171f01 commit 3371e4d

File tree

6 files changed

+9
-9
lines changed

6 files changed

+9
-9
lines changed

doc/src/sgml/config.sgml

+3-3
Original file line numberDiff line numberDiff line change
@@ -4363,8 +4363,8 @@ SELECT * FROM parent WHERE key = 2400;
43634363
find the logs currently in use by the instance. Here is an example of
43644364
this file's content:
43654365
<programlisting>
4366-
stderr pg_log/postgresql.log
4367-
csvlog pg_log/postgresql.csv
4366+
stderr log/postgresql.log
4367+
csvlog log/postgresql.csv
43684368
</programlisting>
43694369

43704370
<filename>current_logfiles</filename> is recreated when a new log file
@@ -4466,7 +4466,7 @@ local0.* /var/log/postgresql
44664466
cluster data directory.
44674467
This parameter can only be set in the <filename>postgresql.conf</>
44684468
file or on the server command line.
4469-
The default is <literal>pg_log</literal>.
4469+
The default is <literal>log</literal>.
44704470
</para>
44714471
</listitem>
44724472
</varlistentry>

doc/src/sgml/file-fdw.sgml

+1-1
Original file line numberDiff line numberDiff line change
@@ -262,7 +262,7 @@ CREATE FOREIGN TABLE pglog (
262262
location text,
263263
application_name text
264264
) SERVER pglog
265-
OPTIONS ( filename '/home/josh/9.1/data/pg_log/pglog.csv', format 'csv' );
265+
OPTIONS ( filename '/home/josh/data/log/pglog.csv', format 'csv' );
266266
</programlisting>
267267
</para>
268268

src/backend/utils/misc/guc.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -3320,7 +3320,7 @@ static struct config_string ConfigureNamesString[] =
33203320
GUC_SUPERUSER_ONLY
33213321
},
33223322
&Log_directory,
3323-
"pg_log",
3323+
"log",
33243324
check_canonical_path, NULL, NULL
33253325
},
33263326
{

src/backend/utils/misc/postgresql.conf.sample

+1-1
Original file line numberDiff line numberDiff line change
@@ -344,7 +344,7 @@
344344
# (change requires restart)
345345

346346
# These are only used if logging_collector is on:
347-
#log_directory = 'pg_log' # directory where log files are written,
347+
#log_directory = 'log' # directory where log files are written,
348348
# can be absolute or relative to PGDATA
349349
#log_filename = 'postgresql-%Y-%m-%d_%H%M%S.log' # log file name pattern,
350350
# can include strftime() escapes

src/test/perl/PostgresNode.pm

+1-1
Original file line numberDiff line numberDiff line change
@@ -551,7 +551,7 @@ sub _backup_fs
551551
$backup_path,
552552
filterfn => sub {
553553
my $src = shift;
554-
return ($src ne 'pg_log' and $src ne 'postmaster.pid');
554+
return ($src ne 'log' and $src ne 'postmaster.pid');
555555
});
556556

557557
if ($hot)

src/test/perl/RecursiveCopy.pm

+2-2
Original file line numberDiff line numberDiff line change
@@ -48,9 +48,9 @@ attempted.
4848
4949
RecursiveCopy::copypath('/some/path', '/empty/dir',
5050
filterfn => sub {
51-
# omit pg_log and contents
51+
# omit log/ and contents
5252
my $src = shift;
53-
return $src ne 'pg_log';
53+
return $src ne 'log';
5454
}
5555
);
5656

0 commit comments

Comments
 (0)