esphome / issues

Issue Tracker for ESPHome
https://esphome.io/
291 stars 34 forks source link

Error after 2021.9.3 update install #2534

Open theflorianmaas opened 2 years ago

theflorianmaas commented 2 years ago

The problem

I updated my working version of ESPHome from 2021.9.2 to 2021.9.3 and now I get this error. I get this error whenever I compile and upload firmaware in any node.


> [cont-init.d] 01-log-level.sh: executing... 
> [cont-init.d] 01-log-level.sh: exited 0.
> [cont-init.d] 10-requirements.sh: executing... 
> [cont-init.d] 10-requirements.sh: exited 0.
> [cont-init.d] 20-nginx.sh: executing... 
> [cont-init.d] 20-nginx.sh: exited 0.
> [cont-init.d] done.
> [services.d] starting services
> [services.d] done.
> [17:00:53] INFO: Waiting for dashboard to come up...
> [17:00:54] INFO: Starting ESPHome dashboard...
> INFO Starting dashboard web server on unix socket /var/run/esphome.sock and configuration dir /config/esphome...
> Exception in thread Thread-1:
> Traceback (most recent call last):
>   File "/usr/lib/python3.9/threading.py", line 954, in _bootstrap_inner
>     self.run()
>   File "/opt/esphome/esphome/dashboard/dashboard.py", line 504, in run
>     zc = EsphomeZeroconf()
>   File "/usr/local/lib/python3.9/dist-packages/zeroconf/_core.py", line 410, in __init__
>     listen_socket, respond_sockets = create_sockets(interfaces, unicast, ip_version, apple_p2p=apple_p2p)
>   File "/usr/local/lib/python3.9/dist-packages/zeroconf/_utils/net.py", line 359, in create_sockets
>     if add_multicast_member(cast(socket.socket, listen_socket), i):
>   File "/usr/local/lib/python3.9/dist-packages/zeroconf/_utils/net.py", line 276, in add_multicast_member
>     listen_socket.setsockopt(socket.IPPROTO_IP, socket.IP_ADD_MEMBERSHIP, _value)
> OSError: [Errno 105] No buffer space available

Which version of ESPHome has the issue?

2021.9.3

What type of installation are you using?

Home Assistant Add-on

Which version of Home Assistant has the issue?

2021.9.7

What platform are you using?

ESP32

Board

ESP32-cam, ESP32 mini D1, TTGO-CAM

Component causing the issue

zeroconf

Example YAML snippet

No response

Anything in the logs that might be useful for us?

[cont-init.d] 01-log-level.sh: executing... 
[cont-init.d] 01-log-level.sh: exited 0.
[cont-init.d] 10-requirements.sh: executing... 
[cont-init.d] 10-requirements.sh: exited 0.
[cont-init.d] 20-nginx.sh: executing... 
[cont-init.d] 20-nginx.sh: exited 0.
[cont-init.d] done.
[services.d] starting services
[services.d] done.
[17:00:53] INFO: Waiting for dashboard to come up...
[17:00:54] INFO: Starting ESPHome dashboard...
INFO Starting dashboard web server on unix socket /var/run/esphome.sock and configuration dir /config/esphome...
Exception in thread Thread-1:
Traceback (most recent call last):
  File "/usr/lib/python3.9/threading.py", line 954, in _bootstrap_inner
    self.run()
  File "/opt/esphome/esphome/dashboard/dashboard.py", line 504, in run
    zc = EsphomeZeroconf()
  File "/usr/local/lib/python3.9/dist-packages/zeroconf/_core.py", line 410, in __init__
    listen_socket, respond_sockets = create_sockets(interfaces, unicast, ip_version, apple_p2p=apple_p2p)
  File "/usr/local/lib/python3.9/dist-packages/zeroconf/_utils/net.py", line 359, in create_sockets
    if add_multicast_member(cast(socket.socket, listen_socket), i):
  File "/usr/local/lib/python3.9/dist-packages/zeroconf/_utils/net.py", line 276, in add_multicast_member
    listen_socket.setsockopt(socket.IPPROTO_IP, socket.IP_ADD_MEMBERSHIP, _value)
OSError: [Errno 105] No buffer space available

Additional information

No response

theflorianmaas commented 2 years ago

The issue is fixed Found the solution here: https://stackoverflow.com/questions/46727211/oserror-105-no-buffer-space-zeroconf I had to increase the net/ipv4/igmp_max_memberships Thanks

Adil-MohammedK commented 2 years ago

@theflorianmaas How did the systctl work in docker container? for me the command doesn't exit

theflorianmaas commented 2 years ago

systctl is a Linux command, available in Debian and in related distros like Ubuntu. Run it from the Linux prompt not in docker cli.

Adil-MohammedK commented 2 years ago

@theflorianmaas Yes I do know that it is a linux command. I tried it inside bash of esphome container. So its a linux machine. And I also tried in my host Linux machine(Raspberry Pi 4). Here is a screenshot of my terminal

image

Adil-MohammedK commented 2 years ago

[https://community.home-assistant.io/t/zeroconf-error/153883/4]() This solution worked for me

theflorianmaas commented 2 years ago

I do not have a raspberry pi. I suppose you have to modify the file /etc/sysctl.conf

Look at this. It might help you.

https://github.com/divergentdave/raspberry-pi-configuration