Re: [PATCH] Recreate Missing WAL Directories (from TODO)

From: "Jonah H(dot) Harris" <jonah(dot)harris(at)gmail(dot)com>
To: "Tom Lane" <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: "Pg Hackers" <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: [PATCH] Recreate Missing WAL Directories (from TODO)
Date: 2008-11-08 22:12:58
Message-ID: 36e682920811081412x7577cc4hc1c8c5621aa6f8dc@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Sat, Nov 8, 2008 at 4:08 PM, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
> This has been suggested before but I'm unconvinced that it's a good
> idea. It's reasonably common for pg_xlog to be a symlink. If you
> neglect to re-establish the symlink then what would happen is that xlog
> gets recreated on the data disk, and with no notice you are running in
> a degraded mode.

Agreed on the basis that people sometimes forget to symlink. That's
the reason why I was echoing a message. Initially the message was
WARNING, but I degraded it to LOG.

> It might be reasonable to auto-recreate XLOGDIR/archive_status, though.

Attached.

BTW, I have seen people create both pg_xlog and archive_status as
files, which is why I'm validating that in this function rather than
waiting for it to error-out later in the code.

--
Jonah H. Harris, Senior DBA
myYearbook.com

Attachment Content-Type Size
arcstatdir_v2.patch application/octet-stream 2.8 KB

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Zdenek Kotala 2008-11-08 22:59:30 WIP: Page space reservation (pgupgrade)
Previous Message Tom Lane 2008-11-08 21:08:58 Re: [PATCH] Recreate Missing WAL Directories (from TODO)