High Availability and Replication

Started by normandavis1990about 2 years ago12 messagesgeneral
Jump to latest
#1normandavis1990
normandavis1990@proton.me

Hello,
What is the difference between High Availability and Replication?

Cheers.

#2David G. Johnston
david.g.johnston@gmail.com
In reply to: normandavis1990 (#1)
Re: High Availability and Replication

On Thursday, February 29, 2024, normandavis1990 <normandavis1990@proton.me>
wrote:

What is the difference between High Availability and Replication?

The former is a goal, the later is a technique.

David J.

#3Clay Jackson (cjackson)
Clay.Jackson@quest.com
In reply to: David G. Johnston (#2)
RE: High Availability and Replication

What David said 😉

Disclaimer – I work for Quest Software – we produce database tools, including SharePlex, which can be used to help create High Availably and Disaster Recovery solutions.

Here’s a blog I did several years ago that might be helpful
https://www.quest.com/community/blogs/b/database-management/posts/high-availability-vs-disaster-recovery---what-s-the-difference

Clay Jackson
Database Solutions Sales Engineer
[cid:image001.jpg@01DA6B01.DC2DA850]<https://www.quest.com/solutions/database-performance-monitoring/&gt;
clay.jackson@quest.com<mailto:clay.jackson@quest.com>
office 949-754-1203 mobile 425-802-9603

From: David G. Johnston <david.g.johnston@gmail.com>
Sent: Thursday, February 29, 2024 11:15 AM
To: normandavis1990 <normandavis1990@proton.me>
Cc: pgsql-general@lists.postgresql.org
Subject: Re: High Availability and Replication

CAUTION: This email originated from outside of the organization. Do not follow guidance, click links, or open attachments unless you recognize the sender and know the content is safe.

On Thursday, February 29, 2024, normandavis1990 <normandavis1990@proton.me<mailto:normandavis1990@proton.me>> wrote:

What is the difference between High Availability and Replication?

The former is a goal, the later is a technique.

David J.

Attachments:

image001.jpgimage/jpeg; name=image001.jpgDownload
#4normandavis1990
normandavis1990@proton.me
In reply to: David G. Johnston (#2)
Re: High Availability and Replication

What does this technique do?

On Thursday, February 29th, 2024 at 10:45 PM, David G. Johnston <david.g.johnston@gmail.com> wrote:

Show quoted text

On Thursday, February 29, 2024, normandavis1990 <normandavis1990@proton.me> wrote:

What is the difference between High Availability and Replication?

The former is a goal, the later is a technique.

David J.

#5Adrian Klaver
adrian.klaver@aklaver.com
In reply to: normandavis1990 (#4)
Re: High Availability and Replication

On 2/29/24 12:02, normandavis1990 wrote:

What does this technique do?

https://www.postgresql.org/docs/current/high-availability.html

On Thursday, February 29th, 2024 at 10:45 PM, David G. Johnston
<david.g.johnston@gmail.com> wrote:

On Thursday, February 29, 2024, normandavis1990
<normandavis1990@proton.me <mailto:normandavis1990@proton.me>> wrote:

What is the difference between High Availability and Replication?

The former is a goal, the later is a technique.

David J.

--
Adrian Klaver
adrian.klaver@aklaver.com

#6Israel Brewster
ijbrewster@alaska.edu
In reply to: David G. Johnston (#2)
Re: High Availability and Replication

On Feb 29, 2024, at 10:15 AM, David G. Johnston <david.g.johnston@gmail.com> wrote:

On Thursday, February 29, 2024, normandavis1990 <normandavis1990@proton.me <mailto:normandavis1990@proton.me>> wrote:

What is the difference between High Availability and Replication?

The former is a goal, the later is a technique.

Perhaps more specifically: Replication is simply Replicating - or copying - the “master” database to one or more “slave” databases, generally in real-time such that the slave database clusters are replicas of the master. This is good when the master goes down, because you’ll still have one or more copies of it available, but by itself it doesn’t keep there from being an outage if/when the master goes down.

High Availability layers on top of replication to provide some means of ensuring that the database is HIGHLY available, such as an automatic failover system or load balancer. Many different options that work in many different ways are available to help meet this goal.
---
Israel Brewster
Software Engineer
Alaska Volcano Observatory
Geophysical Institute - UAF
2156 Koyukuk Drive
Fairbanks AK 99775-7320
Work: 907-474-5172
cell: 907-328-9145

Show quoted text

David J.

#7normandavis1990
normandavis1990@proton.me
In reply to: Israel Brewster (#6)
Re: High Availability and Replication

On Thursday, February 29th, 2024 at 11:38 PM, Israel Brewster <ijbrewster@alaska.edu> wrote:

On Feb 29, 2024, at 10:15 AM, David G. Johnston <david.g.johnston@gmail.com> wrote:

On Thursday, February 29, 2024, normandavis1990 <normandavis1990@proton.me> wrote:

What is the difference between High Availability and Replication?

The former is a goal, the later is a technique.

Perhaps more specifically: Replication is simply Replicating - or copying - the “master” database to one or more “slave” databases, generally in real-time such that the slave database clusters are replicas of the master. This is good when the master goes down, because you’ll still have one or more copies of it available, but by itself it doesn’t keep there from being an outage if/when the master goes down.

High Availability layers on top of replication to provide some means of ensuring that the database is HIGHLY available, such as an automatic failover system or load balancer. Many different options that work in many different ways are available to help meet this goal.
---
Israel Brewster
Software Engineer
Alaska Volcano Observatory
Geophysical Institute - UAF
2156 Koyukuk Drive
Fairbanks AK 99775-7320
Work: 907-474-5172
cell: 907-328-9145

David J.

Hi,
You said "This is good when the master goes down, because you’ll still have one or more copies of it available, but by itself it doesn’t keep there from being an outage if/when the master goes down.". What does "goes down" mean?
In Replication mode, if the primary server is shut down, then the data will also be lost?

#8Israel Brewster
ijbrewster@alaska.edu
In reply to: normandavis1990 (#7)
Re: High Availability and Replication

On Mar 1, 2024, at 11:36 AM, normandavis1990 <normandavis1990@proton.me> wrote:

On Thursday, February 29th, 2024 at 11:38 PM, Israel Brewster <ijbrewster@alaska.edu> wrote:

On Feb 29, 2024, at 10:15 AM, David G. Johnston <david.g.johnston@gmail.com> wrote:

On Thursday, February 29, 2024, normandavis1990 <normandavis1990@proton.me <mailto:normandavis1990@proton.me>> wrote:

What is the difference between High Availability and Replication?

The former is a goal, the later is a technique.

Perhaps more specifically: Replication is simply Replicating - or copying - the “master” database to one or more “slave” databases, generally in real-time such that the slave database clusters are replicas of the master. This is good when the master goes down, because you’ll still have one or more copies of it available, but by itself it doesn’t keep there from being an outage if/when the master goes down.

High Availability layers on top of replication to provide some means of ensuring that the database is HIGHLY available, such as an automatic failover system or load balancer. Many different options that work in many different ways are available to help meet this goal.
---
Israel Brewster
Software Engineer
Alaska Volcano Observatory
Geophysical Institute - UAF
2156 Koyukuk Drive
Fairbanks AK 99775-7320
Work: 907-474-5172
cell: 907-328-9145

David J.

Hi,
You said "This is good when the master goes down, because you’ll still have one or more copies of it available, but by itself it doesn’t keep there from being an outage if/when the master goes down.". What does "goes down" mean?

Exactly what I said - it goes down. Not functioning. Offline. Inaccessible. It is not up and running, therefore, it is down.

In Replication mode, if the primary server is shut down, then the data will also be lost?

No. As I said - and you quoted - “When the master goes down…you’ll still have one or more copies of it available”. So no, the data will NOT be lost.

---
Israel Brewster
Software Engineer
Alaska Volcano Observatory
Geophysical Institute - UAF
2156 Koyukuk Drive
Fairbanks AK 99775-7320
Work: 907-474-5172
cell: 907-328-9145

#9Abdul Sayeed
abdulsayeed24@gmail.com
In reply to: Israel Brewster (#8)
Re: High Availability and Replication

Hi,

When Master server goes down, either you need to promote one of slave node
or configure HA mechanism so that in case of master server goes down it
will automatically promote the slave server as new master.

Patroni HA tool would be good option for your requirement.

https://patroni.readthedocs.io/en/latest/README.html

Hope this helps.

Thanks & Regards,
Abdul Sayeed
PostgreSQL DBA

On Sat, 2 Mar 2024 at 2:15 AM, Israel Brewster <ijbrewster@alaska.edu>
wrote:

Show quoted text

On Mar 1, 2024, at 11:36 AM, normandavis1990 <normandavis1990@proton.me>
wrote:

On Thursday, February 29th, 2024 at 11:38 PM, Israel Brewster <

ijbrewster@alaska.edu> wrote:

On Feb 29, 2024, at 10:15 AM, David G. Johnston <
david.g.johnston@gmail.com> wrote:

On Thursday, February 29, 2024, normandavis1990 <normandavis1990@proton.me>
wrote:

What is the difference between High Availability and Replication?

The former is a goal, the later is a technique.

Perhaps more specifically: Replication is simply Replicating - or copying
- the “master” database to one or more “slave” databases, generally in
real-time such that the slave database clusters are replicas of the master.
This is good when the master goes down, because you’ll still have one or
more copies of it available, but by itself it doesn’t keep there from being
an outage if/when the master goes down.

High Availability layers on top of replication to provide some means of
ensuring that the database is HIGHLY available, such as an automatic
failover system or load balancer. Many different options that work in many
different ways are available to help meet this goal.
---
Israel Brewster
Software Engineer
Alaska Volcano Observatory
Geophysical Institute - UAF
2156 Koyukuk Drive
<https://www.google.com/maps/search/2156+Koyukuk+Drive+Fairbanks+AK+99775-7320?entry=gmail&amp;source=g&gt;

Fairbanks AK 99775-7320
<https://www.google.com/maps/search/2156+Koyukuk+Drive+Fairbanks+AK+99775-7320?entry=gmail&amp;source=g&gt;
Work: 907-474-5172
cell: 907-328-9145

David J.

Hi,
You said "This is good when the master goes down, because you’ll still
have one or more copies of it available, but by itself it doesn’t keep
there from being an outage if/when the master goes down.". What does "goes
down" mean?

Exactly what I said - it goes down. Not functioning. Offline.
Inaccessible. It is not up and running, therefore, it is down.

In Replication mode, if the primary server is shut down, then the data
will also be lost?

No. As I said - and you quoted - “When the master goes down…you’ll still
have one or more copies of it available”. So no, the data will NOT be lost.

---
Israel Brewster
Software Engineer
Alaska Volcano Observatory
Geophysical Institute - UAF
2156 Koyukuk Drive
<https://www.google.com/maps/search/2156+Koyukuk+Drive+Fairbanks+AK+99775-7320?entry=gmail&amp;source=g&gt;

Fairbanks AK 99775-7320
<https://www.google.com/maps/search/2156+Koyukuk+Drive+Fairbanks+AK+99775-7320?entry=gmail&amp;source=g&gt;
Work: 907-474-5172
cell: 907-328-9145

#10normandavis1990
normandavis1990@proton.me
In reply to: Israel Brewster (#8)
Re: High Availability and Replication

On Saturday, March 2nd, 2024 at 12:14 AM, Israel Brewster <ijbrewster@alaska.edu> wrote:

On Mar 1, 2024, at 11:36 AM, normandavis1990 <normandavis1990@proton.me> wrote:

On Thursday, February 29th, 2024 at 11:38 PM, Israel Brewster <ijbrewster@alaska.edu> wrote:

On Feb 29, 2024, at 10:15 AM, David G. Johnston <david.g.johnston@gmail.com> wrote:

On Thursday, February 29, 2024, normandavis1990 <normandavis1990@proton.me> wrote:

What is the difference between High Availability and Replication?

The former is a goal, the later is a technique.

Perhaps more specifically: Replication is simply Replicating - or copying - the “master” database to one or more “slave” databases, generally in real-time such that the slave database clusters are replicas of the master. This is good when the master goes down, because you’ll still have one or more copies of it available, but by itself it doesn’t keep there from being an outage if/when the master goes down.

High Availability layers on top of replication to provide some means of ensuring that the database is HIGHLY available, such as an automatic failover system or load balancer. Many different options that work in many different ways are available to help meet this goal.
---
Israel Brewster
Software Engineer
Alaska Volcano Observatory
Geophysical Institute - UAF
2156 Koyukuk Drive
Fairbanks AK 99775-7320
Work: 907-474-5172
cell: 907-328-9145

David J.

Hi,
You said "This is good when the master goes down, because you’ll still have one or more copies of it available, but by itself it doesn’t keep there from being an outage if/when the master goes down.". What does "goes down" mean?

Exactly what I said - it goes down. Not functioning. Offline. Inaccessible. It is not up and running, therefore, it is down.

In Replication mode, if the primary server is shut down, then the data will also be lost?

No. As I said - and you quoted - “When the master goes down…you’ll still have one or more copies of it available”. So no, the data will NOT be lost.

---
Israel Brewster
Software Engineer
Alaska Volcano Observatory
Geophysical Institute - UAF
2156 Koyukuk Drive
Fairbanks AK 99775-7320
Work: 907-474-5172
cell: 907-328-9145

Hi,
Therefore, in both HA and Replication, when the primary server is shut down, the information is not lost, and the only difference is that in the HA mechanism, another server replaces the primary one, but this is not the case in Replication. Is it true?

#11normandavis1990
normandavis1990@proton.me
In reply to: Abdul Sayeed (#9)
Re: High Availability and Replication

On Saturday, March 2nd, 2024 at 1:24 AM, Abdul Sayeed <abdulsayeed24@gmail.com> wrote:

Hi,

When Master server goes down, either you need to promote one of slave node or configure HA mechanism so that in case of master server goes down it will automatically promote the slave server as new master.

Patroni HA tool would be good option for your requirement.

https://patroni.readthedocs.io/en/latest/README.html

Hope this helps.

Thanks & Regards,
Abdul Sayeed
PostgreSQL DBA

On Sat, 2 Mar 2024 at 2:15 AM, Israel Brewster <ijbrewster@alaska.edu> wrote:

On Mar 1, 2024, at 11:36 AM, normandavis1990 <normandavis1990@proton.me> wrote:

On Thursday, February 29th, 2024 at 11:38 PM, Israel Brewster <ijbrewster@alaska.edu> wrote:

On Feb 29, 2024, at 10:15 AM, David G. Johnston <david.g.johnston@gmail.com> wrote:

On Thursday, February 29, 2024, normandavis1990 <normandavis1990@proton.me> wrote:

What is the difference between High Availability and Replication?

The former is a goal, the later is a technique.

Perhaps more specifically: Replication is simply Replicating - or copying - the “master” database to one or more “slave” databases, generally in real-time such that the slave database clusters are replicas of the master. This is good when the master goes down, because you’ll still have one or more copies of it available, but by itself it doesn’t keep there from being an outage if/when the master goes down.

High Availability layers on top of replication to provide some means of ensuring that the database is HIGHLY available, such as an automatic failover system or load balancer. Many different options that work in many different ways are available to help meet this goal.
---
Israel Brewster
Software Engineer
Alaska Volcano Observatory
Geophysical Institute - UAF
[2156 Koyukuk Drive](https://www.google.com/maps/search/2156+Koyukuk+Drive+Fairbanks+AK+99775-7320?entry=gmail)
[Fairbanks AK 99775-7320](https://www.google.com/maps/search/2156+Koyukuk+Drive+Fairbanks+AK+99775-7320?entry=gmail)
Work: 907-474-5172
cell: 907-328-9145

David J.

Hi,
You said "This is good when the master goes down, because you’ll still have one or more copies of it available, but by itself it doesn’t keep there from being an outage if/when the master goes down.". What does "goes down" mean?

Exactly what I said - it goes down. Not functioning. Offline. Inaccessible. It is not up and running, therefore, it is down.

In Replication mode, if the primary server is shut down, then the data will also be lost?

No. As I said - and you quoted - “When the master goes down…you’ll still have one or more copies of it available”. So no, the data will NOT be lost.

---
Israel Brewster
Software Engineer
Alaska Volcano Observatory
Geophysical Institute - UAF
[2156 Koyukuk Drive](https://www.google.com/maps/search/2156+Koyukuk+Drive+Fairbanks+AK+99775-7320?entry=gmail)
[Fairbanks AK 99775-7320](https://www.google.com/maps/search/2156+Koyukuk+Drive+Fairbanks+AK+99775-7320?entry=gmail)
Work: 907-474-5172
cell: 907-328-9145

Hi,
Does installing Patroni cause the primary server to stop even for a short time?

#12Abdul Sayeed
abdulsayeed24@gmail.com
In reply to: normandavis1990 (#11)
Re: High Availability and Replication

Hi,

Not required.

Thanks & Regards,
Abdul Sayeed
PostgreSQL DBA
Postgres Professional Certified
Skype: abdul.sayeed24

On Sat, 2 Mar 2024 at 12:21 PM, normandavis1990 <normandavis1990@proton.me>
wrote:

Show quoted text

On Saturday, March 2nd, 2024 at 1:24 AM, Abdul Sayeed <

abdulsayeed24@gmail.com> wrote:

Hi,

When Master server goes down, either you need to promote one of slave node
or configure HA mechanism so that in case of master server goes down it
will automatically promote the slave server as new master.

Patroni HA tool would be good option for your requirement.

https://patroni.readthedocs.io/en/latest/README.html

Hope this helps.

Thanks & Regards,
Abdul Sayeed
PostgreSQL DBA

On Sat, 2 Mar 2024 at 2:15 AM, Israel Brewster <ijbrewster@alaska.edu>
wrote:

On Mar 1, 2024, at 11:36 AM, normandavis1990 <normandavis1990@proton.me>
wrote:

On Thursday, February 29th, 2024 at 11:38 PM, Israel Brewster <

ijbrewster@alaska.edu> wrote:

On Feb 29, 2024, at 10:15 AM, David G. Johnston <
david.g.johnston@gmail.com> wrote:

On Thursday, February 29, 2024, normandavis1990 <
normandavis1990@proton.me> wrote:

What is the difference between High Availability and Replication?

The former is a goal, the later is a technique.

Perhaps more specifically: Replication is simply Replicating - or copying
- the “master” database to one or more “slave” databases, generally in
real-time such that the slave database clusters are replicas of the master.
This is good when the master goes down, because you’ll still have one or
more copies of it available, but by itself it doesn’t keep there from being
an outage if/when the master goes down.

High Availability layers on top of replication to provide some means of
ensuring that the database is HIGHLY available, such as an automatic
failover system or load balancer. Many different options that work in many
different ways are available to help meet this goal.
---
Israel Brewster
Software Engineer
Alaska Volcano Observatory
Geophysical Institute - UAF
2156 Koyukuk Drive
<https://www.google.com/maps/search/2156+Koyukuk+Drive+Fairbanks+AK+99775-7320?entry=gmail&gt;
Fairbanks AK 99775-7320
<https://www.google.com/maps/search/2156+Koyukuk+Drive+Fairbanks+AK+99775-7320?entry=gmail&gt;
Work: 907-474-5172
cell: 907-328-9145

David J.

Hi,
You said "This is good when the master goes down, because you’ll still
have one or more copies of it available, but by itself it doesn’t keep
there from being an outage if/when the master goes down.". What does "goes
down" mean?

Exactly what I said - it goes down. Not functioning. Offline.
Inaccessible. It is not up and running, therefore, it is down.

In Replication mode, if the primary server is shut down, then the data
will also be lost?

No. As I said - and you quoted - “When the master goes down…you’ll still
have one or more copies of it available”. So no, the data will NOT be lost.

---
Israel Brewster
Software Engineer
Alaska Volcano Observatory
Geophysical Institute - UAF
2156 Koyukuk Drive
<https://www.google.com/maps/search/2156+Koyukuk+Drive+Fairbanks+AK+99775-7320?entry=gmail&gt;
Fairbanks AK 99775-7320
<https://www.google.com/maps/search/2156+Koyukuk+Drive+Fairbanks+AK+99775-7320?entry=gmail&gt;
Work: 907-474-5172
cell: 907-328-9145

Hi,
Does installing Patroni cause the primary server to stop even for a short
time?