A maioria dos valores de parâmetros padrão do PostgreSQL permanece inalterada, porque as mudanças são limitadas a parâmetros que beneficiam a maioria dos aplicativos.
Os valores sugeridos desses parâmetros geralmente melhoram o desempenho em hardware moderno.
Parâmetro de banco de dados
Padrão do AlloyDB Omni
Configuração sugerida
random_page_cost
4.0
1.1
temp_buffers
8 MB
128 MB
max_wal_size
1 GB
20 GB
min_wal_size
80 MB
10 GB
default_toast_compression
pglz
lz4
maintenance_work_mem
64 MB
1 GB para máquinas menores e 2 GB para máquinas maiores
max_worker_processes
64
max(64, # vCPUs)
max_parallel_workers
8
max(8, # vCPUs)
max_parallel_workers_per_gather
2
max(2, # vCPUs / 2)
work_mem
4 MB
128 a 512 MB, dependendo da carga de trabalho e da quantidade de memória disponível
[[["Fácil de entender","easyToUnderstand","thumb-up"],["Meu problema foi resolvido","solvedMyProblem","thumb-up"],["Outro","otherUp","thumb-up"]],[["Difícil de entender","hardToUnderstand","thumb-down"],["Informações incorretas ou exemplo de código","incorrectInformationOrSampleCode","thumb-down"],["Não contém as informações/amostras de que eu preciso","missingTheInformationSamplesINeed","thumb-down"],["Problema na tradução","translationIssue","thumb-down"],["Outro","otherDown","thumb-down"]],["Última atualização 2025-09-04 UTC."],[[["\u003cp\u003eThis document outlines performance tuning parameters specifically for AlloyDB Omni on a VM, based on various workload tests.\u003c/p\u003e\n"],["\u003cp\u003eThe suggested parameter changes focus on improving performance for most applications on modern hardware, while keeping most default PostgreSQL parameter values unchanged.\u003c/p\u003e\n"],["\u003cp\u003eKey parameters to adjust include \u003ccode\u003erandom_page_cost\u003c/code\u003e, \u003ccode\u003etemp_buffers\u003c/code\u003e, \u003ccode\u003emax_wal_size\u003c/code\u003e, \u003ccode\u003emin_wal_size\u003c/code\u003e, \u003ccode\u003edefault_toast_compression\u003c/code\u003e, and several memory-related settings like \u003ccode\u003emaintenance_work_mem\u003c/code\u003e and \u003ccode\u003ework_mem\u003c/code\u003e.\u003c/p\u003e\n"],["\u003cp\u003eThe tuning parameters for \u003ccode\u003emax_worker_processes\u003c/code\u003e, \u003ccode\u003emax_parallel_workers\u003c/code\u003e, and \u003ccode\u003emax_parallel_workers_per_gather\u003c/code\u003e should be adjusted based on the number of vCPUs.\u003c/p\u003e\n"],["\u003cp\u003eThe \u003ccode\u003eeffective_cache_size\u003c/code\u003e parameter is recommended to be set to 80% of DRAM, and \u003ccode\u003ework_mem\u003c/code\u003e should be adjusted from 128 to 512 MB depending on workload and memory availability.\u003c/p\u003e\n"]]],[],null,["# AlloyDB Omni performance tuning parameters on a VM\n\nSelect a documentation version: 15.7.1keyboard_arrow_down\n\n- [Current (16.8.0)](/alloydb/omni/current/docs/performance-tuning-parameters)\n- [16.8.0](/alloydb/omni/16.8.0/docs/performance-tuning-parameters)\n- [16.3.0](/alloydb/omni/16.3.0/docs/performance-tuning-parameters)\n- [15.12.0](/alloydb/omni/15.12.0/docs/performance-tuning-parameters)\n- [15.7.1](/alloydb/omni/15.7.1/docs/performance-tuning-parameters)\n- [15.7.0](/alloydb/omni/15.7.0/docs/performance-tuning-parameters)\n\n\u003cbr /\u003e\n\nThis document describes performance tuning parameters that can improve AlloyDB Omni performance on a VM. These suggested tuning parameters are based on the results of running a set of workloads that exhibit different read and write patterns, caching behaviors, and index access patterns.\n\n\u003cbr /\u003e\n\nMost default PostgreSQL parameter values remain unchanged, because the changes are limited to parameters that benefit the majority of applications.\nThe suggested values of these parameters should generally improve performance\non modern hardware."]]