Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Docker Image] Error Header value is too long. #23077

Closed
xarbit opened this issue Apr 13, 2019 · 3 comments
Closed

[Docker Image] Error Header value is too long. #23077

xarbit opened this issue Apr 13, 2019 · 3 comments

Comments

@xarbit
Copy link

xarbit commented Apr 13, 2019

Operating environment (Hass.io/Docker/Windows/etc.):
Docker, image from https://hub.docker.com/r/homeassistant/home-assistant

Description of problem:
I installed home assistant via Docker and get the following error trying to access the web interface.:

Got more than 8190 bytes (10694) when reading Header value is too long.

The interface is not accessible at all.

Install method:
docker run --init -d --name="home-assistant" -v /home/yourname/homeassistant/latest:/config -v /etc/localtime:/etc/localtime:ro -p 8123:8123 --device /dev/ttyACM0 --restart unless-stopped homeassistant/home-assistant:latest

Traceback (if applicable):

2019-04-13 20:38:16 ERROR (MainThread) [aiohttp.server] Error handling request
Traceback (most recent call last):
  File "/usr/local/lib/python3.7/site-packages/aiohttp/web_protocol.py", line 275, in data_received
    messages, upgraded, tail = self._request_parser.feed_data(data)
  File "aiohttp/_http_parser.pyx", line 523, in aiohttp._http_parser.HttpParser.feed_data
  File "aiohttp/_http_parser.pyx", line 649, in aiohttp._http_parser.cb_on_header_value
aiohttp.http_exceptions.LineTooLong: 400, message='Got more than 8190 bytes (10694) when reading Header value is too long.'

home-assistant.log

Additional information:
I tried many versions (latest, dev down to 0.89.2).
All with the same issue and it seems to be related to aiohttp.
See :
aio-libs/aiohttp#2304

@xarbit
Copy link
Author

xarbit commented Apr 13, 2019

Ok, after having this with openhab too, I found this report that actually helped solved it partly for me, at least I could access the interface.
(yes I also have tvheadend running on the same host):

openhab/openhab-core#287

@stale
Copy link

stale bot commented Aug 16, 2019

There hasn't been any activity on this issue recently. Due to the high number of incoming GitHub notifications, we have to clean some of the old issues, as many of them have already been resolved with the latest updates.
Please make sure to update to the latest Home Assistant version and check if that solves the issue. Let us know if that works for you by adding a comment 👍
This issue now has been marked as stale and will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the stale label Aug 16, 2019
@stale stale bot closed this as completed Aug 23, 2019
@barberio
Copy link

The cause of this is that aiohttp, which is used at various places in home-assistant, applies strict checking of 8190 bytes for headers.

#aio-libs/aiohttp/issues/2304

Either checks need to be made to make sure home-assistant never passed over-sized headers to aiohttp, or to use a patched version of aiohttp that relaxes the restriction on header length.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants