]> git.openstreetmap.org Git - chef.git/blobdiff - cookbooks/tile/templates/default/replicate.erb
Disable JIT and parallel workers for replication with postgres 12
[chef.git] / cookbooks / tile / templates / default / replicate.erb
index 83fec6fb7d123ff94965c7d0fec93b939bd4f2a9..bdd271f61a044a2c8474e3a22f6be99df3f78ff6 100644 (file)
@@ -17,6 +17,11 @@ exec > /var/log/tile/replicate.log 2>&1
 
 # Change to the replication state directory
 cd /var/lib/replicate
+<% if @postgresql_version >= 12 -%>
+
+# Disable JIT and parallel workers in postgres
+export PGOPTIONS="-c jit=off -c max_parallel_workers_per_gather=0"
+<% end -%>
 
 # Install exit handler
 trap onexit EXIT