Movatterモバイル変換


[0]ホーム

URL:


Ardent Performance Computing

Jeremy Schneider

Search

    >
    Home

    Latest Post

    Testing CloudNativePG Preferred Data Durability

    Posted by

    This is the third post about running Jepsen against CloudNativePG. Earlier posts:

    First: shout out to whoever first came up with Oracle Data Guard Protection Modes. Designing it to be explained as a choice between performance, availability and protection was a great idea.

    Yesterday’s blog post described how the core of all data safety iscopies of the data, and the importance of efficient architectures to meet data safety requirements.

    With Postgres, three-node clusters ensure the highest level of availability if one host fails. But two-node clusters are often worth the cost savings in exchange for a few seconds of unavailability during cluster reconfigurations. Similar to Oracle, Postgres two-node clusters can be configured to maximize performance or availability or protection.

    Oracle Data Guard modeBehaviorPatroni configurationCloudNativePG configuration
    Max Performance 
    oracle default
    Async; fastest commits; possible data loss on failoverpatroni defaultcnpg default
    Max Availability (NOAFFIRM)Sync when standby available; acknowledge after standby write (not flush); if none available, don’t blocksynchronous_mode: true
    synchronous_commit: remote_write
    method: any
    number: 1
    dataDurability: preferred
    synchronous_commit: remote_write
    Max Availability (AFFIRM)Sync when standby available; acknowledge after standby flush; if none available, don’t blocksynchronous_mode: truemethod: any
    number: 1
    dataDurability: preferred
    Max ProtectionAlways sync; if no sync standby, block commits (no data loss)synchronous_mode: true
    synchronous_mode_strict: true
    method: any
    number: 1

    Automated failovers can involve a small amount of data loss with maximum performance and maximum availability configurations. With Oracle Fast-Start Failover, the FastStartFailoverLagLimit configuration property indicates the maximum amount of data loss that is permissible in order for an automatic failover to occur.

    Theprevious blog post in this series compared CloudNativePG Max Performance and Max Protection modes. Now I want to take a look at Max Availability. In CloudNativePG, the key setting here is spec.postgresql.synchronous.dataDurability. When dataDurability is set to preferred, the required number of synchronous instances adjusts based on the number of available standbys. PostgreSQL will attempt to replicate WAL records to the designated number of synchronous standbys, but write operations will continue even if fewer than the requested number of standbys are available.

    All of these experiments were executed on my HP EliteBook (Ryzen Pro 5) with two CNPG Lab VMs via Hyper‑V and the tests ran in a loop for 12–24 hours to aggregate failure rates across the runs.

    Continue reading
    Leave a commentkubernetes,Planet,PostgreSQL,Technical

    What is Ardent?

    ADJECTIVE:
    1. Warmth of feeling; passionate
    2. Strong enthusiasm or devotion; fervent
    3. Burning/fiery or glowing/shining
    (American Heritage Dictionary)

    Subscribe

    RSS Feed RSS - Posts

    Social

    As of 2025: I'm on LinkedIn most. Also Slack and Discord but don't have Discord invite links handy. I check Twitter/X on occasion. Haven't been on IRC regularly since the old days, before the PG folks moved to Libera. I've de-supported all other (old) social accounts listed here, but I'll keep them handy for theZombie Apocalypse.

    LinkedIn:linkedin.com/in/ardentperf/
    Slack: jer_s@pgtreats.info/slack-invite

    Twitter/X:jer_s
    IRC: jer_s@FreeNode (#postgresql, #ansible, #oracle, ##oracledb)
    AIM, MSN, Google: jeremy.schneider@ardentperf.com
    Yahoo: ardentperf
    ICQ: 614052660

    Disclaimer

    This is my personal website. The views expressed here are mine alone and may not reflect the views of my employer.I am currently looking for consulting and/or contracting work in the USA around the oracle database ecosystem.

    contact:312-725-9249 orschneider @ ardentperf.com


    https://about.me/jeremy_schneider

    oaktableocmaceracattack

    (a)

    Enter your email address to receive notifications of new posts by email.

    Email Address:

    Join 73 other subscribers

    Recent Posts

    Recent Comments

    Ardent Performance Computing

    Create a website or blog at WordPress.com


    [8]ページ先頭

    ©2009-2025 Movatter.jp