Collect services statuses in logs

Change-Id: I5fbcec3a587cdb76d486e05951940bfc3fa61b76
This commit is contained in:
Sagi Shnaidman 2019-03-21 19:15:17 +02:00
parent a1f4a4d0db
commit 89668ff83b
1 changed files with 6 additions and 1 deletions

View File

@ -48,7 +48,7 @@
- name: Collect logs from all failed systemd services
shell: >
systemctl -t service --failed --no-legend | awk '{print $1}'
| xargs -r -n1 journalctl -u > /var/log/extra/services.txt 2>&1
| xargs -r -n1 journalctl -u > /var/log/extra/failed_services.txt 2>&1
- name: Collect network status info
shell: >
@ -128,6 +128,11 @@
- name: lvm debug
shell: "(vgs; pvs; lvs) &> /var/log/extra/lvm.txt"
- name: Collect services status
shell: |
systemctl list-units --full --all &> /var/log/extra/services.txt
systemctl status "*" &>> /var/log/extra/services.txt
- name: check if ODL is enabled via docker
shell: docker ps | grep opendaylight_api
register: odl_container_enabled