| # |
| # Licensed to the Apache Software Foundation (ASF) under one or more |
| # contributor license agreements. See the NOTICE file distributed with |
| # this work for additional information regarding copyright ownership. |
| # The ASF licenses this file to You under the Apache License, Version 2.0 |
| # (the "License"); you may not use this file except in compliance with |
| # the License. You may obtain a copy of the License at |
| # |
| # http://www.apache.org/licenses/LICENSE-2.0 |
| # |
| # Unless required by applicable law or agreed to in writing, software |
| # distributed under the License is distributed on an "AS IS" BASIS, |
| # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| # See the License for the specific language governing permissions and |
| # limitations under the License. |
| # |
| |
| - hosts: metrics |
| become: yes |
| tasks: |
| - name: "stop influxdb and grafana" |
| service: name={{ item }} state=stopped |
| with_items: |
| - influxdb |
| - grafana-server |
| - name: "wipe influxdb data" |
| file: path={{ default_data_dirs[0] }}/influxdb state=absent |
| - name: "wipe grafana db" |
| file: path=/var/lib/grafana/grafana.db state=absent |
| - include: kill.yml |
| - hosts: all |
| tasks: |
| - name: "wipe software installation dirs" |
| file: path={{ item }} state=absent |
| with_items: |
| - "{{ hadoop_home }}" |
| - "{{ zookeeper_home }}" |
| - "{{ accumulo_home }}" |
| - "{{ fluo_home }}" |
| - "{{ spark_home }}" |
| - hosts: hadoop |
| tasks: |
| - name: "wipe hadoop data" |
| file: path={{item}}/hadoop state=absent |
| with_items: "{{ worker_data_dirs }}" |
| - name: "remove hadoop logs" |
| shell: rm -rf {{ hadoop_home }}/logs/* |
| - hosts: zookeepers |
| tasks: |
| - name: "wipe zookeeper data" |
| file: path={{ default_data_dirs[0] }}/zookeeper state=absent |
| - name: "remove zookeeper logs" |
| file: path={{ zookeeper_home }}/zookeeper.out state=absent |
| - hosts: accumulo |
| tasks: |
| - name: "remove accumulo logs" |
| shell: rm -rf {{ accumulo_home }}/logs/* |