diff --git a/hosts.astana b/hosts.astana index b776016..c307e3e 100644 --- a/hosts.astana +++ b/hosts.astana @@ -1,6 +1,6 @@ [all:vars] ansible_user=root -rpm_file_name=tsg-cli-1.0.11.d276da8-1.el7.x86_64.rpm +rpm_file_name=tsg-cli-1.0.13.c6d5037-1.el7.x86_64.rpm [sled-mxn] 10.4.164.23 SN=CBT2201840103110 diff --git a/hosts.huayan b/hosts.huayan index fee4760..433b2ac 100644 --- a/hosts.huayan +++ b/hosts.huayan @@ -1,6 +1,6 @@ [all:vars] ansible_user=root -rpm_file_name=tsg-cli-1.0.11.d276da8-1.el7.x86_64.rpm +rpm_file_name=tsg-cli-1.0.13.c6d5037-1.el7.x86_64.rpm [sled-mxn] 192.168.10.45 SN=CBT2201925000001 diff --git a/hosts.xxg b/hosts.xxg.165.sn001 similarity index 82% rename from hosts.xxg rename to hosts.xxg.165.sn001 index 8eed513..9961706 100644 --- a/hosts.xxg +++ b/hosts.xxg.165.sn001 @@ -1,6 +1,6 @@ [all:vars] ansible_user=root -rpm_file_name=tsg-cli-1.0.11.d276da8-1.el7.x86_64.rpm +rpm_file_name=tsg-cli-1.0.13.c6d5037-1.el7.x86_64.rpm [sled-mxn] 192.168.40.165 SN=CBT2201925000001 diff --git a/hosts.xxg.170.sn003 b/hosts.xxg.170.sn003 new file mode 100644 index 0000000..05b8140 --- /dev/null +++ b/hosts.xxg.170.sn003 @@ -0,0 +1,36 @@ +[all:vars] +ansible_user=root +use_chassis_hardware_sn=true +rpm_file_name=tsg-cli-1.0.13.c6d5037-1.el7.x86_64.rpm + +[sled-mxn] +192.168.40.170 SN=CBT2201925000003 + +[sled-mcn0] +192.168.40.166 SN=CBT2201925000003 + +[sled-mcn1] +192.168.40.167 SN=CBT2201925000003 + +[sled-mcn2] +192.168.40.168 SN=CBT2201925000003 + +[sled-mcn3] +192.168.40.169 SN=CBT2201925000003 + +[Functional_Host:children] +sled-mcn0 +sled-mcn1 +sled-mcn2 +sled-mcn3 + + +[tsg-all:children] +sled-mxn +sled-mcn0 +sled-mcn1 +sled-mcn2 +sled-mcn3 + + + diff --git a/hosts.xxg.new b/hosts.xxg.25.sn002 similarity index 88% rename from hosts.xxg.new rename to hosts.xxg.25.sn002 index 550c4ba..a3c9490 100644 --- a/hosts.xxg.new +++ b/hosts.xxg.25.sn002 @@ -1,6 +1,6 @@ [all:vars] ansible_user=root -rpm_file_name=tsg-cli-1.0.11.d276da8-1.el7.x86_64.rpm +rpm_file_name=tsg-cli-1.0.13.c6d5037-1.el7.x86_64.rpm [sled-mxn] 192.168.40.25 SN=CBT2201925000002 diff --git a/roles/tsg-cli-mcn0/files/rsyslog.conf b/roles/tsg-cli-mcn0/files/rsyslog.conf index a84716a..9da82b0 100644 --- a/roles/tsg-cli-mcn0/files/rsyslog.conf +++ b/roles/tsg-cli-mcn0/files/rsyslog.conf @@ -89,5 +89,5 @@ local7.* /var/log/boot.log #$ActionQueueType LinkedList # run asynchronously #$ActionResumeRetryCount -1 # infinite retries if host is down # remote host is: name/ip:port, e.g. 192.168.0.1:514, port optional -.notice @@192.168.100.5:514 +*.warning @@192.168.100.5:514 # ### end of the forwarding rule ### diff --git a/roles/tsg-cli-mcn0/files/tsg-monitor.sh b/roles/tsg-cli-mcn0/files/tsg-monitor.sh index af6854a..c474424 100644 --- a/roles/tsg-cli-mcn0/files/tsg-monitor.sh +++ b/roles/tsg-cli-mcn0/files/tsg-monitor.sh @@ -77,7 +77,7 @@ sleep_for_time_ms(){ while [ 1 ]; do start_time=`get_current_time_in_ms` - echo tsg-monitor start at `date +"%Y/%m/%d, %H:%M:%S.%N"` >> /tmp/tsg-monitor.log + #echo tsg-monitor start at `date +"%Y/%m/%d, %H:%M:%S.%N"` >> /tmp/tsg-monitor.log start_background_cmd sleep 10 diff --git a/roles/tsg-cli-mcn0/tasks/main.yml b/roles/tsg-cli-mcn0/tasks/main.yml index 91be784..786395b 100644 --- a/roles/tsg-cli-mcn0/tasks/main.yml +++ b/roles/tsg-cli-mcn0/tasks/main.yml @@ -17,6 +17,14 @@ src: "{{ role_path }}/templates/tsg_sn.json.j2" dest: /opt/tsg/etc/tsg_sn.json tags: template + when: not use_chassis_hardware_sn | bool + +- name: "copy tsg_sn.json to destination server" + synchronize: + src: "{{ role_path }}/../tsg-common-files/tsg_sn.json" + dest: "/opt/tsg/etc/tsg_sn.json" + when: use_chassis_hardware_sn | bool + - name: "copy tsg-monitor.service to destination server" synchronize: @@ -35,13 +43,20 @@ dest: "/opt/tsg/tsg-monitor/" mode: 0755 -- name: "enable tsg-monitor service" - systemd: - name: tsg-monitor - enabled: yes - daemon_reload: yes - - name: "copy rsyslog.conf to destination server" synchronize: src: "{{ role_path }}/files/rsyslog.conf" - dest: "/etc/" \ No newline at end of file + dest: "/etc/" + +- name: "restart rsyslog service" + systemd: + name: rsyslog + state: restarted + +- name: "enable tsg-monitor service" + systemd: + name: tsg-monitor + daemon_reload: yes + enabled: yes + state: restarted + \ No newline at end of file diff --git a/roles/tsg-cli-mcn1/files/rsyslog.conf b/roles/tsg-cli-mcn1/files/rsyslog.conf index a84716a..9da82b0 100644 --- a/roles/tsg-cli-mcn1/files/rsyslog.conf +++ b/roles/tsg-cli-mcn1/files/rsyslog.conf @@ -89,5 +89,5 @@ local7.* /var/log/boot.log #$ActionQueueType LinkedList # run asynchronously #$ActionResumeRetryCount -1 # infinite retries if host is down # remote host is: name/ip:port, e.g. 192.168.0.1:514, port optional -.notice @@192.168.100.5:514 +*.warning @@192.168.100.5:514 # ### end of the forwarding rule ### diff --git a/roles/tsg-cli-mcn1/files/tsg-monitor.sh b/roles/tsg-cli-mcn1/files/tsg-monitor.sh index bad8e24..21fa970 100644 --- a/roles/tsg-cli-mcn1/files/tsg-monitor.sh +++ b/roles/tsg-cli-mcn1/files/tsg-monitor.sh @@ -65,7 +65,7 @@ sleep_for_time_ms(){ while [ 1 ]; do start_time=`get_current_time_in_ms` - echo tsg-monitor start at `date +"%Y/%m/%d, %H:%M:%S.%N"` >> /tmp/tsg-monitor.log + #echo tsg-monitor start at `date +"%Y/%m/%d, %H:%M:%S.%N"` >> /tmp/tsg-monitor.log start_background_cmd sleep 10 diff --git a/roles/tsg-cli-mcn1/tasks/main.yml b/roles/tsg-cli-mcn1/tasks/main.yml index 434209a..40581ce 100644 --- a/roles/tsg-cli-mcn1/tasks/main.yml +++ b/roles/tsg-cli-mcn1/tasks/main.yml @@ -17,6 +17,13 @@ src: "{{ role_path }}/templates/tsg_sn.json.j2" dest: /opt/tsg/etc/tsg_sn.json tags: template + when: not use_chassis_hardware_sn | bool + +- name: "copy tsg_sn.json to destination server" + synchronize: + src: "{{ role_path }}/../tsg-common-files/tsg_sn.json" + dest: "/opt/tsg/etc/tsg_sn.json" + when: use_chassis_hardware_sn | bool - name: "copy tsg-monitor.service to destination server" synchronize: @@ -34,14 +41,21 @@ src: "{{ role_path }}/files/tsg-monitor.sh" dest: "/opt/tsg/tsg-monitor/" mode: 0755 - + +- name: "copy rsyslog.conf to destination server" + synchronize: + src: "{{ role_path }}/files/rsyslog.conf" + dest: "/etc/" + +- name: "restart rsyslog service" + systemd: + name: rsyslog + state: restarted + - name: "enable tsg-monitor service" systemd: name: tsg-monitor enabled: yes daemon_reload: yes + state: restarted -- name: "copy rsyslog.conf to destination server" - synchronize: - src: "{{ role_path }}/files/rsyslog.conf" - dest: "/etc/" \ No newline at end of file diff --git a/roles/tsg-cli-mcn2/files/rsyslog.conf b/roles/tsg-cli-mcn2/files/rsyslog.conf index a84716a..9da82b0 100644 --- a/roles/tsg-cli-mcn2/files/rsyslog.conf +++ b/roles/tsg-cli-mcn2/files/rsyslog.conf @@ -89,5 +89,5 @@ local7.* /var/log/boot.log #$ActionQueueType LinkedList # run asynchronously #$ActionResumeRetryCount -1 # infinite retries if host is down # remote host is: name/ip:port, e.g. 192.168.0.1:514, port optional -.notice @@192.168.100.5:514 +*.warning @@192.168.100.5:514 # ### end of the forwarding rule ### diff --git a/roles/tsg-cli-mcn2/files/tsg-monitor.sh b/roles/tsg-cli-mcn2/files/tsg-monitor.sh index 74d7fa8..e702f0d 100644 --- a/roles/tsg-cli-mcn2/files/tsg-monitor.sh +++ b/roles/tsg-cli-mcn2/files/tsg-monitor.sh @@ -65,7 +65,7 @@ sleep_for_time_ms(){ while [ 1 ]; do start_time=`get_current_time_in_ms` - echo tsg-monitor start at `date +"%Y/%m/%d, %H:%M:%S.%N"` >> /tmp/tsg-monitor.log + #echo tsg-monitor start at `date +"%Y/%m/%d, %H:%M:%S.%N"` >> /tmp/tsg-monitor.log start_background_cmd sleep 10 diff --git a/roles/tsg-cli-mcn2/tasks/main.yml b/roles/tsg-cli-mcn2/tasks/main.yml index 434209a..b4691f9 100644 --- a/roles/tsg-cli-mcn2/tasks/main.yml +++ b/roles/tsg-cli-mcn2/tasks/main.yml @@ -17,6 +17,13 @@ src: "{{ role_path }}/templates/tsg_sn.json.j2" dest: /opt/tsg/etc/tsg_sn.json tags: template + when: not use_chassis_hardware_sn | bool + +- name: "copy tsg_sn.json to destination server" + synchronize: + src: "{{ role_path }}/../tsg-common-files/tsg_sn.json" + dest: "/opt/tsg/etc/tsg_sn.json" + when: use_chassis_hardware_sn | bool - name: "copy tsg-monitor.service to destination server" synchronize: @@ -34,14 +41,20 @@ src: "{{ role_path }}/files/tsg-monitor.sh" dest: "/opt/tsg/tsg-monitor/" mode: 0755 - -- name: "enable tsg-monitor service" - systemd: - name: tsg-monitor - enabled: yes - daemon_reload: yes - name: "copy rsyslog.conf to destination server" synchronize: src: "{{ role_path }}/files/rsyslog.conf" - dest: "/etc/" \ No newline at end of file + dest: "/etc/" + +- name: "restart rsyslog service" + systemd: + name: rsyslog + state: restarted + +- name: "enable tsg-monitor service" + systemd: + name: tsg-monitor + enabled: yes + daemon_reload: yes + state: restarted \ No newline at end of file diff --git a/roles/tsg-cli-mcn3/files/rsyslog.conf b/roles/tsg-cli-mcn3/files/rsyslog.conf index a84716a..9da82b0 100644 --- a/roles/tsg-cli-mcn3/files/rsyslog.conf +++ b/roles/tsg-cli-mcn3/files/rsyslog.conf @@ -89,5 +89,5 @@ local7.* /var/log/boot.log #$ActionQueueType LinkedList # run asynchronously #$ActionResumeRetryCount -1 # infinite retries if host is down # remote host is: name/ip:port, e.g. 192.168.0.1:514, port optional -.notice @@192.168.100.5:514 +*.warning @@192.168.100.5:514 # ### end of the forwarding rule ### diff --git a/roles/tsg-cli-mcn3/files/tsg-monitor.sh b/roles/tsg-cli-mcn3/files/tsg-monitor.sh index 49f913b..175be7b 100644 --- a/roles/tsg-cli-mcn3/files/tsg-monitor.sh +++ b/roles/tsg-cli-mcn3/files/tsg-monitor.sh @@ -65,7 +65,7 @@ sleep_for_time_ms(){ while [ 1 ]; do start_time=`get_current_time_in_ms` - echo tsg-monitor start at `date +"%Y/%m/%d, %H:%M:%S.%N"` >> /tmp/tsg-monitor.log + #echo tsg-monitor start at `date +"%Y/%m/%d, %H:%M:%S.%N"` >> /tmp/tsg-monitor.log start_background_cmd sleep 10 diff --git a/roles/tsg-cli-mcn3/tasks/main.yml b/roles/tsg-cli-mcn3/tasks/main.yml index 434209a..a87e349 100644 --- a/roles/tsg-cli-mcn3/tasks/main.yml +++ b/roles/tsg-cli-mcn3/tasks/main.yml @@ -17,6 +17,13 @@ src: "{{ role_path }}/templates/tsg_sn.json.j2" dest: /opt/tsg/etc/tsg_sn.json tags: template + when: not use_chassis_hardware_sn | bool + +- name: "copy tsg_sn.json to destination server" + synchronize: + src: "{{ role_path }}/../tsg-common-files/tsg_sn.json" + dest: "/opt/tsg/etc/tsg_sn.json" + when: use_chassis_hardware_sn | bool - name: "copy tsg-monitor.service to destination server" synchronize: @@ -34,14 +41,20 @@ src: "{{ role_path }}/files/tsg-monitor.sh" dest: "/opt/tsg/tsg-monitor/" mode: 0755 - -- name: "enable tsg-monitor service" - systemd: - name: tsg-monitor - enabled: yes - daemon_reload: yes - name: "copy rsyslog.conf to destination server" synchronize: src: "{{ role_path }}/files/rsyslog.conf" - dest: "/etc/" \ No newline at end of file + dest: "/etc/" + +- name: "restart rsyslog service" + systemd: + name: rsyslog + state: restarted + +- name: "enable tsg-monitor service" + systemd: + name: tsg-monitor + enabled: yes + daemon_reload: yes + state: restarted \ No newline at end of file diff --git a/roles/tsg-cli-mxn/files/cmm_api_tst b/roles/tsg-cli-mxn/files/cmm_api_tst new file mode 100644 index 0000000..a228f12 Binary files /dev/null and b/roles/tsg-cli-mxn/files/cmm_api_tst differ diff --git a/roles/tsg-cli-mxn/files/tsg-monitor.sh b/roles/tsg-cli-mxn/files/tsg-monitor.sh index 861df26..3943447 100644 --- a/roles/tsg-cli-mxn/files/tsg-monitor.sh +++ b/roles/tsg-cli-mxn/files/tsg-monitor.sh @@ -65,7 +65,7 @@ sleep_for_time_ms(){ while [ 1 ]; do start_time=`get_current_time_in_ms` - echo tsg-monitor start at `date +"%Y/%m/%d, %H:%M:%S.%N"` >> /tmp/tsg-monitor.log + #echo tsg-monitor start at `date +"%Y/%m/%d, %H:%M:%S.%N"` >> /tmp/tsg-monitor.log start_background_cmd sleep 10 diff --git a/roles/tsg-cli-mxn/files/tsg_read_sn.sh b/roles/tsg-cli-mxn/files/tsg_read_sn.sh new file mode 100644 index 0000000..24e71bd --- /dev/null +++ b/roles/tsg-cli-mxn/files/tsg_read_sn.sh @@ -0,0 +1,110 @@ +#!/bin/bash +# ==================================================== +# Main Script Test for Check ZHK's CSA-7400 Chassis ID +# Edit:Edgar.Tang +# Release date: 2019.9.16 +# ==================================================== +a=`date` +Tstart=$(date +%s) +Stime=`date +%Y%m%d-%H%M%S` +open_intf.inst +patch=`pwd` +Version="A2" +#SPVer=`cat release_note.txt | grep VERSION | head -n 1 | awk -F ":" '{print $2}'` +i=0 +chmod 777 * +rm -f *.log +rm -f *.LOG +rm -rf *.bin +rm -rf tmp* +rm -rf *dat +rm -rf *PASS +rm -rf *id +rm -rf *ipmi +clear +function maintest(){ +#echo "##########################################################################" +#echo "=========================Check chassis id information===============" +#echo "-------------------------Check chassis id information---------------" + +if [ ! -f "cmm_api_tst" ];then + echo "not found cmm_api_tst!" + exit 1 +fi + +./cmm_api_tst 9 1 1 127.0.0.1 | tee chid.id +if [ $? != 0 ]; then + echo "cmm_api_tst failed!" + exit 1 +fi + +CHID=`cat chid.id | sed -n '1p' | awk -F ":" '{print $2}' | sed 's/ //g'` +CHIDL=`echo $CHID | awk '{print length($0)}'` + +if [ $CHIDL != 20 ];then + echo "CHID length is not 20!" + exit 1 +fi + +echo "{\"sn\": \"$CHID\"}" > ./tsg_sn.json +} + +#echo "#######################################################################" +#echo "==========================Check Main Switch information================ " +#echo "--------------------------Check Main Switch information----------------" + +ipmitool raw 0x2e 0x32 0x00 0x5f 0x13 | tee main.ipmi +ipmitool raw 0x2e 0x32 0x00 0x5f 0x13 | tail -n 1 | awk '{print $5}' | sed 's/ //g' | grep 01 +if [ $? == 0 ]; then + echo "ipmitool: Check DUT Switch for Main!.......................................PASS" + maintest $CHID $PSN $1 +else + sdrnum=`ipmitool sdr | grep -a ok | wc -l` + if [ $sdrnum == 23 ]; then + echo "sdrnum: Check DUT Switch for Main!.......................................PASS" + maintest $CHID $PSN $1 + else + echo "====================================================================================" + echo "====================FFFFFF======A========IIIIIIIII===LL=============================" + echo "====================F==========A=A===========I=======LL=============================" + echo "====================F=========A===A==========I=======LL=============================" + echo "====================FFFFF====AAAAAAA=========I=======LL=============================" + echo "====================F=======A=======A========I=======LL=============================" + echo "====================F======A=========A=======I=======LL=============================" + echo "====================F=====A===========A==IIIIIIIII===LLLLLLLLL======================" + echo "====================================================================================" + echo "FAIL FAIL FAIL FAIL FAIL FAIL FAIL FAIL FAIL FAIL FAIL FAIL FAIL FAIL FAIL" + echo "Check DUT Switch for Main!......................................FAIL" + echo "====================================================================================== " + echo "Please changed CMM for Main and please reboot another CMM via Serial Port;then retest" + echo "====================================================================================== " + read + i=1 + exit 1 + fi +fi + + +#end=$(date +%s) +#endt=$((end-Tstart)) +#echo "Test time: $endt seconds" +# +#clear +#echo "========================================================================" +#echo "Chassis Program Ver : $SPVer" +#echo "------------------------------------------------------------------------" +#echo "Chassis ID : $CHID" +#echo "Chassis ID length : $CHIDL" +#echo "------------------------------------------------------------------------" +#echo "Test Time : $endt seconds" +#echo "========================================================================" +#echo "=================PPPPP=======A=======SSSSSSSSS==SSSSSSSS================" +#echo "=================P====P=====A=A======S==========S=======================" +#echo "=================P====P====A===A=====S==========S=======================" +#echo "=================PPPPP====A=====A====SSSSSSSSS==SSSSSSSS================" +#echo "=================P=======AAAAAAAAA===========S=========S================" +#echo "=================P======A=========A==========S=========S================" +#echo "=================P=====A===========A=SSSSSSSSS==SSSSSSSS================" +#echo "========================================================================" + +#echo "Chassis ID : $CHID" diff --git a/roles/tsg-cli-mxn/tasks/main.yml b/roles/tsg-cli-mxn/tasks/main.yml index 6c53a62..4ab79ab 100644 --- a/roles/tsg-cli-mxn/tasks/main.yml +++ b/roles/tsg-cli-mxn/tasks/main.yml @@ -1,4 +1,31 @@ --- +- name: "copy tsg_read_sn.sh to destination server" + copy: + src: "{{ role_path }}/files/tsg_read_sn.sh" + dest: "/tmp/tsg-cli-deploy/" + mode: 0755 + when: use_chassis_hardware_sn | bool + +- name: "copy cmm_api_tst to destination server" + copy: + src: "{{ role_path }}/files/cmm_api_tst" + dest: "/tmp/tsg-cli-deploy/" + mode: 0755 + when: use_chassis_hardware_sn | bool + +- name: "run tsg_read_sn.sh on destination server" + shell: ./tsg_read_sn.sh + args: + chdir: /tmp/tsg-cli-deploy/ + when: use_chassis_hardware_sn | bool + +- name: "scp tsg_sn.json from destination server to local" + fetch: + src: "/tmp/tsg-cli-deploy/tsg_sn.json" + dest: "{{ role_path }}/../tsg-common-files/tsg_sn.json" + flat: yes + when: use_chassis_hardware_sn | bool + - name: "copy tsg-cli rmp to destination server" synchronize: src: "{{ role_path }}/../tsg-common-files/{{ rpm_file_name }}" @@ -15,8 +42,15 @@ - name: Template the tsg_sn.json template: src: "{{ role_path }}/templates/tsg_sn.json.j2" - dest: /opt/tsg/etc/tsg_sn.json + dest: "/opt/tsg/etc/tsg_sn.json" tags: template + when: not use_chassis_hardware_sn | bool + +- name: "copy tsg_sn.json to destination server" + synchronize: + src: "{{ role_path }}/../tsg-common-files/tsg_sn.json" + dest: "/opt/tsg/etc/tsg_sn.json" + when: use_chassis_hardware_sn | bool - name: "copy tsg-monitor.service to destination server" synchronize: @@ -30,13 +64,19 @@ dest: "/opt/tsg/tsg-monitor/" mode: 0755 +- name: "copy rsyslog.conf to destination server" + synchronize: + src: "{{ role_path }}/files/rsyslog.conf" + dest: "/etc/" + +- name: "restart rsyslog service" + systemd: + name: rsyslog + state: restarted + - name: "enable tsg-monitor service" systemd: name: tsg-monitor enabled: yes daemon_reload: yes - -- name: "copy rsyslog.conf to destination server" - synchronize: - src: "{{ role_path }}/files/rsyslog.conf" - dest: "/etc/" \ No newline at end of file + state: restarted \ No newline at end of file diff --git a/roles/tsg-common-files/tsg-cli-1.0.12.c84ffd9-1.el7.x86_64.rpm b/roles/tsg-common-files/tsg-cli-1.0.13.c6d5037-1.el7.x86_64.rpm similarity index 93% rename from roles/tsg-common-files/tsg-cli-1.0.12.c84ffd9-1.el7.x86_64.rpm rename to roles/tsg-common-files/tsg-cli-1.0.13.c6d5037-1.el7.x86_64.rpm index 4006776..b9156d2 100644 Binary files a/roles/tsg-common-files/tsg-cli-1.0.12.c84ffd9-1.el7.x86_64.rpm and b/roles/tsg-common-files/tsg-cli-1.0.13.c6d5037-1.el7.x86_64.rpm differ diff --git a/roles/tsg-common-files/tsg_sn.json b/roles/tsg-common-files/tsg_sn.json new file mode 100644 index 0000000..a72f17e --- /dev/null +++ b/roles/tsg-common-files/tsg_sn.json @@ -0,0 +1 @@ +{"sn": "GN191205CH1234567890"} diff --git a/tsg-cli-playbook.yml b/tsg-cli-install.yml similarity index 100% rename from tsg-cli-playbook.yml rename to tsg-cli-install.yml diff --git a/tsg-cli-uninstall.yml b/tsg-cli-uninstall.yml new file mode 100644 index 0000000..2a7f12a --- /dev/null +++ b/tsg-cli-uninstall.yml @@ -0,0 +1,12 @@ +--- +- hosts: sled-mcn0 sled-mcn1 sled-mcn2 sled-mcn3 sled-mxn + tasks: + - name: "stop tsg-monitor service" + service: + name: tsg-monitor + state: stopped + + - name: "uninstall tsg-cli" + yum: + name: "tsg-cli" + state: absent \ No newline at end of file