notify für "update finished, "shutdown restart" is needed to activate the change

Begonnen von heinzfo, 29 Oktober 2016, 14:04:39

Vorheriges Thema - Nächstes Thema

heinzfo

Hallo

Ich möchte eine notify einrichten für die Message "update finished, "shutdown restart" is needed to activate the changes.

Könnte das so funktionieren, geht es überhaupt?
global:.*finished.* {fhem "set HeinzMobil send fhem Update done, restart needed!"}

Beste Grüße
Heinz

heinzfo

Ich antworte mal selbst.

Nach der Meldung update finished kommt noch Global global UPDATE

Damit geht es dann:
global:.*Global.global.UPDATE.* {fhem "set HeinzMobil send fhem Update done, restart needed!"}

Beste Grüße
Heinz

Markus Bloch

Das Event selber heißt lediglich "global:UPDATE" siehe auch commandref: http://fhem.de/commandref.html#update (Zitat: "Upon completion it triggers the global:UPDATE event.")

Ich hab bei mir bspw. den Neustart automatisiert mit:

define Restart_on_update_complete notify global:UPDATE sleep 2;;shutdown restart

In deinem Fall dann:

define <NAME> notify global:UPDATE set HeinzMobil send fhem Update done, restart needed!

Der Wechsel auf eine Perl-Expression ist nicht notwendig.

Gruß
Markus

Gruß
Markus
Developer für Module: YAMAHA_AVR, YAMAHA_BD, FB_CALLMONITOR, FB_CALLLIST, PRESENCE, Pushsafer, LGTV_IP12, version

aktives Mitglied des FHEM e.V. (Technik)

heinzfo

Hallo Markus

Danke für den Tipp!

Es geht mit global:UPDATE
define UpdateDoneWA notify global:UPDATE set HeinzMobil send fhem Update done, restart ongoing!

Und das noch:
define RestartUpdateFinished notify global:UPDATE sleep 2;; save;; sleep 2;; shutdown restart

Schönes WE