From 65784b61d6987b260f9c82ca4ffc368e3c5cba11 Mon Sep 17 00:00:00 2001 From: Malvads Date: Mon, 27 Nov 2023 11:06:07 +0000 Subject: [PATCH 1/5] Add rbcgroupc cookbook as dependency --- resources/metadata.rb | 1 + 1 file changed, 1 insertion(+) diff --git a/resources/metadata.rb b/resources/metadata.rb index 5d51d16a..5c0d649c 100644 --- a/resources/metadata.rb +++ b/resources/metadata.rb @@ -38,3 +38,4 @@ depends 'cron' #depends 'ohai' depends 'rbaioutliers' +depends 'rbcgroup' From 6ee6f07148549586f0cbe174dfce8088130e43ac Mon Sep 17 00:00:00 2001 From: Malvads Date: Mon, 27 Nov 2023 12:23:10 +0000 Subject: [PATCH 2/5] Disable rbaioutliers cookbook --- resources/metadata.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/resources/metadata.rb b/resources/metadata.rb index 5c0d649c..0e7d5fe9 100644 --- a/resources/metadata.rb +++ b/resources/metadata.rb @@ -37,5 +37,5 @@ depends 'rbcep' depends 'cron' #depends 'ohai' -depends 'rbaioutliers' +#depends 'rbaioutliers' depends 'rbcgroup' From 326f096d2a2cf119b0e50f57e9ac25c637ee5626 Mon Sep 17 00:00:00 2001 From: Malvads Date: Mon, 27 Nov 2023 14:37:28 +0000 Subject: [PATCH 3/5] Add configure of cgroups --- resources/recipes/configure.rb | 3 +++ 1 file changed, 3 insertions(+) diff --git a/resources/recipes/configure.rb b/resources/recipes/configure.rb index f6880f21..7e2b583a 100644 --- a/resources/recipes/configure.rb +++ b/resources/recipes/configure.rb @@ -309,6 +309,9 @@ # action (node["redborder"]["services"]["redborder-cep"] ? [:add, :register] : [:remove, :deregister]) #end +rbcgroup_config "Configure cgroups" do + action :add +end # Determine external external_services = Chef::DataBagItem.load("rBglobal", "external_services") From c6daa4e676d013f77c52caa68f643d0d751958e5 Mon Sep 17 00:00:00 2001 From: Malvads Date: Tue, 28 Nov 2023 13:49:25 +0000 Subject: [PATCH 4/5] Check for cluster install before creating cgroups --- resources/recipes/configure.rb | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/resources/recipes/configure.rb b/resources/recipes/configure.rb index 7e2b583a..027d5fcf 100644 --- a/resources/recipes/configure.rb +++ b/resources/recipes/configure.rb @@ -309,8 +309,10 @@ # action (node["redborder"]["services"]["redborder-cep"] ? [:add, :register] : [:remove, :deregister]) #end +cluster_installed = `[ -e /etc/redborder/cluster-installed.txt ] && echo 1 || echo 0` + rbcgroup_config "Configure cgroups" do - action :add + action (cluster_installed == 1 ? :add : nil) end # Determine external From d04d7ccb7e7fb455bdf3dfb77e9bb33c61ef994c Mon Sep 17 00:00:00 2001 From: Malvads Date: Tue, 28 Nov 2023 16:28:43 +0000 Subject: [PATCH 5/5] Do not wait for cluster installation --- resources/recipes/configure.rb | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/resources/recipes/configure.rb b/resources/recipes/configure.rb index 027d5fcf..2c6e1baa 100644 --- a/resources/recipes/configure.rb +++ b/resources/recipes/configure.rb @@ -309,10 +309,9 @@ # action (node["redborder"]["services"]["redborder-cep"] ? [:add, :register] : [:remove, :deregister]) #end -cluster_installed = `[ -e /etc/redborder/cluster-installed.txt ] && echo 1 || echo 0` rbcgroup_config "Configure cgroups" do - action (cluster_installed == 1 ? :add : nil) + action :add end # Determine external