Device_tracker.luci Invalid response from luci: <Response [404]>


TLDR: on router; rm /tmp/luci-indexcache

I set-up on my router:

opkg install luci-mod-rpc

In my homeassistant.log I had the following error:

homeassistant.components.device_tracker.luci] Invalid response from luci: <Response [404]>

(Many google searches later and scratching of head)

On my OpenWRT router:

rm /tmp/luci-indexcache

Restart homeassistant and now everything working.

According to the author this is solved.


I run into the same problem. I tried the proposed solution but this does not solve it for me.

Any tips would be appreciated.



1 Like

Having the same problem here. The only relevant lines in my log:

2017-10-29 22:43:39 ERROR (MainThread) [homeassistant.components.device_tracker] Unable to load /config/known_devices.yaml: Config file not found: /config/known_devices.yaml
2017-10-29 22:43:39 ERROR (SyncWorker_4) [homeassistant.components.device_tracker.luci] Invalid response from luci: <Response [404]>
2017-10-29 22:43:39 ERROR (MainThread) [homeassistant.components.device_tracker] Error setting up platform luci

Anyone else had this issue?


For me reinstalling luci-mod-rpc now has helped (I am not sure what I tried before, or what has changed in the repository, but i assume there has been a package update somehow, likely on the Lede-side)).

Did you install or re-install/update luci-mod-rpc on your Lede-router?

What is the output of

opkg install luci-mod-rpc?



Hm, it did update luci-mod-rpc and luci-lib-json. So now opkg install luci-mod-rpc says it is installed and up to date:

 root@linksys:~# opkg install luci-mod-rpc
 Package luci-mod-rpc (git-17.291.51172-a98548e-1) installed in root is up to date.

Now Home Assistant doesn’t give any startup errors but every time it tries to ping luci this shows in the logs:

 2017-11-08 19:29:25 ERROR (SyncWorker_5) [homeassistant.components.device_tracker.luci] Luci responded with a 403 Invalid token
 2017-11-08 19:29:38 ERROR (SyncWorker_10) [homeassistant.components.device_tracker.luci] Luci responded with a 403 Invalid token
 2017-11-08 19:29:51 ERROR (SyncWorker_13) [homeassistant.components.device_tracker.luci] Luci responded with a 403 Invalid token

This thread may help you:

Yeah I’ve seen that thread, thanks though. Unfortunately I’m getting a different error, “Luci responded with a 403 Invalid token”, which I can’t find any information about on google.

1 Like

I have same error in log with my Lede Router. But, with suggestion of another thread i now have a working device tracker

Here’s my logs:

urllib3.exceptions.ReadTimeoutError: HTTPConnectionPool(host='', port=80): Read timed out. (read timeout=5)
During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/lib/python3.5/asyncio/", line 241, in _step
    result = coro.throw(exc)
  File "/srv/homeassistant/lib/python3.5/site-packages/homeassistant/components/device_tracker/", line 711, in async_device_tracker_scan
    found_devices = yield from scanner.async_scan_devices()
  File "/usr/lib/python3.5/asyncio/", line 380, in __iter__
    yield self  # This tells Task to wait for completion.
  File "/usr/lib/python3.5/asyncio/", line 304, in _wakeup
  File "/usr/lib/python3.5/asyncio/", line 293, in result
    raise self._exception
  File "/usr/lib/python3.5/concurrent/futures/", line 55, in run
    result = self.fn(*self.args, **self.kwargs)
  File "/srv/homeassistant/lib/python3.5/site-packages/homeassistant/components/device_tracker/",     line 64, in scan_devices
  File "/srv/homeassistant/lib/python3.5/site-packages/homeassistant/components/device_tracker/", line 99, in _update_info
    params={'auth': self.token})
  File "/srv/homeassistant/lib/python3.5/site-packages/homeassistant/components/device_tracker/", line 123, in _req_json_rpc
    res =, data=data, timeout=5, **kwargs)
  File "/srv/homeassistant/lib/python3.5/site-packages/requests/", line 112, in post
    return request('post', url, data=data, json=json, **kwargs)
  File "/srv/homeassistant/lib/python3.5/site-packages/requests/", line 58, in request
    return session.request(method=method, url=url, **kwargs)
  File "/srv/homeassistant/lib/python3.5/site-packages/requests/", line 508, in request
    resp = self.send(prep, **send_kwargs)
  File "/srv/homeassistant/lib/python3.5/site-packages/requests/", line 618, in send
    r = adapter.send(request, **kwargs)
  File "/srv/homeassistant/lib/python3.5/site-packages/requests/", line 521, in send
    raise ReadTimeout(e, request=request)
requests.exceptions.ReadTimeout: HTTPConnectionPool(host='', port=80): Read timed out. (read timeout=5)
2018-01-24 11:42:04 ERROR (Thread-3) [homeassistant.components.device_tracker.luci] Luci responded with a 403 Invalid token

Did you resolved your problem?

Did you end up resolving your issue?