<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>How-to Guides on Mimus</title><link>https://mimus.pgsty.com/docs/guides/</link><description>Recent content in How-to Guides on Mimus</description><generator>Hugo</generator><language>en-US</language><lastBuildDate>Sun, 06 Dec 2026 15:37:05 +0800</lastBuildDate><atom:link href="https://mimus.pgsty.com/docs/guides/index.xml" rel="self" type="application/rss+xml"/><item><title>Conflict resolution and standby failover</title><link>https://mimus.pgsty.com/docs/guides/failover-and-conflicts/</link><guid>https://mimus.pgsty.com/docs/guides/failover-and-conflicts/</guid><description>&lt;h2 id="policies"&gt;Choose conflict arbitration rules&#10;&lt;/h2&gt;&#10;&lt;p&gt;Asynchronous multi-master replication allows two nodes to commit writes to the same row before replicating to each other. Before adding a table to a &lt;code&gt;spock&lt;/code&gt; replication set, configure &lt;code&gt;track_commit_timestamp = on&lt;/code&gt; on every node and match each table column pattern to a deterministic conflict rule:&lt;/p&gt;&#10;&lt;ul&gt;&#10;&lt;li&gt;&lt;strong&gt;Last-update-wins (&lt;code&gt;last_update_wins&lt;/code&gt;)&lt;/strong&gt;: Resolves concurrent &lt;code&gt;INSERT&lt;/code&gt;/&lt;code&gt;UPDATE&lt;/code&gt; conflicts using commit timestamps; Mimus kernel layers &lt;code&gt;200&lt;/code&gt; / &lt;code&gt;201&lt;/code&gt; preserve surviving subtransaction commit timestamps inside &lt;code&gt;COMMIT&lt;/code&gt; WAL so physical standbys see identical timestamps.&lt;/li&gt;&#10;&lt;li&gt;&lt;strong&gt;Delta-apply (&lt;code&gt;spock.delta_apply&lt;/code&gt;)&lt;/strong&gt;: For numeric counters and balances, enable &lt;code&gt;log_old_value = true&lt;/code&gt; and &lt;code&gt;delta_apply_function = spock.delta_apply&lt;/code&gt; on the column so concurrent increments and decrements commute cleanly.&lt;/li&gt;&#10;&lt;li&gt;&lt;strong&gt;Distributed IDs&lt;/strong&gt;: Avoid colliding &lt;code&gt;SERIAL&lt;/code&gt; sequences across writable nodes by assigning disjoint sequence ranges, UUIDs, or the pgEdge &lt;a href="https://mimus.pgsty.com/docs/spock/upstream/snowflake/"&gt;Snowflake&lt;/a&gt; extension.&lt;/li&gt;&#10;&lt;/ul&gt;&#10;&lt;h2 id="monitoring"&gt;Monitor subscriptions and conflict logs&#10;&lt;/h2&gt;&#10;&lt;p&gt;Check subscription state, replication slot lag, and recorded conflict history on every writable node:&lt;/p&gt;</description></item><item><title>Build extensions, run REPACK and validate workloads</title><link>https://mimus.pgsty.com/docs/guides/extensions/</link><guid>https://mimus.pgsty.com/docs/guides/extensions/</guid><description>&lt;h2 id="abi"&gt;Choosing extension binaries&#10;&lt;/h2&gt;&#10;&lt;p&gt;Build native C and Rust (&lt;code&gt;pgrx 0.20.1&lt;/code&gt;) extensions using the &lt;code&gt;pg_config&lt;/code&gt; binary and server headers from the target &lt;code&gt;/usr/mimus-19&lt;/code&gt; installation:&lt;/p&gt;&#10;&lt;div class="td-code td-code--untitled" id="td-code-e1f248e7-fence-0" data-td-code data-td-code-auto-id&#10; data-td-language="sh" data-td-line-count="3"&gt;&#10; &lt;div class="td-code__viewport" id="td-code-e1f248e7-fence-0-viewport" data-td-code-viewport&gt;&lt;div class="highlight"&gt;&lt;pre tabindex="0" class="chroma"&gt;&lt;code class="language-sh" data-lang="sh"&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="nb"&gt;export&lt;/span&gt; &lt;span class="nv"&gt;PATH&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s2"&gt;&amp;#34;/usr/mimus-19/bin:&lt;/span&gt;&lt;span class="nv"&gt;$PATH&lt;/span&gt;&lt;span class="s2"&gt;&amp;#34;&lt;/span&gt;&#10;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;make &lt;span class="nv"&gt;PG_CONFIG&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;/usr/mimus-19/bin/pg_config&#10;&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;sudo make &lt;span class="nv"&gt;PG_CONFIG&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;/usr/mimus-19/bin/pg_config install&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;&#10;&lt;/div&gt;&#10;&lt;p&gt;A shared PostgreSQL 19 major version establishes the SQL baseline, not universal drop-in ABI compatibility with prebuilt third-party binaries, because the unified Mimus kernel includes Babelfish parser/executor hooks alongside storage and replication interfaces. &lt;code&gt;pgrx 0.20.1&lt;/code&gt; header compatibility is verified against Mimus &lt;code&gt;19.0.1-r4&lt;/code&gt; (790 PG 19 tests passed). For workloads requiring &lt;strong&gt;Citus&lt;/strong&gt; or &lt;strong&gt;TimescaleDB&lt;/strong&gt;, deploy a separate community PostgreSQL cluster.&lt;/p&gt;</description></item><item><title>Backup, restore and encrypted recovery</title><link>https://mimus.pgsty.com/docs/guides/backup-and-recovery/</link><guid>https://mimus.pgsty.com/docs/guides/backup-and-recovery/</guid><description>&lt;h2 id="physical-backup"&gt;Run physical backups and offline page checks&#10;&lt;/h2&gt;&#10;&lt;p&gt;Use &lt;code&gt;pg_basebackup&lt;/code&gt; from the matching &lt;code&gt;/usr/mimus-19/bin&lt;/code&gt; installation to take physical backups of Mimus clusters, including instances with &lt;code&gt;pg_tde&lt;/code&gt;, &lt;code&gt;spock&lt;/code&gt;, &lt;code&gt;pg_mysql&lt;/code&gt;, or &lt;code&gt;Babelfish&lt;/code&gt; enabled:&lt;/p&gt;&#10;&lt;div class="td-code td-code--untitled" id="td-code-b16ab2d1-fence-0" data-td-code data-td-code-auto-id&#10; data-td-language="sh" data-td-line-count="1"&gt;&#10; &lt;div class="td-code__viewport" id="td-code-b16ab2d1-fence-0-viewport" data-td-code-viewport&gt;&lt;div class="highlight"&gt;&lt;pre tabindex="0" class="chroma"&gt;&lt;code class="language-sh" data-lang="sh"&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;/usr/mimus-19/bin/pg_basebackup -D /var/backups/mimus-base -Fp -Xs -P -R&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;&#10;&lt;/div&gt;&#10;&lt;p&gt;On encrypted clusters, physical pages on disk contain ciphertext. Standard checksum tools that are unaware of &lt;code&gt;pg_tde&lt;/code&gt; cannot inspect encrypted page payloads directly; always use the Mimus toolchain built with layer &lt;code&gt;100&lt;/code&gt; / &lt;code&gt;101&lt;/code&gt; storage hooks and rehearse independent restore into a separate host before relying on a backup chain.&lt;/p&gt;</description></item><item><title>Instance profiles, ports and authentication</title><link>https://mimus.pgsty.com/docs/guides/instance-planning/</link><guid>https://mimus.pgsty.com/docs/guides/instance-planning/</guid><description>&lt;h2 id="profiles"&gt;Select an instance profile&#10;&lt;/h2&gt;&#10;&lt;p&gt;Every Mimus instance retains its native PostgreSQL listener (&lt;code&gt;5432&lt;/code&gt;) for administration, backup, and native SQL clients. In addition, choose &lt;strong&gt;at most one&lt;/strong&gt; session or document compatibility profile per &lt;code&gt;PGDATA&lt;/code&gt; directory:&lt;/p&gt;&#10;&lt;div class="td-table-scroll td-table-scroll--static"&gt;&#10;&lt;table&gt;&#10; &lt;thead&gt;&#10; &lt;tr&gt;&#10; &lt;th scope="col"&gt;Instance profile&lt;/th&gt;&#10; &lt;th scope="col"&gt;&lt;code&gt;shared_preload_libraries&lt;/code&gt; baseline&lt;/th&gt;&#10; &lt;th scope="col"&gt;Client ports&lt;/th&gt;&#10; &lt;/tr&gt;&#10; &lt;/thead&gt;&#10; &lt;tbody&gt;&#10; &lt;tr&gt;&#10; &lt;td&gt;Native PostgreSQL&lt;/td&gt;&#10; &lt;td&gt;&lt;em&gt;(empty, or &lt;code&gt;pg_tde&lt;/code&gt;, &lt;code&gt;spock&lt;/code&gt;)&lt;/em&gt;&lt;/td&gt;&#10; &lt;td&gt;&lt;code&gt;5432&lt;/code&gt;&lt;/td&gt;&#10; &lt;/tr&gt;&#10; &lt;tr&gt;&#10; &lt;td&gt;MySQL compatible&lt;/td&gt;&#10; &lt;td&gt;&lt;code&gt;pg_mysql&lt;/code&gt; &lt;em&gt;(plus optional &lt;code&gt;pg_tde&lt;/code&gt;, &lt;code&gt;spock&lt;/code&gt;)&lt;/em&gt;&lt;/td&gt;&#10; &lt;td&gt;&lt;code&gt;5432&lt;/code&gt;, &lt;code&gt;3306&lt;/code&gt;&lt;/td&gt;&#10; &lt;/tr&gt;&#10; &lt;tr&gt;&#10; &lt;td&gt;MSSQL compatible&lt;/td&gt;&#10; &lt;td&gt;&lt;code&gt;babelfishpg_tds&lt;/code&gt; &lt;em&gt;(plus optional &lt;code&gt;pg_tde&lt;/code&gt;, &lt;code&gt;spock&lt;/code&gt;)&lt;/em&gt;&lt;/td&gt;&#10; &lt;td&gt;&lt;code&gt;5432&lt;/code&gt;, &lt;code&gt;1433&lt;/code&gt;&lt;/td&gt;&#10; &lt;/tr&gt;&#10; &lt;tr&gt;&#10; &lt;td&gt;MongoDB gateway&lt;/td&gt;&#10; &lt;td&gt;&lt;code&gt;pg_cron&lt;/code&gt;, DocumentDB &lt;em&gt;(single-node)&lt;/em&gt;&lt;/td&gt;&#10; &lt;td&gt;&lt;code&gt;5432&lt;/code&gt;, &lt;code&gt;27017&lt;/code&gt; (gateway)&lt;/td&gt;&#10; &lt;/tr&gt;&#10; &lt;/tbody&gt;&#10;&lt;/table&gt;&#10;&lt;/div&gt;&#10;&#10;&lt;p&gt;Service gateways that require zero kernel patches (&lt;code&gt;pgredis&lt;/code&gt;, &lt;code&gt;pgetcd&lt;/code&gt;, &lt;code&gt;pgsilo&lt;/code&gt;) connect over standard PostgreSQL pools and load their companion extensions (&lt;code&gt;pg_redis&lt;/code&gt;, &lt;code&gt;pg_etcd&lt;/code&gt;, or &lt;code&gt;silo&lt;/code&gt; schemas) on stock or Mimus instances.&lt;/p&gt;</description></item></channel></rss>