diff --git a/scripts/legacy/tar/linux/opensearch-tar-install.sh b/scripts/legacy/tar/linux/opensearch-tar-install.sh index 07da0d933b..a1f19eb812 100755 --- a/scripts/legacy/tar/linux/opensearch-tar-install.sh +++ b/scripts/legacy/tar/linux/opensearch-tar-install.sh @@ -27,6 +27,7 @@ if ! grep -q '## OpenSearch Performance Analyzer' $OPENSEARCH_HOME/config/jvm.op echo "-Dclk.tck=$CLK_TCK" >> $OPENSEARCH_HOME/config/jvm.options echo "-Djdk.attach.allowAttachSelf=true" >> $OPENSEARCH_HOME/config/jvm.options echo "-Djava.security.policy=$OPENSEARCH_HOME/plugins/opensearch-performance-analyzer/pa_config/opensearch_security.policy" >> $OPENSEARCH_HOME/config/jvm.options + echo "--add-opens=jdk.attach/sun.tools.attach=ALL-UNNAMED" >> $OPENSEARCH_HOME/config/jvm.options fi echo "done plugins" diff --git a/scripts/opensearch-onetime-setup.sh b/scripts/opensearch-onetime-setup.sh index c2c62e5eae..c275c851eb 100755 --- a/scripts/opensearch-onetime-setup.sh +++ b/scripts/opensearch-onetime-setup.sh @@ -46,5 +46,6 @@ if ! grep -q '## OpenDistro Performance Analyzer' $OPENSEARCH_HOME/config/jvm.op echo "-Dclk.tck=$CLK_TCK" >> $OPENSEARCH_HOME/config/jvm.options echo "-Djdk.attach.allowAttachSelf=true" >> $OPENSEARCH_HOME/config/jvm.options echo "-Djava.security.policy=$OPENSEARCH_HOME/plugins/$PA_PLUGIN/pa_config/opensearch_security.policy" >> $OPENSEARCH_HOME/config/jvm.options + echo "--add-opens=jdk.attach/sun.tools.attach=ALL-UNNAMED" >> $OPENSEARCH_HOME/config/jvm.options fi diff --git a/scripts/pkg/build_templates/opensearch/opensearch.rpm.spec b/scripts/pkg/build_templates/opensearch/opensearch.rpm.spec index 1bb5209282..3065d250cd 100644 --- a/scripts/pkg/build_templates/opensearch/opensearch.rpm.spec +++ b/scripts/pkg/build_templates/opensearch/opensearch.rpm.spec @@ -94,6 +94,7 @@ if ! grep -q '## OpenSearch Performance Analyzer' %{config_dir}/jvm.options; the echo "-Dclk.tck=$CLK_TCK" >> %{config_dir}/jvm.options echo "-Djdk.attach.allowAttachSelf=true" >> %{config_dir}/jvm.options echo "-Djava.security.policy=file:///usr/share/opensearch/plugins/opensearch-performance-analyzer/pa_config/opensearch_security.policy" >> %{config_dir}/jvm.options + echo "--add-opens=jdk.attach/sun.tools.attach=ALL-UNNAMED" >> %{config_dir}/jvm.options fi # Reload systemctl daemon if command -v systemctl > /dev/null; then