hi,
einfache scripts bekomme ich ja hin, aber auskennen tue ich mich nicht
Meine 2.te platte wird unwillkührlich aufgeweckt. link Jetzt suche ich was zur Fehlereingrenzung was den status alle 5 Minuten abfragt und in ein logdatei schreibt.
Code
#! /bin/bash
#
#
LOG=/log/hdparm-sdb.log
HD="hdparm -C /dev/sdb"
SLEEP="sleep 300"
rm $LOG
echo "script gestartet, bitte sdb aktivieren (auf daten zugreifen)"
echo "log startet sdb wird ggf. gleich aufgeweckt" >> $LOG
date >> $LOG
$HD >> $LOG
$SLEEP
date >> $LOG
$HD >> $LOG
$SLEEP
date >> $LOG
$HD >> $LOG
$SLEEP
date >> $LOG
$HD >> $LOG
$SLEEP
date >> $LOG
$HD >> $LOG
$SLEEP
date >> $LOG
$HD >> $LOG
$SLEEP
date >> $LOG
$HD >> $LOG
$SLEEP
date >> $LOG
$HD >> $LOG
$SLEEP
date >> $LOG
$HD >> $LOG
$SLEEP
date >> $LOG
$HD >> $LOG
$SLEEP
date >> $LOG
$HD >> $LOG
$SLEEP
date >> $LOG
$HD >> $LOG
$SLEEP
date >> $LOG
$HD >> $LOG
$SLEEP
date >> $LOG
$HD >> $LOG
$SLEEP
date >> $LOG
$HD >> $LOG
$SLEEP
Alles anzeigen
das könnte ich zwar immer weiter führen aber da gibt es doch sicher was besseres was immer wieder von vorne beginnt?
Gruss Lexi