script: smart-status.sh entfernt (#257)
Co-authored-by: Michael Grote <michael.grote@posteo.de> Reviewed-on: mg/ansible#257 Co-authored-by: mg <michael.grote@posteo.de> Co-committed-by: mg <michael.grote@posteo.de>
This commit is contained in:
parent
ddae32ea0a
commit
2a5d9a8dea
3 changed files with 0 additions and 33 deletions
|
@ -3,24 +3,6 @@
|
||||||
### Beschreibung
|
### Beschreibung
|
||||||
Installiert und konfiguriert smartmontools + Mail-Benachrichtigungen.(Mail muss extra konfiguriert werden.)
|
Installiert und konfiguriert smartmontools + Mail-Benachrichtigungen.(Mail muss extra konfiguriert werden.)
|
||||||
|
|
||||||
Stellt `smart_status.sh` bereit.
|
|
||||||
Ausgabe:
|
|
||||||
```shell
|
|
||||||
mg@pve2 ~
|
|
||||||
> sudo smart_status.sh
|
|
||||||
Device Model: SAMSUNG MZ7LH960HAJR-00005
|
|
||||||
SMART test result: PASSED
|
|
||||||
Device Model: SAMSUNG MZ7LH960HAJR-00005
|
|
||||||
SMART test result: PASSED
|
|
||||||
Device Model: WDC WD80EZAZ-11TDBA0
|
|
||||||
SMART test result: PASSED
|
|
||||||
Device Model: WDC WD80EZAZ-11TDBA0
|
|
||||||
SMART test result: PASSED
|
|
||||||
Device Model: WDC WD80EZAZ-11TDBA0
|
|
||||||
SMART test result: PASSED
|
|
||||||
Device Model: MTFDDAK256MBF-1AN15ABHA
|
|
||||||
SMART test result: PASSED
|
|
||||||
```
|
|
||||||
|
|
||||||
### getestet auf
|
### getestet auf
|
||||||
- [x] ProxMox 6*
|
- [x] ProxMox 6*
|
||||||
|
|
|
@ -25,12 +25,3 @@
|
||||||
owner: "{{ smart_user }}"
|
owner: "{{ smart_user }}"
|
||||||
group: "{{ smart_user_group }}"
|
group: "{{ smart_user_group }}"
|
||||||
notify: restart smartmontools
|
notify: restart smartmontools
|
||||||
|
|
||||||
- name: copy smart_status.sh
|
|
||||||
become: yes
|
|
||||||
ansible.builtin.template:
|
|
||||||
src: "smart_status.sh"
|
|
||||||
dest: "/usr/local/bin/smart_status.sh"
|
|
||||||
owner: "{{ smart_user }}"
|
|
||||||
group: "{{ smart_user_group }}"
|
|
||||||
mode: 0744
|
|
||||||
|
|
|
@ -1,6 +0,0 @@
|
||||||
#!/bin/bash
|
|
||||||
{{ file_header | default () }}
|
|
||||||
for i in {a..z}; do
|
|
||||||
smartctl /dev/sd$i -a | grep "Device Model: "
|
|
||||||
smartctl /dev/sd$i -a | grep "SMART overall-health self-assessment test result: " | sed -r 's/SMART overall-health self-assessment test result: /SMART test result: /g'| sed -r "s/(PASSED)/`printf "\033[92m"`\1`printf "\033[0m"`/g" | sed -r "s/(FAILED)/`printf "\033[31m"`\1`printf "\033[0m"`/g"
|
|
||||||
done
|
|
Loading…
Reference in a new issue