Re: "Hot standby"?

From: Mark Mielke <mark(at)mark(dot)mielke(dot)cc>
To: Robert Haas <robertmhaas(at)gmail(dot)com>
Cc: Greg Stark <gsstark(at)mit(dot)edu>, Josh Berkus <josh(at)agliodbs(dot)com>, Kevin Grittner <Kevin(dot)Grittner(at)wicourts(dot)gov>, Peter Eisentraut <peter_e(at)gmx(dot)net>, Bruce Momjian <bruce(at)momjian(dot)us>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: "Hot standby"?
Date: 2009-08-12 04:27:50
Message-ID: 4A8244C6.2090501@mark.mielke.cc
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On 08/11/2009 11:19 PM, Robert Haas wrote:
> On Tue, Aug 11, 2009 at 9:44 PM, Greg Stark<gsstark(at)mit(dot)edu> wrote:
>
>> No! This is *not* what "hot standby" means, at least not in the Oracle world.
>>
>
> I'm perplexed by this. For example: http://en.wikipedia.org/wiki/Hot_standby
>
> Admittedly, wikipedia is not an authoritative source, but I've always
> understood cold/warm/hot just as Peter described them upthread. Cold
> means it's on the shelf. Warm means it's plugged in, but you have to
> have to do something to get it going. Hot means it just takes over
> when needed.
>
> But of course I guess Oracle can call their features what they want to...
>

To further confuse things, the "temperature" might apply to only a
particular aspect of the solution. For example, "hot swappable disk
drives" are drives that probably do sit on a shelf until they are
needed, and the "hot" aspect only implies that the server does not need
to be shut down to install the drives, and initialize them for service. :-)

For databases, people seem to be associating "hot" with the ability to
issue read only queries. As somebody else said - under a definition of
hot that includes read-only clones, pg_dump/pg_restore could be
considered a "hot standby" strategy.

I don't agree with that definition. For the clone to be able to perform
read-only queries does not imply "hot" nor does it imply "standby". It
implies "slave". The original poster correctly raised this concern.

For myself, I associate "hot" to mean "ready to replace the master",
which implies that the data is up-to-date or nearly up-to-date, and
implies that the server is within a bit toggle of accepting mastership
of the data and serving ALL queries that the master would serve. Key to
this is "nearly up-to-date" (requires some sort of streaming) AND "ALL
queries" (not just read queries!).

If the server happens to be able to do read queries while it is waiting
in standby more - that's convenient and could be useful to somebody, but
that's not the value of a "hot standby" - that's the value of a
"read-only slave". The feature being provided is not "hot standby".

In the case of Oracle, I believe their "hot standby" provides the nearly
up-to-date, and the capability to switch over, which satisfies my
requirements. It might *also* allow read-only slave for the standby, but
that's just convenience - it's not really part of the definition or
expectation of "hot standby".

>> "log based replication", "read-only slaves", and "hot standby" are all
>> 100% accurate descriptions of what the hot standby patch enables. I do
>> like "read only slaves" because it's the most precise and meaningful.
>>
>
> Me too.
>

Read only slave works for me.

Cheers,
mark

--
Mark Mielke<mark(at)mielke(dot)cc>

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Markus Wanner 2009-08-12 04:48:19 Re: "Hot standby"?
Previous Message Tom Lane 2009-08-12 04:27:16 Re: pgindent timing (was Re: [COMMITTERS] pgsql: Refactor NUM_cache_remove calls in error report path to a PG_TRY)