Grüezi,
Ich melde mich hier, obwohl es sich vermutlich um eine Rechte-Frage (also Anfängerfrage) handelt...
RasperryMatic und Fhem laufen auf zwei verschiedenen Raspis.
Alles funktioniert, nur wird eine Statusänderung erst nach einem (manuellen) update angezeigt.
Der Grund dürfte darin liegen, dass ich den den rpcserver nicht zum Laufen bringe .
set r_ccu off ergibt:
HMCCU: r_ccu Stop of RPC server failed
bzw. im Event Monitor:
2019-04-06 09:01:58 HMCCU r_ccu busy
2019-04-06 09:01:58 HMCCURPCPROC d_rpc188123BidCos_RF OK
2019-04-06 09:01:58 HMCCURPCPROC d_rpc188123BidCos_RF RPC server CB2001188133188123 stopped
2019-04-06 09:01:58 HMCCU r_ccu Error
set r_ccu on im Event Monitor:
2019-04-06 09:03:37 HMCCURPCPROC d_rpc188123BidCos_RF rpcstate: starting
2019-04-06 09:03:37 HMCCU r_ccu busy
2019-04-06 09:03:38 HMCCURPCPROC d_rpc188123BidCos_RF RPC server starting
2019-04-06 09:03:38 HMCCU r_ccu OK
2019-04-06 09:03:47 HMCCURPCPROC d_rpc188123BidCos_RF rpcstate: inactive
2019-04-06 09:03:47 HMCCU r_ccu rpcstate: inactive
2019-04-06 09:03:47 HMCCU r_ccu RPC server inactive
2019-04-06 09:03:47 HMCCURPCPROC d_rpc188123BidCos_RF OK
2019-04-06 09:03:47 HMCCURPCPROC d_rpc188123BidCos_RF RPC server CB2001188133188123 stopped
list r_ccu:
Internals:
CCUNum 1
Clients :HMCCUDEV:HMCCUCHN:HMCCURPC:HMCCURPCPROC:
DEF x.x.188.123
FUUID 5c883a7c-f33f-2a3b-9286-e12d314ebd37a665
NAME r_ccu
NOTIFYDEV global,TYPE=(HMCCU|HMCCUDEV|HMCCUCHN)
NR 152
NTFY_ORDER 50-r_ccu
RPCState inactive
STATE inactive/OK
TYPE HMCCU
ccuaddr BidCoS-RF
ccuchannels 105
ccudevices 25
ccuif BidCos-RF
ccuinterfaces BidCos-RF,VirtualDevices
ccuip x.x.188.123
ccuname HM-RCV-50 BidCoS-RF
ccustate active
ccutype CCU2/3
host x.x.188.123
prot http
version 4.3.014
READINGS:
2019-04-06 08:24:00 count_channels 105
2019-04-06 08:24:00 count_devices 25
2019-04-06 08:24:00 count_groups 0
2019-04-06 08:24:00 count_interfaces 2
2019-04-06 08:24:00 count_programs 1
2019-04-06 09:03:47 rpcstate inactive
2019-04-06 09:10:07 state OK
hmccu:
defInterface BidCos-RF
defPort 2001
evtime 0
evtimeout 0
rpccount 0
rpcports 2001
updatetime 0
adr:
DAEGWippexy:
......
Attributes:
ccudef-readingfilter ^(.+\.)?LOW_?BAT$:battery;^(.+\.)?UNREACH$:activity
ccudef-substitute AES_KEY!(0|false):off,(1|true):on;LOWBAT,LOW_BAT!(0|false):ok,(1|true):low;UNREACH!(0|false):alive,(1|true):dead;MOTION!(0|false):noMotion,(1|true):motion;DIRECTION!0:stop,1:up,2:down,3:undefined;WORKING!0:false,1:true;INHIBIT!(0|false):unlocked,(1|true):locked
ccuflags procrpc,trace
cmdIcon on:general_an off:general_aus
event-on-change-reading .*
eventMap /rpcserver on:on/rpcserver off:off/
room HomeMatic
rpcinterfaces BidCos-RF
rpcport 2001
rpcqueue /tmp
rpcserver on
stateFormat rpcstate/state
stripnumber 1
verbose 5
Dir Rechte von /tmp sind -rwrwxrwxrwt; trotzdem finde ich keine FHEM Dateien im Verzeichnis /tmp (vorhanden sind 5 scheinbar leere Verzeichnisse '.*-unix' und eines 'systemd-private*'. Ich habe sogar spezifisch das Attribut rpcqueue /tmp gesetzt.
Hinweis: die Verbindung von RaspberryMatic ist nicht wireless (d.h. an ethernet; trotzdem rpcport 2001?).
get r_ccu update:
24 devices successfully updated. Update for 0 client services failed.
Vielen Dank wenn mir jemand auf die Sprünge hilft.
Marcel
Du benutzt richtigerweise den externen RPC Server. Der schreibt nichts nach /tmp.
Interessant wären die Logfile Meldungen beim Start des RPC Servers.
Die Firewall Einstellungen auf der CCU sind korrekt und die Authentifizierung ist aus?
Hi zap!
Danke für die Hilfe.
Der erste Fehler wäre eliminiert - Authentifizierung war aktiv.
Die jetzigen Sicherheitseinstellungen:
Firewall: Port offen
Homematic XML-RPC API: Vollzugriff
Remote Homematic-Script API: Vollzugriff
Mediola-Zugriff: Kein Zugriff
Authentifizierung nicht aktiv
Logfile Meldungen nach shutdown restart:
2019.04.06 22:48:54 1: HMCCU: [r_ccu] Initialized version 4.3.014
2019.04.06 22:48:54 1: HMCCU: [r_ccu] HMCCU: Initializing device
2019.04.06 22:48:54 1: HMCCU: [r_ccu] HMCCU: Read 25 devices with 105 channels from CCU x.y.188.123
2019.04.06 22:48:54 1: HMCCU: [r_ccu] HMCCU: Read 2 interfaces from CCU x.y.188.123
2019.04.06 22:48:54 1: HMCCU: [r_ccu] HMCCU: Read 1 programs from CCU x.y.188.123
2019.04.06 22:48:54 1: HMCCU: [r_ccu] HMCCU: Read 0 virtual groups from CCU x.y.188.123
2019.04.06 22:48:54 1: HMCCURPCPROC: [d_rpc188123BidCos_RF] Initialized version 1.7.001 for interface BidCos-RF with I/O device r_ccu
2019.04.06 22:48:54 0: HMCCU: Start of RPC server after FHEM initialization in 12 seconds
2019.04.06 22:48:54 0: Featurelevel: 5.9
2019.04.06 22:48:54 0: Server started with 111 defined entities (fhem.pl:19085/2019-04-01 perl:5.024001 os:linux user:fhem pid:23052)
2019.04.06 22:48:54 2: HMCCU: GetAttrSubstitute: subst = AES_KEY!(0|false):off,(1|true):on;LOWBAT,LOW_BAT!(0|false):ok,(1|true):low;UNREACH!(0|false):alive,(1|true):dead;MOTION!(0|false):noMotion,(1|true):motion;DIRECTION!0:stop,1:up,2:down,3:undefined;WORKING!0:false,1:true;INHIBIT!(0|false):unlocked,(1|true):locked
2019.04.06 22:49:06 2: HMCCU: [r_ccu] Get RPC device for interface BidCos-RF
2019.04.06 22:49:06 2: HMCCURPCPROC: [d_rpc188123BidCos_RF] RPC server process started for interface BidCos-RF with PID=23054
2019.04.06 22:49:06 2: CCURPC: [d_rpc188123BidCos_RF] Initializing RPC server CB2001188133188123 for interface BidCos-RF
2019.04.06 22:49:06 1: HMCCURPCPROC: [d_rpc188123BidCos_RF] RPC server starting
2019.04.06 22:49:06 2: HMCCURPCPROC: [d_rpc188123BidCos_RF] Callback server CB2001188133188123 created. Listening on port 7411
2019.04.06 22:49:06 2: CCURPC: [d_rpc188123BidCos_RF] CB2001188133188123 accepting connections. PID=23054
2019.04.06 22:49:06 2: HMCCURPCPROC: [d_rpc188123BidCos_RF] RPC server CB2001188133188123 enters server loop
2019.04.06 22:49:06 4: HMCCU: [r_ccu] Build URL = http://FhemSystem:09u34hTR$nq34p)oq34t#rHjna@x.y.188.123:2001
2019.04.06 22:49:06 2: HMCCURPCPROC: [d_rpc188123BidCos_RF] Registering callback http://x.y.188.133:7411/fh2001 of type A with ID CB2001188133188123 at http://FhemSystem:09u34hTR$nq34p)oq34t#rHjna@x.y.188.123:2001
2019.04.06 22:49:06 4: HMCCU: [r_ccu] Build URL = http://FhemSystem:09u34hTR$nq34p)oq34t#rHjna@x.y.188.123:2001
2019.04.06 22:49:06 2: HMCCURPCPROC: [d_rpc188123BidCos_RF] RPC request error RPC::XML::Client::simple_request: RPC::XML::Client::send_request: HTTP server error: Can't connect to [FhemSystem:09u34hTR$nq34p)oq34t]:80
2019.04.06 22:49:06 1: HMCCURPCPROC: [d_rpc188123BidCos_RF] Failed to register callback for ID CB2001188133188123
2019.04.06 22:49:06 4: HMCCU: [r_ccu] Set rpcstate to error
2019.04.06 22:49:06 1: HMCCU: [r_ccu] All RPC servers error
Logfile Meldungen bei set r_ccu rpcserver on scheint mir sinngemäss identisch:
2019.04.06 23:01:01 2: HMCCURPCPROC: [d_rpc188123BidCos_RF] RPC request error RPC::XML::Client::simple_request: RPC::XML::Client::send_request: HTTP server error: Can't connect to [FhemSystem:09u34hTR$nq34p)oq34t]:80
2019.04.06 23:01:01 1: HMCCURPCPROC: [d_rpc188123BidCos_RF] Failed to register callback for ID CB2001188133188123
2019.04.06 23:01:01 4: HMCCU: [r_ccu] Set rpcstate to error
Beim Suchen nach welchen Dienste / Ports beim Fhem Raspi geöffnet sein müssen bin ich auf rpcserverport gestossen.
Den habe ich versuchshalber mit d_rpc188123BidCos_RF rpcServerPort auf 7411 gesetzt.
Da iptables noch jungfräulich ist, sollte nach meinem Wissen der Zugriff eigentlich möglich sein ...
Was nun?
Gruss Marcel
Rufe mal set authenticate ohne Parameter auf. Du musst auch die Authentifizierung auf FHeM Seite löschen.
Und lösche das rpcServerPort Attribut.
Danke zap,
Das Löschen der Authentifizierung auf FHeM Seite mit
set <HMCCU-name> authentication
hat das Problem behoben.
Wie vorgeschlagen habe ich rpcServerPort Attribut gelöscht (das war auch eher eine Verzweiflungstat!)
Danke nochmals-
Marcel