diff --git a/ansible/inventory/all-in-one b/ansible/inventory/all-in-one index a720a7d069..005054d813 100644 --- a/ansible/inventory/all-in-one +++ b/ansible/inventory/all-in-one @@ -230,10 +230,6 @@ common [opensearch:children] control -# TODO: This is used for cleanup and can be removed in the Antelope cycle. -[elasticsearch-curator:children] -opensearch - # Opensearch dashboards [opensearch-dashboards:children] opensearch diff --git a/ansible/inventory/multinode b/ansible/inventory/multinode index b8479c6ae7..4ca2274285 100644 --- a/ansible/inventory/multinode +++ b/ansible/inventory/multinode @@ -248,10 +248,6 @@ common [opensearch:children] control -# TODO: This is used for cleanup and can be removed in the Antelope cycle. -[elasticsearch-curator:children] -opensearch - # Opensearch dashboards [opensearch-dashboards:children] opensearch diff --git a/ansible/roles/opensearch/tasks/precheck.yml b/ansible/roles/opensearch/tasks/precheck.yml index 997c030dda..835316f09e 100644 --- a/ansible/roles/opensearch/tasks/precheck.yml +++ b/ansible/roles/opensearch/tasks/precheck.yml @@ -11,7 +11,6 @@ container_engine: "{{ kolla_container_engine }}" name: - opensearch - - elasticsearch check_mode: false register: container_facts @@ -23,6 +22,5 @@ timeout: 1 state: stopped when: - - container_facts['elasticsearch'] is not defined - container_facts['opensearch'] is not defined - inventory_hostname in groups['opensearch'] diff --git a/ansible/roles/opensearch/tasks/upgrade.yml b/ansible/roles/opensearch/tasks/upgrade.yml index f0b8f78cf0..2891b64e08 100644 --- a/ansible/roles/opensearch/tasks/upgrade.yml +++ b/ansible/roles/opensearch/tasks/upgrade.yml @@ -1,8 +1,4 @@ --- -# NOTE: The following tasks assume that the same hosts are used for -# OpenSearch as were for ElasticSearch / Kibana, and that the -# OpenSearch endpoint remains the same as ElasticSearch. - - name: Disable shard allocation become: true vars: @@ -38,55 +34,6 @@ register: result until: ('status' in result) and result.status == 200 -- name: Stop and remove ElasticSearch - become: true - kolla_docker: - action: "stop_and_remove_container" - name: "elasticsearch" - when: - - inventory_hostname in groups['opensearch'] - -- name: Stop and remove ElasticSearch Curator - become: true - kolla_docker: - action: "stop_and_remove_container" - name: "elasticsearch_curator" - when: - - inventory_hostname in groups['elasticsearch-curator'] - -- name: Stop and remove Kibana - become: true - kolla_docker: - action: "stop_and_remove_container" - name: "kibana" - when: - - inventory_hostname in groups['opensearch-dashboards'] - -- name: Delete ElasticSearch load-balancer config - file: - path: "{{ node_config_directory }}/haproxy/services.d/elasticsearch.cfg" - state: "absent" - become: true - when: - - inventory_hostname in groups['loadbalancer'] - -- name: Delete Kibana load-balancer config - file: - path: "{{ node_config_directory }}/haproxy/services.d/kibana.cfg" - state: "absent" - become: true - when: - - inventory_hostname in groups['loadbalancer'] - -# TODO: Use the volume name from defaults.yml -- name: Create OpenSearch Docker volume - become: true - command: "docker volume create opensearch" - -- name: Migrate ElasticSearch data to OpenSearch - become: true - command: "mv /var/lib/docker/volumes/elasticsearch/_data/nodes /var/lib/docker/volumes/opensearch/_data/" - - import_tasks: config-host.yml - import_tasks: config.yml diff --git a/tests/run.yml b/tests/run.yml index b30d13a414..fb9b83042c 100644 --- a/tests/run.yml +++ b/tests/run.yml @@ -509,17 +509,6 @@ environment: KOLLA_ANSIBLE_VENV_PATH: "{{ kolla_ansible_venv_path }}" - - name: Run test-prometheus-efk.sh script - script: - cmd: test-prometheus-efk.sh - executable: /bin/bash - chdir: "{{ kolla_ansible_src_dir }}" - environment: - TLS_ENABLED: "{{ tls_enabled }}" - when: - - is_upgrade - - scenario == "prometheus-opensearch" - - name: Run test-prometheus-opensearch.sh script script: cmd: test-prometheus-opensearch.sh @@ -528,7 +517,6 @@ environment: TLS_ENABLED: "{{ tls_enabled }}" when: - - not is_upgrade - scenario == "prometheus-opensearch" - name: Run test-venus.sh script diff --git a/tests/templates/inventory.j2 b/tests/templates/inventory.j2 index bd12a267af..ae8c54993d 100644 --- a/tests/templates/inventory.j2 +++ b/tests/templates/inventory.j2 @@ -116,11 +116,6 @@ monitoring network storage -{% if is_upgrade %} -[elasticsearch:children] -control -{% endif %} - # NOTE(yoctozepto): Until we are able to isolate network namespaces in k-a, # we are forced to separate Pacemaker remotes from full members. # This is not as bad as it sounds, because it would be enforced in @@ -286,11 +281,6 @@ common [kolla-toolbox:children] common -{% if is_upgrade %} -[elasticsearch-curator:children] -elasticsearch -{% endif %} - [opensearch:children] control @@ -704,11 +694,7 @@ monitoring monitoring [prometheus-elasticsearch-exporter:children] -{% if is_upgrade %} -elasticsearch -{% else %} opensearch -{% endif %} [prometheus-blackbox-exporter:children] monitoring diff --git a/tests/test-prometheus-efk.sh b/tests/test-prometheus-efk.sh deleted file mode 100644 index 436b2b8d5a..0000000000 --- a/tests/test-prometheus-efk.sh +++ /dev/null @@ -1,189 +0,0 @@ -#!/bin/bash - -set -o xtrace -set -o errexit -set -o pipefail - -# Enable unbuffered output -export PYTHONUNBUFFERED=1 - -function check_kibana { - # Perform and validate a basic status page check - KIBANA_URL=${OS_AUTH_URL%:*}:5601/api/status - output_path=$1 - kibana_password=$(awk '$1 == "kibana_password:" { print $2 }' /etc/kolla/passwords.yml) - args=( - --include - --location - --fail - --user - kibana:$kibana_password - ) - if [[ "$TLS_ENABLED" = "True" ]]; then - args+=(--cacert $OS_CACERT) - fi - if ! curl "${args[@]}" $KIBANA_URL > $output_path; then - return 1 - fi - if ! grep 'Looking good' $output_path >/dev/null; then - return 1 - fi -} - -function check_elasticsearch { - # Verify that we see a healthy index created due to Fluentd forwarding logs - ELASTICSEARCH_URL=${OS_AUTH_URL%:*}:9200/_cluster/health - output_path=$1 - args=( - --include - --location - --fail - ) - if [[ "$TLS_ENABLED" = "True" ]]; then - args+=(--cacert $OS_CACERT) - fi - if ! curl "${args[@]}" $ELASTICSEARCH_URL > $output_path; then - return 1 - fi - # NOTE(mgoddard): Status may be yellow because no indices have been - # created. - if ! grep -E '"status":"(green|yellow)"' $output_path >/dev/null; then - return 1 - fi -} - -function check_grafana { - # Query grafana, and check that the returned page looks like a grafana page. - GRAFANA_URL=${OS_AUTH_URL%:*}:3000 - output_path=$1 - grafana_password=$(awk '$1 == "grafana_admin_password:" { print $2 }' /etc/kolla/passwords.yml) - args=( - --include - --location - --fail - --user - admin:$grafana_password - ) - if [[ "$TLS_ENABLED" = "True" ]]; then - args+=(--cacert $OS_CACERT) - fi - if ! curl "${args[@]}" $GRAFANA_URL > $output_path; then - return 1 - fi - if ! grep '