From 874fb8745063242272f3bcccc6de9829f2336583 Mon Sep 17 00:00:00 2001 From: Sarah Hoffmann Date: Thu, 16 Dec 2021 14:26:28 +0100 Subject: [PATCH] consolidate settings for nominatim machines --- cookbooks/nominatim/attributes/default.rb | 2 +- roles/dulcy.rb | 23 +---------------------- roles/longma.rb | 23 +---------------------- roles/nominatim.rb | 21 ++++++++++++++++++++- roles/pummelzacken.rb | 21 +-------------------- roles/stormfly-04.rb | 21 --------------------- 6 files changed, 24 insertions(+), 87 deletions(-) diff --git a/cookbooks/nominatim/attributes/default.rb b/cookbooks/nominatim/attributes/default.rb index 056d41c76..cd5083c57 100644 --- a/cookbooks/nominatim/attributes/default.rb +++ b/cookbooks/nominatim/attributes/default.rb @@ -24,7 +24,7 @@ default[:nominatim][:fpm_pools] = { } default[:nominatim][:config] = { - :tokenizer => "legacy" + :tokenizer => "icu" } default[:nominatim][:redirects] = {} diff --git a/roles/dulcy.rb b/roles/dulcy.rb index 29a4548be..b3f864c6a 100644 --- a/roles/dulcy.rb +++ b/roles/dulcy.rb @@ -32,9 +32,6 @@ default_attributes( :settings => { :defaults => { :work_mem => "240MB", - :maintenance_work_mem => "10GB", - :random_page_cost => "1.5", - :effective_cache_size => "60GB", :fsync => "on", :effective_io_concurrency => "500" } @@ -42,28 +39,10 @@ default_attributes( }, :nominatim => { :state => "standalone", - :enable_backup => false, - :enable_git_updates => true, - :dbadmins => %w[lonvia tomh], :dbcluster => "14/main", :postgis => "3", :flatnode_file => "/ssd/nominatim/nodes.store", - :config => { - :tokenizer => "icu" - }, - :logdir => "/ssd/nominatim/log", - :tablespaces => { - "dosm" => "/ssd/tablespaces/dosm", - "iosm" => "/ssd/tablespaces/iosm", - "dplace" => "/ssd/tablespaces/dplace", - "iplace" => "/ssd/tablespaces/iplace", - "daddress" => "/ssd/tablespaces/daddress", - "iaddress" => "/ssd/tablespaces/iaddress", - "dsearch" => "/ssd/tablespaces/dsearch", - "isearch" => "/ssd/tablespaces/isearch", - "daux" => "/ssd/tablespaces/daux", - "iaux" => "/ssd/tablespaces/iaux" - } + :logdir => "/ssd/nominatim/log" } ) diff --git a/roles/longma.rb b/roles/longma.rb index a8380824f..a22f08a05 100644 --- a/roles/longma.rb +++ b/roles/longma.rb @@ -35,9 +35,6 @@ default_attributes( :settings => { :defaults => { :work_mem => "240MB", - :maintenance_work_mem => "10GB", - :random_page_cost => "1.5", - :effective_cache_size => "60GB", :fsync => "off", :effective_io_concurrency => "500" } @@ -45,28 +42,10 @@ default_attributes( }, :nominatim => { :state => "standalone", - :enable_backup => false, - :enable_git_updates => true, - :dbadmins => %w[lonvia tomh], :dbcluster => "14/main", :postgis => "3", :flatnode_file => "/ssd/nominatim/nodes.store", - :config => { - :tokenizer => "icu" - }, - :logdir => "/ssd/nominatim/log", - :tablespaces => { - "dosm" => "/ssd/tablespaces/dosm", - "iosm" => "/ssd/tablespaces/iosm", - "dplace" => "/ssd/tablespaces/dplace", - "iplace" => "/ssd/tablespaces/iplace", - "daddress" => "/ssd/tablespaces/daddress", - "iaddress" => "/ssd/tablespaces/iaddress", - "dsearch" => "/ssd/tablespaces/dsearch", - "isearch" => "/ssd/tablespaces/isearch", - "daux" => "/ssd/tablespaces/daux", - "iaux" => "/ssd/tablespaces/iaux" - } + :logdir => "/ssd/nominatim/log" } ) diff --git a/roles/nominatim.rb b/roles/nominatim.rb index 8981e500a..49c8a3200 100644 --- a/roles/nominatim.rb +++ b/roles/nominatim.rb @@ -27,7 +27,10 @@ default_attributes( :jit => "off", :shared_buffers => "2GB", :autovacuum_max_workers => "1", - :max_parallel_workers_per_gather => "0" + :max_parallel_workers_per_gather => "0", + :maintenance_work_mem => "10GB", + :random_page_cost => "1.5", + :effective_cache_size => "60GB" } } }, @@ -64,7 +67,23 @@ default_attributes( "net.netfilter.nf_conntrack_max" => "196608" } } + }, + :nominatim => { + :dbadmins => %w[lonvia tomh], + :tablespaces => { + "dosm" => "/ssd/tablespaces/dosm", + "iosm" => "/ssd/tablespaces/iosm", + "dplace" => "/ssd/tablespaces/dplace", + "iplace" => "/ssd/tablespaces/iplace", + "daddress" => "/ssd/tablespaces/daddress", + "iaddress" => "/ssd/tablespaces/iaddress", + "dsearch" => "/ssd/tablespaces/dsearch", + "isearch" => "/ssd/tablespaces/isearch", + "daux" => "/ssd/tablespaces/daux", + "iaux" => "/ssd/tablespaces/iaux" + } } + ) run_list( diff --git a/roles/pummelzacken.rb b/roles/pummelzacken.rb index 5ce024ec7..9095e8ffb 100644 --- a/roles/pummelzacken.rb +++ b/roles/pummelzacken.rb @@ -30,9 +30,6 @@ default_attributes( :defaults => { :listen_addresses => "10.0.0.20", :work_mem => "160MB", - :maintenance_work_mem => "10GB", - :random_page_cost => "1.5", - :effective_cache_size => "60GB", :effective_io_concurrency => "256", :fsync => "on" } @@ -40,26 +37,10 @@ default_attributes( }, :nominatim => { :state => "standalone", - :dbadmins => %w[lonvia tomh], :dbcluster => "13/main", :postgis => "3", :enable_backup => true, - :flatnode_file => "/ssd/nominatim/nodes.store", - :config => { - :tokenizer => "icu" - }, - :tablespaces => { - "dosm" => "/ssd/tablespaces/dosm", - "iosm" => "/ssd/tablespaces/iosm", - "dplace" => "/ssd/tablespaces/dplace", - "iplace" => "/ssd/tablespaces/iplace", - "daddress" => "/ssd/tablespaces/daddress", - "iaddress" => "/ssd/tablespaces/iaddress", - "dsearch" => "/ssd/tablespaces/dsearch", - "isearch" => "/ssd/tablespaces/isearch", - "daux" => "/data/tablespaces/daux", - "iaux" => "/data/tablespaces/iaux" - } + :flatnode_file => "/ssd/nominatim/nodes.store" } ) diff --git a/roles/stormfly-04.rb b/roles/stormfly-04.rb index 6f947994a..b59bf690e 100644 --- a/roles/stormfly-04.rb +++ b/roles/stormfly-04.rb @@ -29,9 +29,6 @@ default_attributes( :settings => { :defaults => { :work_mem => "300MB", - :maintenance_work_mem => "10GB", - :random_page_cost => "1.5", - :effective_cache_size => "60GB", :fsync => "on", :effective_io_concurrency => "100" } @@ -39,33 +36,15 @@ default_attributes( }, :nominatim => { :state => "standalone", - :enable_backup => false, - :enable_git_updates => true, :enable_qa_tiles => true, - :dbadmins => %w[lonvia tomh], :dbcluster => "14/main", :postgis => "3", :flatnode_file => "/ssd/nominatim/nodes.store", :logdir => "/ssd/nominatim/log", - :config => { - :tokenizer => "icu" - }, :fpm_pools => { "nominatim.openstreetmap.org" => { :max_children => 100 } - }, - :tablespaces => { - "dosm" => "/ssd/tablespaces/dosm", - "iosm" => "/ssd/tablespaces/iosm", - "dplace" => "/ssd/tablespaces/dplace", - "iplace" => "/ssd/tablespaces/iplace", - "daddress" => "/ssd/tablespaces/daddress", - "iaddress" => "/ssd/tablespaces/iaddress", - "dsearch" => "/ssd/tablespaces/dsearch", - "isearch" => "/ssd/tablespaces/isearch", - "daux" => "/ssd/tablespaces/daux", - "iaux" => "/ssd/tablespaces/iaux" } } ) -- 2.39.5