HomeMogDBMogDB StackUqbar
v6.3

Documentation:v6.3

Supported Versions:

Parameter Optimization

When creating a database, if the optimization parameter switch is enabled and the server memory for the instance to be deployed is greater than 4GB, some recommended parameter values will be set by default to optimize the database.

Note: If the server memory is less than 4GB, none of the following parameters will be modified.

Below is the list of optimized parameters (consistent with the recommended parameters on the official website of PTK):

Part One: Parameters Related to Memory Size (assuming memory size is N, in GB)

  • When 4 < N <= 8
Parameter Value
max_connections 500
max_prepared_transactions 500
max_process_memory (0.6*N)GB
shared_buffers (0.2*N)GB
work_mem 16MB
maintenance_work_mem 512MB
wal_buffers 128MB
  • When 8 < N <= 64
Parameter Value
max_connections 1000
max_prepared_transactions 1000
max_process_memory (0.7*N)GB
shared_buffers (0.2*N)GB
work_mem 32MB
maintenance_work_mem 1GB
wal_buffers 512MB
  • When N > 64
Parameter Value
max_connections 3000
max_prepared_transactions 3000
max_process_memory (0.8*N)GB
shared_buffers (0.3*N)GB
work_mem 64MB
maintenance_work_mem 2GB
wal_buffers 1GB

Part Two: Fixed Optimization Parameter List

Parameter Value
remote_read_mode non_authentication
password_encryption_type 1
password_reuse_time 0
password_lock_time 0
password_effect_time 0
session_timeout 0
modify_initial_password off
wal_level logical
full_page_writes off
wal_log_hints off
xloginsert_locks 48
advance_xlog_file_num 10
wal_keep_segments 1024
most_available_sync on
catchup2normal_wait_time 0
enable_slot_log on
max_replication_slots 32
wal_receiver_timeout 60s
sync_config_strategy none_node
log_line_prefix '%m %u %d %r %p %S'
log_checkpoints on
vacuum_cost_limit 1000
autovacuum_max_workers 10
autovacuum_naptime 20s
autovacuum_vacuum_cost_delay 10
autovacuum_vacuum_scale_factor 0.05
autovacuum_analyze_scale_factor 0.02
autovacuum_vacuum_threshold 200
autovacuum_analyze_threshold 200
autovacuum_io_limits 104857600
instr_unique_sql_count 200000
enable_wdr_snapshot on
log_min_duration_statement 200
track_activity_query_size 2048
enable_instr_rt_percentile off
cstore_buffers 16MB
local_syscache_threshold 32MB
standby_shared_buffers_fraction 1
checkpoint_segments 1024
checkpoint_completion_target 0.8
max_files_per_process 100000
behavior_compat_options display_leading_zero
lc_messages en_US.UTF-8
lc_monetary en_US.UTF-8
lc_numeric en_US.UTF-8
lc_time en_US.UTF-8
enable_opfusion off
Copyright © 2011-2024 www.enmotech.com All rights reserved.