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

Roborock integration unable to connect to the vacuum (S5 Max) #92660

Closed
mag1024 opened this issue May 6, 2023 · 6 comments
Closed

Roborock integration unable to connect to the vacuum (S5 Max) #92660

mag1024 opened this issue May 6, 2023 · 6 comments

Comments

@mag1024
Copy link

mag1024 commented May 6, 2023

The problem

The integration locates the vacuum's IP successfully, but is unable to connect to the device.

2023-05-05 23:07:49.897 INFO (MainThread) [roborock.local_api] Connecting to 10.0.4.29
2023-05-05 23:07:51.478 INFO (MainThread) [roborock.cloud_api] Starting mqtt loop
2023-05-05 23:07:51.479 INFO (MainThread) [roborock.cloud_api] Connecting to mqtt
2023-05-05 23:07:52.530 INFO (Thread-68 (_thread_main)) [roborock.cloud_api] Connected to mqtt mqtt-us.roborock.com:8883
2023-05-05 23:07:52.531 INFO (Thread-68 (_thread_main)) [roborock.cloud_api] Subscribed to topic rr/m/o/.../#
2023-05-05 23:07:52.601 INFO (MainThread) [roborock.cloud_api] Disconnecting from mqtt
2023-05-05 23:07:52.601 WARNING (Thread-68 (_thread_main)) [roborock.api] Roborock client disconnected
2023-05-05 23:07:52.602 WARNING (Thread-68 (_thread_main)) [roborock.api] (rc: 0)
2023-05-05 23:07:52.602 INFO (MainThread) [roborock.local_api] Connecting to 10.0.4.29
2023-05-05 23:07:53.899 INFO (MainThread) [roborock.local_api] Connecting to 10.0.4.29
2023-05-05 23:07:56.604 INFO (MainThread) [roborock.local_api] Connecting to 10.0.4.29
2023-05-05 23:08:00.606 INFO (MainThread) [roborock.local_api] Connecting to 10.0.4.29
2023-05-05 23:08:04.606 INFO (MainThread) [roborock.local_api] Connecting to 10.0.4.29

And so forth.
FWIW, the device is on a different vlan from HA, but HA has no issues communicating with other devices on that vlan.
I also noticed that the vacuum doesn't respond to pings, and does not seem to have any ports open -- is it supposed to? -- but it works fine with the Roborock app.

What version of Home Assistant Core has the issue?

2023.5.3

What was the last working version of Home Assistant Core?

No response

What type of installation are you running?

Home Assistant Core

Integration causing the issue

roborock

Link to integration documentation on our website

https://www.home-assistant.io/integrations/roborock

Diagnostics information

No response

Example YAML snippet

No response

Anything in the logs that might be useful for us?

No response

Additional information

No response

@home-assistant
Copy link

home-assistant bot commented May 6, 2023

Hey there @humbertogontijo, @Lash-L, mind taking a look at this issue as it has been labeled with an integration (roborock) you are listed as a code owner for? Thanks!

Code owner commands

Code owners of roborock can trigger bot actions by commenting:

  • @home-assistant close Closes the issue.
  • @home-assistant rename Awesome new title Renames the issue.
  • @home-assistant reopen Reopen the issue.
  • @home-assistant unassign roborock Removes the current integration label and assignees on the issue, add the integration domain after the command.

(message by CodeOwnersMention)


roborock documentation
roborock source
(message by IssueLinks)

@humbertogontijo
Copy link
Contributor

Port open in device needs to be 58867

@ufozone
Copy link

ufozone commented May 6, 2023

This is not an issue of integration but of your network design.

In this issue comment you find the solution:
rytilahti/python-miio#422 (comment)

@mag1024
Copy link
Author

mag1024 commented May 6, 2023

Thanks -- indeed, I was able to to get it to work by forcing the relevant traffic to be masqueraded.

I agree that it's not a bug in the integration, but it is also not an issue of network design. This kind of segmenting of iot devices to separate vlan is a common security best-practice, and does not require nat. The problem is rather with the existence of this non-standard security "feature" in Xiaomi devices.

Please consider updating the integration documentation to call out this limitation, and, possibly, even mention in when logging a "failed to connect" error.

@Lash-L
Copy link
Contributor

Lash-L commented May 6, 2023

I agree @mag1024 - I have an outstanding PR for the documentation that adds a bunch of FAQ and this information should be on it.

Glad you got it working and I will try to add this to the docs! Thank you!

I'm going to close this for now

@Lash-L
Copy link
Contributor

Lash-L commented May 6, 2023

@home-assistant close

@home-assistant home-assistant bot closed this as completed May 6, 2023
@github-actions github-actions bot locked and limited conversation to collaborators Jun 5, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

4 participants