home-assistant / home-assistant.io

:blue_book: Home Assistant User documentation
https://www.home-assistant.io
Other
4.98k stars 7.29k forks source link

Presence detection (opnsense) does not work for me #34059

Closed alexg-k closed 3 months ago

alexg-k commented 3 months ago

Feedback

My problem is that all device-trackers are being shown always as at Home and never as Away. It does not depend on the connection status of the device in the network as it should.

Homeassistant seems to connect to Opnsense. It showed a SSL connection error at first, but that was fixed by adding my custom CA. I get no error in the logs now.

Here is my Homeassistant configuration:

automation: !include automations.yaml
script: !include scripts.yaml
scene: !include scenes.yaml

http:
  use_x_forwarded_for: true
  trusted_proxies:
    - 172.30.33.0/24
  ip_ban_enabled: true
  login_attempts_threshold: 5

additional_ca:
  my_private_ca: lan.crt

opnsense:
  url: https://router.lan/api
  api_secret: U+sfLniJujz94...
  api_key: JdjDxeaxhOs3cL...
  verify_ssl: True
  tracker_interfaces:
    - Trusted

group:
  smartphones:
    name: "Our Smartphones"
    entities:
      - device_tracker.phone_alice
      - device_tracker.phone_bob

The interface Trusted is the name of the opnsense interface where both devices are in.

Here is my Opnsense user configuration: Screenshot from 2024-08-01 07-11-37

The devices show up in homeassistant: Screenshot from 2024-08-01 07-41-35

When I open a device tracker in homeassistant I get this warning, but this might be normal: Screenshot from 2024-08-01 07-47-19

URL

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

Version

2024.7.4

Additional information

No response

home-assistant[bot] commented 3 months ago

Hey there @mtreinish, mind taking a look at this feedback as it has been labeled with an integration (opnsense) you are listed as a code owner for? Thanks!

Code owner commands Code owners of `opnsense` can trigger bot actions by commenting: - `@home-assistant close` Closes the feedback. - `@home-assistant rename Awesome new title` Renames the feedback. - `@home-assistant reopen` Reopen the feedback. - `@home-assistant unassign opnsense` Removes the current integration label and assignees on the feedback, add the integration domain after the command. - `@home-assistant add-label needs-more-information` Add a label (needs-more-information) to the feedback. - `@home-assistant remove-label needs-more-information` Remove a label (needs-more-information) on the feedback.
klaasnicolaas commented 3 months ago

Thank you for reaching out. We use GitHub for tracking issues, not for providing support.

If you are in need of support, you should try our Community Forum or join our Discord chat server.

You are more likely to get the answer you are looking for in those places.

Thanks! 👍

./Klaas

alexg-k commented 3 months ago

Hi @klaasnicolaas,

thank you, I will do that. One further remark: I landed in the issue section here because of this page: Link. On the bottom, it asks me to "provide feedback for this page" and sends me right here. I find this misleading, if this is only intended for confirmed issues.

klaasnicolaas commented 3 months ago

That button is for documentation feedback, from your issue I have not been able to determine that there is anything that can be improved in the documentation. More like an issue with the integration or a support question.

./klaas