Quick onboard
Deployment
Data Modeling
Connecting
Migration
Query
Operations and Maintenance
Common Maintenance
Partition
Backup and Restore
Expansion
Mirroring
Resource Management
Security
Monitoring
Performance Tuning
Troubleshooting
Reference Guide
Tool guide
Data type
Storage Engine
Executor
Stream
DR (Disaster Recovery)
Configuration
Index
Extension
SQL Reference
This document describes the master/standby port modification utility mxchangeport.
Introduce mxchangeport to safely change MatrixDB ports for master and optionally standby. The workflow performs prechecks, updates catalog and configs, syncs the spec, and completes with a controlled recovery. During revert, a revert-only step restarts replication services to promptly restore connectivity.
postgresql.conf: set port per targeted instance.defaults.conf: update MasterPortBase/StandbyPortBase.cluster.conf: set PGPort for the host.recover_db_cluster.json: refresh DBID→port mappings.postgresql.auto.conf: patch primary_conninfo port.update_bash: refresh mxadmin environment (PGPORT).mxchangeport run --new-port 6432
mxchangeport run --new-port 6432 --with-standby
mxchangeport run --new-port 6432 --with-standby --standby-port 7432
mxchangeport run --new-port 6432 --revert-test
mxchangeport run --new-port 6432 --with-standby --standby-port 7432 --gen-init > init.json
mxchangeport run --init-file init.json --gen-plan > plan.json
Execute plan:
mxchangeport run --plan-file plan.json
Note!
With--with-standbyand no--standby-port, standby uses the same new port.