Guten Tag,
ich versuche ein funktionierendes Backup (getestet auf einem NUC) auf einer anderen Hardware (RPI 4B) zum laufen zu bringen.
Dafür wurden auf dem RPI 4B folgende Einstellungen durchgeführt:
1.
sudo apt-get -y install perl-base libdevice-serialport-perl libwww-perl libio-socket-ssl-perl libcgi-pm-perl libjson-perl sqlite3 libdbd-sqlite3-perl libtext-diff-perl libtimedate-perl libmail-imapclient-perl libgd-graph-perl libtext-csv-perl libxml-simple-perl liblist-moreutils-perl fonts-liberation libimage-librsvg-perl libgd-text-perl libsocket6-perl libio-socket-inet6-perl libmime-base64-perl libimage-info-perl libusb-1.0-0-dev libnet-server-perl
sudo apt-get -y install libdate-manip-perl libhtml-treebuilder-xpath-perl libmojolicious-perl libxml-bare-perl libauthen-oath-perl libconvert-base32-perl libmodule-pluggable-perl libnet-bonjour-perl libcrypt-urandom-perl
sudo wget http://fhem.de/fhem-6.0.deb
sudo dpkg -i fhem-6.0.deb
update
shutdown restart
Das frische fhem läuft jetzt.
2. sudo systemctl stop fhem
Backup mit WinSCP übertragen nach /home/pi
sudo tar -xvzf /home/pi/FHEM-2021xxxxx_xxxxxx.tar.gz -C /opt/fhem/
Rechte angepasst
pi@raspberrypi:~ $ ls -la /opt/fhem/
total 820
drwxr-xr-x 12 fhem dialout 4096 Jul 7 09:43 .
drwxr-xr-x 4 root root 4096 Jul 7 09:36 ..
-rw-rw-rw- 1 fhem dialout 363246 May 29 12:15 CHANGED
-rw-rw-rw- 1 fhem dialout 41645 May 29 12:15 configDB.pm
drwxrwxrwx 46 fhem dialout 4096 Jun 4 2018 contrib
drwxrwxrwx 3 fhem dialout 4096 Jun 4 2018 demolog
drwxrwxrwx 4 fhem dialout 4096 Jun 4 2018 docs
drwxrwxrwx 6 fhem dialout 36864 May 29 12:15 FHEM
-rw-rw-rw- 1 fhem dialout 62926 Jun 7 14:17 fhem.cfg
-rw-rw-rw- 1 fhem dialout 2988 Jun 24 2018 fhem.cfg.debug
-rw-rw-rw- 1 fhem dialout 25544 Jul 21 2019 fhem.cfg.demo
-rwxrwxrwx 1 fhem dialout 168179 May 29 12:15 fhem.pl
-rw-r--r-- 1 fhem dialout 18092 Dec 13 2020 GPL_V2.txt
-rw-rw-r-- 1 fhem dialout 2833 May 26 2019 index.html
drwxr-xr-x 3 fhem dialout 4096 Sep 19 2020 lib
drwxrwxrwx 2 fhem dialout 4096 Jul 9 14:23 log
-rw-rw-rw- 1 fhem dialout 43322 May 29 12:15 MAINTAINER.txt
-rw-rw-rw- 1 fhem dialout 935 Jun 4 2018 README_DEMO.txt
drwxrwxrwx 4 fhem dialout 4096 Jun 4 2018 restoreDir
drwxrwxrwx 2 fhem dialout 4096 Jun 4 2018 unused
drwxrwxr-x 2 fhem dialout 4096 May 23 2019 uploads
drwxrwxrwx 12 fhem dialout 4096 Dec 31 2019 www
Fehlermeldungen
pi@raspberrypi:~ $ tail -n 20 /opt/fhem/log/fhem-$(date '+%Y-%m').log
2021.07.09 15:16:13 3: HUESensor65574: I/O device is Tradfri
2021.07.09 15:16:13 3: HUESensor65576: I/O device is Tradfri
2021.07.09 15:16:13 3: HUEDevice65577: I/O device is Tradfri
2021.07.09 15:16:13 3: HUEGroup131103: I/O device is Tradfri
2021.07.09 15:16:13 3: HUEGroup131105: I/O device is Tradfri
2021.07.09 15:16:14 3: HUEDevice65579: I/O device is Tradfri
2021.07.09 15:16:14 3: HUEGroup131106: I/O device is Tradfri
2021.07.09 15:16:14 1: MQTTServer: Can't open server port at 1883: Cannot assign requested address. Exiting.
2021.07.09 15:16:15 1: Including fhem.cfg
2021.07.09 15:16:15 3: telnetPort: port 7072 opened
2021.07.09 15:16:15 3: WEB: port 8083 opened
2021.07.09 15:16:15 3: WEBphone: port 8084 opened
2021.07.09 15:16:15 3: WEBtablet: port 8085 opened
2021.07.09 15:16:15 2: eventTypes: loaded 1707 lines from ./log/eventTypes.txt
2021.07.09 15:16:15 3: Opening nanoCUL device /dev/serial/by-id/usb-FTDI_FT232R_USB_UART_A9CVN1L5-if00-port0
2021.07.09 15:16:15 1: nanoCUL: Can't open /dev/serial/by-id/usb-FTDI_FT232R_USB_UART_A9CVN1L5-if00-port0: No such file or directory
2021.07.09 15:16:15 2: Switched nanoCUL rfmode to MAX
2021.07.09 15:16:15 3: Opening myJeeLink device /dev/serial/by-id/usb-Arduino__www.arduino.cc__0043_55432333038351803181-if00
2021.07.09 15:16:15 1: myJeeLink: Can't open /dev/serial/by-id/usb-Arduino__www.arduino.cc__0043_55432333038351803181-if00: No such file or directory
2021.07.09 15:16:15 1: PERL WARNING: Possible attempt to separate words with commas at ./FHEM/00_MYSENSORS.pm line 80, <$fh> line 111.
An den USB-Schnittstellen ist nicht angeschlossen, daher die Fehler.
Hat jemand noch Ideen was hier geprüft werden kann?
MfG
https://wiki.fhem.de/wiki/FHEM_startet_nicht_-_Tipps_zur_Fehlersuche
Ansonsten scheint der Port 1883 bereits belegt zu sein, vermutlich läuft da schon ein mosquitto?
Das letzte Warning deutet für mich darauf hin, dass FHEM nicht 100% aktuell ist, aber an sich scheint der Server zu laufen. Würde mal auf initialUsbCheck tippen, der da erst mal für "Stillstand" sorgt?
Würde den FHEM-Service stoppen, mit der demo-cfg starten und dann mal ein update machen und nebenher den USB-Check disablen. Wenn das update durch ist, wieder via systemctl starten.
- welches OS ist auf dem PI,
- was ist da sonst noch drauf
- warum nicht "the easy way" --> debian.fhem.de
- vor dem Restore ein FHEM Update gemacht?
Hallo,
bei meinem Umzug hat FHEM auch nicht gestartet wenn auf dem Betriebssystem ein Mosquitto Server aktiv war. Wenn Port 1883 schon belegt ist läuft vermutlich der Mosquitto auf dem Rechner.
Was sagt:
systemctl status mosquitto
und
ps aux | grep mosquitto
Wenn hier ein mosquitto läuf dann mal diesen stoppen und danach fhem starten:
systemctl stop mosquitto
systemctl start fhem
Gruß Jochen
Danke für die Informationen,
- welches OS ist auf dem PI
Raspberry Pi OS Lite (32bit) 2021-05-07
- was ist da sonst noch drauf
sudo wget http://fhem.de/fhem-6.0.deb
- vor dem Restore ein FHEM Update gemach
update
shutdown restart
Ansonsten scheint der Port 1883 bereits belegt zu sein, vermutlich läuft da schon ein mosquitto?
systemctl status mosquitto
pi@raspberrypi:~ $ systemctl status mosquitto
Unit mosquitto.service could not be found.
ps aux | grep mosquitto
pi@raspberrypi:~ $ ps aux | grep mosquitto
pi 1117 0.0 0.0 7348 476 pts/0 S+ 19:39 0:00 grep --color=auto mosquitto
systemctl stop mosquitto
pi@raspberrypi:~ $ systemctl stop mosquitto
==== AUTHENTICATING FOR org.freedesktop.systemd1.manage-units ===
Authentication is required to stop 'mosquitto.service'.
Authenticating as: ,,, (pi)
Password:
==== AUTHENTICATION COMPLETE ===
Failed to stop mosquitto.service: Unit mosquitto.service not loaded.
demo-cfg starten
Die Demo funktioniert.
Habe fhem gestoppt und in der fhem "attr initialUsbCheck disable 1"
Der Prozess fhem läuft aber wechselt zwischen 9 - 100%
%CPU
1323 fhem 20 0 17936 11320 4272 R 9.0 0.6 0:00.27 perl
Die Webseite ist nicht erreichbar.
netstat -lntp
Wenn CPU = 100% für FHEM, dürfte fhem nicht erreichbar sein. Was sagt den das fhem-logfile?
Hallo,
netstat -lntp
pi@raspberrypi:/opt/fhem/log $ netstat -lntp
(Not all processes could be identified, non-owned process info
will not be shown, you would have to be root to see it all.)
Active Internet connections (only servers)
Proto Recv-Q Send-Q Local Address Foreign Address State PID/Program name
tcp 0 0 0.0.0.0:139 0.0.0.0:* LISTEN -
tcp 0 0 0.0.0.0:8083 0.0.0.0:* LISTEN -
tcp 0 0 0.0.0.0:8084 0.0.0.0:* LISTEN -
tcp 0 0 0.0.0.0:8085 0.0.0.0:* LISTEN -
tcp 0 0 0.0.0.0:22 0.0.0.0:* LISTEN -
tcp 0 0 0.0.0.0:445 0.0.0.0:* LISTEN -
tcp 0 0 0.0.0.0:7072 0.0.0.0:* LISTEN -
tcp6 0 0 :::139 :::* LISTEN -
tcp6 0 0 :::22 :::* LISTEN -
tcp6 0 0 :::445 :::* LISTEN -
Der Prozess fhem läuft aber wechselt zwischen 9 - 100% er ist nicht ständig bei 100% sondern schwankt.
Auszug aus dem Logfile, SONOS macht anscheinend die Schwierigkeiten..
2021.06.07 19:31:36 3: SONOS1: Transport-Subscription for ZonePlayer "RINCON_347E5C34D71C01400_MR" has expired and is now renewed.
2021.06.07 19:31:36 3: SONOS1: Rendering-Subscription for ZonePlayer "RINCON_347E5C34D71C01400_MR" has expired and is now renewed.
2021.06.07 19:31:36 3: SONOS1: GroupRendering-Subscription for ZonePlayer "RINCON_347E5C34D71C01400_MR" has expired and is now renewed.
2021.06.07 19:31:36 3: SONOS1: ContentDirectory-Subscription for ZonePlayer "RINCON_347E5C34D71C01400_MR" has expired and is now renewed.
2021.06.07 19:31:36 3: SONOS1: Alarm-Subscription for ZonePlayer "RINCON_347E5C34D71C01400_MR" has expired and is now renewed.
2021.06.07 19:31:36 3: SONOS1: ZoneGroupTopology-Subscription for ZonePlayer "RINCON_347E5C34D71C01400_MR" has expired and is now renewed.
2021.06.07 19:31:36 3: SONOS1: DeviceProperties-Subscription for ZonePlayer "RINCON_347E5C34D71C01400_MR" has expired and is now renewed.
2021.06.07 19:31:36 3: SONOS1: MusicServices-Subscription for ZonePlayer "RINCON_347E5C34D71C01400_MR" has expired and is now renewed.
Loading device description failed with error: 500 Can't connect to 0.0.0.0:1901 (Location: http://0.0.0.0:1901/index.html) at ./FHEM/00_SONOS.pm line 2478 thread 1.
Loading device description failed with error: 500 Can't connect to 0.0.0.0:1901 (Location: http://0.0.0.0:1901/index.html) at ./FHEM/00_SONOS.pm line 2478 thread 1.
Loading device description failed with error: 500 Can't connect to 0.0.0.0:1901 (Location: http://0.0.0.0:1901/index.html) at ./FHEM/00_SONOS.pm line 2478 thread 1.
Loading device description failed with error: 500 Can't connect to 0.0.0.0:1901 (Location: http://0.0.0.0:1901/index.html) at ./FHEM/00_SONOS.pm line 2478 thread 1.
Loading device description failed with error: 500 Can't connect to 0.0.0.0:1901 (Location: http://0.0.0.0:1901/index.html) at ./FHEM/00_SONOS.pm line 2478 thread 1.
Loading device description failed with error: 500 Can't connect to 0.0.0.0:1901 (Location: http://0.0.0.0:1901/index.html) at ./FHEM/00_SONOS.pm line 2478 thread 1.
Loading device description failed with error: 500 Can't connect to 0.0.0.0:1901 (Location: http://0.0.0.0:1901/index.html) at ./FHEM/00_SONOS.pm line 2478 thread 1.
Loading device description failed with error: 500 Can't connect to 0.0.0.0:1901 (Location: http://0.0.0.0:1901/index.html) at ./FHEM/00_SONOS.pm line 2478 thread 1.
Loading device description failed with error: 500 Can't connect to 0.0.0.0:1901 (Location: http://0.0.0.0:1901/index.html) at ./FHEM/00_SONOS.pm line 2478 thread 1.
Loading device description failed with error: 500 Can't connect to 0.0.0.0:1901 (Location: http://0.0.0.0:1901/index.html) at ./FHEM/00_SONOS.pm line 2478 thread 1.
Loading device description failed with error: 500 Can't connect to 0.0.0.0:1901 (Location: http://0.0.0.0:1901/index.html) at ./FHEM/00_SONOS.pm line 2478 thread 1.
Loading device description failed with error: 500 Can't connect to 0.0.0.0:1901 (Location: http://0.0.0.0:1901/index.html) at ./FHEM/00_SONOS.pm line 2478 thread 1.
Loading device description failed with error: 500 Can't connect to 0.0.0.0:1901 (Location: http://0.0.0.0:1901/index.html) at ./FHEM/00_SONOS.pm line 2478 thread 1.
Loading device description failed with error: 500 Can't connect to 0.0.0.0:1901 (Location: http://0.0.0.0:1901/index.html) at ./FHEM/00_SONOS.pm line 2478 thread 1.
Loading device description failed with error: 500 Can't connect to 0.0.0.0:1901 (Location: http://0.0.0.0:1901/index.html) at ./FHEM/00_SONOS.pm line 2478 thread 1.
Loading device description failed with error: 500 Can't connect to 0.0.0.0:1901 (Location: http://0.0.0.0:1901/index.html) at ./FHEM/00_SONOS.pm line 2478 thread 1.
Loading device description failed with error: 500 Can't connect to 0.0.0.0:1901 (Location: http://0.0.0.0:1901/index.html) at ./FHEM/00_SONOS.pm line 2478 thread 1.