Klappt nicht
2017-12-26 20:05:43 INFO (MainThread) [homeassistant.setup] Setting up homematic
2017-12-26 20:05:43 DEBUG (Thread-4) [pyhomematic.connection] HMConnection: Creating server object
2017-12-26 20:05:43 DEBUG (Thread-4) [pyhomematic._hm] ServerThread.__init__
2017-12-26 20:05:43 DEBUG (Thread-4) [pyhomematic._hm] __init__: Creating proxies
2017-12-26 20:05:43 INFO (Thread-4) [pyhomematic._hm] Creating proxy wireless. Connecting to http://192.168.0.70:2001
2017-12-26 20:05:43 DEBUG (Thread-4) [pyhomematic._hm] LockingServerProxy.__init__: Getting local ip
2017-12-26 20:05:43 DEBUG (Thread-4) [pyhomematic._hm] LockingServerProxy.__init__: Got local ip 192.168.0.70
2017-12-26 20:05:43 INFO (Thread-4) [pyhomematic._hm] Creating proxy groups. Connecting to http://192.168.0.70:9292/groups
2017-12-26 20:05:43 DEBUG (Thread-4) [pyhomematic._hm] LockingServerProxy.__init__: Getting local ip
2017-12-26 20:05:43 DEBUG (Thread-4) [pyhomematic._hm] LockingServerProxy.__init__: Got local ip 192.168.0.70
2017-12-26 20:05:43 DEBUG (Thread-4) [pyhomematic._hm] RPCFunctions.__init__
2017-12-26 20:05:43 DEBUG (Thread-4) [pyhomematic._hm] RPCFunctions.__init__: iterating proxy = homeassistant-groups
2017-12-26 20:05:43 DEBUG (Thread-4) [pyhomematic._hm] RPCFunctions.__init__: devices_raw = []
2017-12-26 20:05:43 DEBUG (Thread-4) [pyhomematic._hm] RPCFunctions.createDeviceObjects: iterating interface_id = groups
2017-12-26 20:05:43 DEBUG (Thread-4) [pyhomematic._hm] RPCFunctions.__init__: iterating proxy = homeassistant-wireless
2017-12-26 20:05:43 DEBUG (Thread-4) [pyhomematic._hm] RPCFunctions.__init__: devices_raw = []
2017-12-26 20:05:43 DEBUG (Thread-4) [pyhomematic._hm] RPCFunctions.createDeviceObjects: iterating interface_id = wireless
2017-12-26 20:05:43 DEBUG (Thread-4) [pyhomematic._hm] ServerThread.__init__: Setting up server
2017-12-26 20:05:43 DEBUG (Thread-4) [pyhomematic._hm] ServerThread.__init__: Registering RPC functions
2017-12-26 20:05:43 INFO (Thread-22) [pyhomematic._hm] Starting server at http://192.168.0.70:36845
2017-12-26 20:05:43 DEBUG (Thread-4) [pyhomematic._hm] ServerThread.proxyInit: init('http://172.17.0.2:36845', 'homeassistant-groups')
2017-12-26 20:05:43 DEBUG (Thread-4) [pyhomematic._hm] proxyInit: Exception: [Errno 111] Connection refused
2017-12-26 20:05:43 WARNING (Thread-4) [pyhomematic._hm] Failed to initialize proxy
2017-12-26 20:05:43 CRITICAL (Thread-4) [pyhomematic.connection] Failed to start server
2017-12-26 20:05:43 DEBUG (Thread-4) [pyhomematic.connection]
2017-12-26 20:05:43 DEBUG (Thread-4) [pyhomematic._hm] ServerThread.stop: init('http://172.17.0.2:36845')
2017-12-26 20:05:43 DEBUG (Thread-4) [pyhomematic._hm] proxyInit: Exception: [Errno 111] Connection refused
2017-12-26 20:05:43 WARNING (Thread-4) [pyhomematic._hm] Failed to de-initialize proxy
2017-12-26 20:05:43 ERROR (MainThread) [homeassistant.setup] Error during setup of component homematic
Traceback (most recent call last):
File "/home/haadmin/.homeassistant/deps/lib/python3.5/site-packages/pyhomematic/_hm.py", line 534, in proxyInit
(callbackip, callbackport), interface_id)
File "/usr/lib/python3.5/xmlrpc/client.py", line 1092, in __call__
return self.__send(self.__name, args)
File "/home/haadmin/.homeassistant/deps/lib/python3.5/site-packages/pyhomematic/_hm.py", line 412, in __request
return parent._ServerProxy__request(self, *args, **kwargs)
File "/usr/lib/python3.5/xmlrpc/client.py", line 1432, in __request
verbose=self.__verbose
File "/usr/lib/python3.5/xmlrpc/client.py", line 1134, in request
return self.single_request(host, handler, request_body, verbose)
File "/usr/lib/python3.5/xmlrpc/client.py", line 1146, in single_request
http_conn = self.send_request(host, handler, request_body, verbose)
File "/usr/lib/python3.5/xmlrpc/client.py", line 1259, in send_request
self.send_content(connection, request_body)
File "/usr/lib/python3.5/xmlrpc/client.py", line 1289, in send_content
connection.endheaders(request_body)
File "/usr/lib/python3.5/http/client.py", line 1103, in endheaders
self._send_output(message_body)
File "/usr/lib/python3.5/http/client.py", line 934, in _send_output
self.send(msg)
File "/usr/lib/python3.5/http/client.py", line 877, in send
self.connect()
File "/usr/lib/python3.5/http/client.py", line 849, in connect
(self.host,self.port), self.timeout, self.source_address)
File "/usr/lib/python3.5/socket.py", line 712, in create_connection
raise err
File "/usr/lib/python3.5/socket.py", line 703, in create_connection
sock.connect(sa)
ConnectionRefusedError: [Errno 111] Connection refused
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/haadmin/.homeassistant/deps/lib/python3.5/site-packages/pyhomematic/connection.py", line 74, in start
self._server.proxyInit()
File "/home/haadmin/.homeassistant/deps/lib/python3.5/site-packages/pyhomematic/_hm.py", line 539, in proxyInit
raise Exception
Exception
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/haadmin/.homeassistant/deps/lib/python3.5/site-packages/pyhomematic/_hm.py", line 555, in stop
proxy.init(remote)
File "/usr/lib/python3.5/xmlrpc/client.py", line 1092, in __call__
return self.__send(self.__name, args)
File "/home/haadmin/.homeassistant/deps/lib/python3.5/site-packages/pyhomematic/_hm.py", line 412, in __request
return parent._ServerProxy__request(self, *args, **kwargs)
File "/usr/lib/python3.5/xmlrpc/client.py", line 1432, in __request
verbose=self.__verbose
File "/usr/lib/python3.5/xmlrpc/client.py", line 1134, in request
return self.single_request(host, handler, request_body, verbose)
File "/usr/lib/python3.5/xmlrpc/client.py", line 1146, in single_request
http_conn = self.send_request(host, handler, request_body, verbose)
File "/usr/lib/python3.5/xmlrpc/client.py", line 1259, in send_request
self.send_content(connection, request_body)
File "/usr/lib/python3.5/xmlrpc/client.py", line 1289, in send_content
connection.endheaders(request_body)
File "/usr/lib/python3.5/http/client.py", line 1103, in endheaders
self._send_output(message_body)
File "/usr/lib/python3.5/http/client.py", line 934, in _send_output
self.send(msg)
File "/usr/lib/python3.5/http/client.py", line 877, in send
self.connect()
File "/usr/lib/python3.5/http/client.py", line 849, in connect
(self.host,self.port), self.timeout, self.source_address)
File "/usr/lib/python3.5/socket.py", line 712, in create_connection
raise err
File "/usr/lib/python3.5/socket.py", line 703, in create_connection
sock.connect(sa)
ConnectionRefusedError: [Errno 111] Connection refused
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/usr/local/lib/python3.5/dist-packages/homeassistant/setup.py", line 193, in _async_setup_component
component.setup, hass, processed_config)
File "/usr/lib/python3.5/asyncio/futures.py", line 380, in __iter__
yield self # This tells Task to wait for completion.
File "/usr/lib/python3.5/asyncio/tasks.py", line 304, in _wakeup
future.result()
File "/usr/lib/python3.5/asyncio/futures.py", line 293, in result
raise self._exception
File "/usr/lib/python3.5/concurrent/futures/thread.py", line 55, in run
result = self.fn(*self.args, **self.kwargs)
File "/usr/local/lib/python3.5/dist-packages/homeassistant/components/homematic/__init__.py", line 318, in setup
homematic.start()
File "/home/haadmin/.homeassistant/deps/lib/python3.5/site-packages/pyhomematic/connection.py", line 79, in start
self._server.stop()
File "/home/haadmin/.homeassistant/deps/lib/python3.5/site-packages/pyhomematic/_hm.py", line 561, in stop
raise Exception
Exception
2017-12-26 20:05:43 INFO (MainThread) [homeassistant.core] Bus:Handling <Event call_service[L]: service_call_id=1962225744-2, service_data=title=Invalid config, notification_id=invalid_config, message=The following components and platforms could not be set up:
- [homematic](https://home-assistant.io/components/homematic/)
Please check your config., service=create, domain=persistent_notification>
2017-12-26 20:05:43 INFO (MainThread) [homeassistant.core] Bus:Handling <Event state_changed[L]: old_state=None, new_state=<state persistent_notification.invalid_config=notifying; title=Invalid config, message=The following components and platforms could not be set up:
- [homematic](https://home-assistant.io/components/homematic/)
Weshalb “ConnectionRefusedError: [Errno 111] Connection refused” ???
Passen die Firewall Regeln soweit? Ohne die Iptables-Eintrage kann ich mich nicht mit Home-Assistant verbinden,da dann auch die Verbindung nicht erlaubt ist.
-> http://192.168.0.70:8123
Chain INPUT (policy ACCEPT)
target prot opt source destination
ACCEPT all -- anywhere anywhere
REJECT all -- anywhere loopback/8 reject-with icmp-port-unreachable
ACCEPT all -- anywhere anywhere state RELATED,ESTABLISHED
ACCEPT tcp -- 192.168.0.0/24 anywhere tcp dpt:http
ACCEPT tcp -- 192.168.0.0/24 anywhere tcp dpt:https
ACCEPT tcp -- 192.168.0.0/24 anywhere tcp dpt:http-alt
ACCEPT tcp -- 192.168.0.0/24 anywhere tcp dpt:8123
ACCEPT tcp -- 172.17.0.0/16 anywhere tcp dpt:2001
ACCEPT tcp -- 172.17.0.0/16 anywhere tcp dpt:2002
ACCEPT tcp -- 172.17.0.0/16 anywhere tcp dpt:cfinger
ACCEPT tcp -- 192.168.0.0/24 anywhere tcp dpt:2869
ACCEPT udp -- 192.168.0.0/24 anywhere udp dpt:1900
ACCEPT udp -- 172.17.0.0/16 anywhere udp dpt:2001
ACCEPT udp -- 172.17.0.0/16 anywhere udp dpt:2002
ACCEPT udp -- 172.17.0.0/16 anywhere udp dpt:2003
ACCEPT tcp -- anywhere anywhere state NEW tcp dpt:ssh
ACCEPT icmp -- anywhere anywhere
LOG all -- anywhere anywhere limit: avg 5/min burst 5 LOG level debug prefix "iptables denied: "
DROP all -- anywhere anywhere
Chain FORWARD (policy DROP)
target prot opt source destination
DOCKER-USER all -- anywhere anywhere
DOCKER-ISOLATION all -- anywhere anywhere
ACCEPT all -- anywhere anywhere ctstate RELATED,ESTABLISHED
DOCKER all -- anywhere anywhere
ACCEPT all -- anywhere anywhere
ACCEPT all -- anywhere anywhere
DROP all -- anywhere anywhere
Chain OUTPUT (policy ACCEPT)
target prot opt source destination
ACCEPT all -- anywhere anywhere
ACCEPT all -- anywhere anywhere ctstate ESTABLISHED
Chain DOCKER (1 references)
target prot opt source destination
ACCEPT tcp -- anywhere 172.17.0.2 tcp dpt:cfinger
ACCEPT tcp -- anywhere 172.17.0.2 tcp dpt:2002
ACCEPT tcp -- anywhere 172.17.0.2 tcp dpt:2001
Chain DOCKER-ISOLATION (1 references)
target prot opt source destination
RETURN all -- anywhere anywhere
Chain DOCKER-USER (1 references)
target prot opt source destination
RETURN all -- anywhere anywhere
Und hier bin ich jetzt irritiert -> docker0:172.17.0.1
ip addr show
docker0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue state UP group default
link/ether 02:42:6a:26:01:64 brd ff:ff:ff:ff:ff:ff
inet 172.17.0.1/16 scope global docker0
valid_lft forever preferred_lft forever
inet 169.254.157.77/16 brd 169.254.255.255 scope global docker0
valid_lft forever preferred_lft forever
Aber docker network inspect bridge zeigt
"NetworkSettings": {
"Bridge": "",
"SandboxID": "f6f5742b3ef2c14890c3ad4a6a1b2a49f42397bf04fd55acaa36f42617685806",
"HairpinMode": false,
"LinkLocalIPv6Address": "",
"LinkLocalIPv6PrefixLen": 0,
"Ports": {
"2001/tcp": [
{
"HostIp": "0.0.0.0",
"HostPort": "2001"
}
],
"2002/tcp": [
{
"HostIp": "0.0.0.0",
"HostPort": "2002"
}
],
"2003/tcp": [
{
"HostIp": "0.0.0.0",
"HostPort": "2003"
}
]
},
"SandboxKey": "/var/run/docker/netns/f6f5742b3ef2",
"SecondaryIPAddresses": null,
"SecondaryIPv6Addresses": null,
"EndpointID": "4718e360c1575703de21198ee93c4b960b24bb82a0b422acba409549ddfcd163",
"Gateway": "172.17.0.1",
"GlobalIPv6Address": "",
"GlobalIPv6PrefixLen": 0,
"IPAddress": "172.17.0.2",
"IPPrefixLen": 16,
"IPv6Gateway": "",
"MacAddress": "02:42:ac:11:00:02",
"Networks": {
"bridge": {
"IPAMConfig": null,
"Links": null,
"Aliases": null,
"NetworkID": "33d3f0fee4ac3cf2b55483987a9c8aa4a3f4f771d151eb5792c0ccaf86652c00",
"EndpointID": "4718e360c1575703de21198ee93c4b960b24bb82a0b422acba409549ddfcd163",
"Gateway": "172.17.0.1",
"IPAddress": "172.17.0.2",
"IPPrefixLen": 16,
"IPv6Gateway": "",
"GlobalIPv6Address": "",
"GlobalIPv6PrefixLen": 0,
"MacAddress": "02:42:ac:11:00:02",
"DriverOpts": null
Laut docker0 wäre 172.17.0.1 die zugewiesene IP für den Container.
In der bridge Config steht aber
“Gateway”: “172.17.0.1”,
“IPAddress”: “172.17.0.2”
Was stimmt jetzt? Diese Angaben sind schon verwirrend…
Wie gesagt, konnte ich über das Homematic Utilty den Thermostat über das Funkmodul pairen.
Homegear im Docker Container sieht es ja auch über die RPC-Schnittstelle:
http://192.168.0.70:2001
Ich meine gelesen zu haben, dass der Thermostat von HA erkannt wird und in der Konfiguration auftaucht.
Irgendetwas mache ich also grundlegend falsch.