agora inbox for pgsql-docs@postgresql.org
help / color / mirror / Atom feedALTER COLLATION ... REFRESH VERSION - sample script outdated
2+ messages / 2 participants
[nested] [flat]
* ALTER COLLATION ... REFRESH VERSION - sample script outdated
@ 2021-05-21 10:22 PG Doc comments form <noreply@postgresql.org>
0 siblings, 0 replies; 2+ messages in thread
From: PG Doc comments form @ 2021-05-21 10:22 UTC (permalink / raw)
To: pgsql-docs@lists.postgresql.org; +Cc: frank_limpert@yahoo.com
The following documentation comment has been logged on the website:
Page: https://www.postgresql.org/docs/13/sql-altercollation.html
Description:
The sample script that is given in section "Notes" finds only libc
collations. If you omit joining "pg_depend" you also find outdated ICU
collations. Like this:
DO $BODY$
DECLARE
r RECORD;
BEGIN
FOR r IN (
SELECT n.nspname, c.collname
FROM pg_collation c JOIN pg_namespace n ON c.collnamespace =
n.oid
WHERE c.collversion <> pg_collation_actual_version(c.oid)
) LOOP
EXECUTE format('ALTER COLLATION %I.%I REFRESH VERSION;', r.nspname,
r.collname);
RAISE NOTICE 'ALTER COLLATION %.% REFRESH VERSION;', r.nspname,
r.collname;
END LOOP;
END;
$BODY$;
^ permalink raw reply [nested|flat] 2+ messages in thread
* AW: Documentation for initdb option --waldir
@ 2025-03-27 11:40 Theodor Herlo <t.herlo@proventa.de>
0 siblings, 0 replies; 2+ messages in thread
From: Theodor Herlo @ 2025-03-27 11:40 UTC (permalink / raw)
To: Laurenz Albe <laurenz.albe@cybertec.at>; David G. Johnston <david.g.johnston@gmail.com>; pgsql-docs@lists.postgresql.org <pgsql-docs@lists.postgresql.org>
Both look great to me! I thought the advantage of having different devices is also to easy I/O load. But I guess you have to decide for yourself what is the best strategy. For me it was important to know what initdb does with ---waldir. And this is nicely explained here.
One more little thing, I stumbled across " should not be a mount point", sounds thirst like it was not good to use the mount point. Maybe: " should not be the mount point itself but a directory in the mount point". It might be only me, you diced.
Thank you very much!
Regards,
Theo
-----Ursprüngliche Nachricht-----
Von: Laurenz Albe <laurenz.albe@cybertec.at>
Gesendet: Donnerstag, 27. März 2025 11:32
An: David G. Johnston <david.g.johnston@gmail.com>; Theodor Herlo <t.herlo@proventa.de>; pgsql-docs@lists.postgresql.org
Betreff: Re: Documentation for initdb option --waldir
[Sie erhalten nicht häufig E-Mails von laurenz.albe@cybertec.at. Weitere Informationen, warum dies wichtig ist, finden Sie unter https://aka.ms/LearnAboutSenderIdentification ]
On Wed, 2025-03-26 at 17:34 -0700, David G. Johnston wrote:
> + <para>
> + The <filename>pg_wal</filename> subdirectory will always exist within the
> + data directory. This is where <productname>PostgreSQL</productname>
> + sends its write-ahead log (<acronym>WAL</acronym>) files.
> + Specifying the <option>--waldir</option> option turns this subdirectory entry
> + into a symbolic link. In general, this is only useful if the remote location
> + is on a different physical device. An existing directory must be empty and
> + should not be a mount point. The directory will be created
> + (including missing parents) if necessary.
> + </para>
I think that it is very valuable to have WAL on a different file system on the same storage device. The idea is that growing data files cannot exhaust the space available for WAL.
How about this:
There is always a <filename>pg_wal</filename> within the data directory.
By default, it is a directory where <productname>PostgreSQL</productname>
places its write-ahead log (<acronym>WAL</acronym>) segment files. If
you create the <acronym>WAL</acronym> location somewhere else using the option
<option>--waldir</option>, <filename>pg_wal</filename> will be created as
a symbolic link pointing to that <acronym>WAL</acronym> location.
If the directory already exists, it must be empty and should not be a mount
point. The directory will be created (including missing parents) if necessary.
Yours,
Laurenz Albe
^ permalink raw reply [nested|flat] 2+ messages in thread
end of thread, other threads:[~2025-03-27 11:40 UTC | newest]
Thread overview: 2+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2021-05-21 10:22 ALTER COLLATION ... REFRESH VERSION - sample script outdated PG Doc comments form <noreply@postgresql.org>
2025-03-27 11:40 AW: Documentation for initdb option --waldir Theodor Herlo <t.herlo@proventa.de>
This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox