hjdhjd / homebridge-unifi-protect

:video_camera: Complete HomeKit integration for all UniFi Protect device types with full support for most features including HomeKit Secure Video, and more. https://homebridge.io
Other
1.39k stars 84 forks source link

API error: Error: EHOSTUNREACH connect EHOSTUNREACH 192.168.1.196:443. #1087

Closed DavidRCT closed 4 weeks ago

DavidRCT commented 4 weeks ago

Homebridge UniFi Protect Version

7.0.1

Homebridge Platform and OS

PI 4

Homebridge Version

1.8.2

Node Version

18.9.0

UniFi OS Version

3.2.12

UniFi Protect Controller Version

4.0.21

Describe the problem

Hi, been running this for some time but getting the following error in the log. Tried restarting the plugin and OS but no luck, none of the cameras are active in HomeKit but are fine in Unifi Protect.

192.168.1.196: API error: Error: EHOSTUNREACH connect EHOSTUNREACH 192.168.1.196:443.

Thanks David

Homebridge HBUP JSON configuration

{
    "bridge": {
        "name": "Homebridge 4E80",
        "username": "*:56:**:**:**:**",
        "port": 51103,
        "pin": "199-22-102",
        "advertiser": "avahi"
    },
    "accessories": [],
    "platforms": [
        {
            "name": "Config",
            "port": 8581,
            "platform": "config"
        },
        {
            "controllers": [
                {
                    "address": "192.168.1.196",
                    "doorbellMessages": [
                        {
                            "duration": 0,
                            "message": "PLEASE RING DOORBELL"
                        },
                        {
                            "duration": 30,
                            "message": "ON MY WAY"
                        }
                    ],
                    "password": "*************",
                    "username": "**********"
                }
            ],
            "name": "UniFi Protect",
            "options": [
                "Enable.Device.SyncName.7483C21AEC0D",
                "Enable.Device.StatusLed.7483C21AEC0D",
                "Enable.Doorbell.PhysicalChime.Duration.Digital.7483C21AEC0D.1000",
                "Enable.Video.Transcode.Hardware.7483C21AEC0D",
                "Disable.Log.Doorbell.7483C21AEC0D",
                "Disable.Doorbell.Trigger.B4FBE49F16D3",
                "Disable.Log.Doorbell.B4FBE49F16D3",
                "Enable.Video.Transcode.Hardware.B4FBE49F16D3",
                "Enable.Device.SyncName.7845582F8097",
                "Enable.Device.StatusLed.7845582F8097",
                "Disable.Log.Doorbell.7845582F8097",
                "Enable.Video.Transcode.Hardware.7845582F8097",
                "Enable.Device.SyncName.B4FBE49F26C6",
                "Enable.Device.StatusLed.B4FBE49F26C6",
                "Disable.Doorbell.Trigger.B4FBE49F26C6",
                "Disable.Log.Doorbell.B4FBE49F26C6",
                "Enable.Video.Transcode.Hardware.B4FBE49F26C6",
                "Enable.Device.SyncName.B4FBE49F2715",
                "Enable.Device.StatusLed.B4FBE49F2715",
                "Disable.Doorbell.Trigger.B4FBE49F2715",
                "Disable.Log.Doorbell.B4FBE49F2715",
                "Enable.Video.Transcode.Hardware.B4FBE49F2715",
                "Enable.Device.SyncName.B4FBE49F16D3",
                "Enable.Device.StatusLed.B4FBE49F16D3",
                "Enable.Doorbell.Trigger.7483C21AEC0D",
                "Enable.Doorbell.Trigger.7845582F8097",
                "Disable.Doorbell.Messages.FromDoorbell.7483C21AEC0D",
                "Enable.Video.HKSV.Record.Only.High.7483C21AEC0D",
                "Enable.Video.Stream.Only.High.7483C21AEC0D"
            ],
            "_bridge": {
                "username": "**:AC:26:**:09:**",
                "port": 36676
            },
            "platform": "UniFi Protect"
        }
    ]
}

Relevant log output

[07/06/2024, 19:48:26] [UniFi Protect] 192.168.1.196: API error: Error: EHOSTUNREACH connect EHOSTUNREACH 192.168.1.196:443.
[07/06/2024, 19:48:58] [UniFi Protect] 192.168.1.196: API error: Error: EHOSTUNREACH connect EHOSTUNREACH 192.168.1.196:443.
[07/06/2024, 19:49:14] [UniFi Protect] 192.168.1.196: API error: Error: EHOSTUNREACH connect EHOSTUNREACH 192.168.1.196:443.
[07/06/2024, 19:49:30] [UniFi Protect] 192.168.1.196: API error: Error: EHOSTUNREACH connect EHOSTUNREACH 192.168.1.196:443.
[07/06/2024, 19:49:47] [UniFi Protect] 192.168.1.196: API error: Error: EHOSTUNREACH connect EHOSTUNREACH 192.168.1.196:443.
[07/06/2024, 19:49:57] [UniFi Protect] 192.168.1.196: API error: Throttling API calls due to errors with the 10 previous attempts. Pausing communication with the Protect controller for 5 minutes.
[07/06/2024, 19:54:57] [UniFi Protect] 192.168.1.196: API error: Resuming connectivity to the UniFi Protect API after pausing for 5 minutes.
[07/06/2024, 19:55:03] [UniFi Protect] 192.168.1.196: API error: Error: EHOSTUNREACH connect EHOSTUNREACH 192.168.1.196:443.
[07/06/2024, 19:55:06] [UniFi Protect] 192.168.1.196: API error: Error: EHOSTUNREACH connect EHOSTUNREACH 192.168.1.196:443.
[07/06/2024, 19:55:22] [UniFi Protect] 192.168.1.196: API error: Error: EHOSTUNREACH connect EHOSTUNREACH 192.168.1.196:443.
[07/06/2024, 19:55:38] [UniFi Protect] 192.168.1.196: API error: Error: EHOSTUNREACH connect EHOSTUNREACH 192.168.1.196:443.
[07/06/2024, 19:55:54] [UniFi Protect] 192.168.1.196: API error: Error: EHOSTUNREACH connect EHOSTUNREACH 192.168.1.196:443.
[07/06/2024, 19:56:07] [UniFi Protect] 192.168.1.196: API error: Throttling API calls due to errors with the 10 previous attempts. Pausing communication with the Protect controller for 5 minutes.

Acknowledgment that you are only running UniFi OS and UniFi Protect releases from the Ubiquiti Official release channel

hjdhjd commented 4 weeks ago

Thanks for the report. Not to state the obvious...but you're having network issues here. Not much I can do here...looks like your Protect controller is inaccessible from the Pi4 you're running HBUP on. Not much I can do I'm afraid...I'd doublecheck the connectivity. Perhaps you're using multiple network interfaces or a Docker setup? If so...that can lead to issues as well.

DavidRCT commented 4 weeks ago

Yeah I can access the Pi so it's on the network, but you've given me a couple of hints so will work on it. Just odd it's just stopped working. Thanks.

hjdhjd commented 4 weeks ago

Generally when stuff like this happens, it's not related to HBUP. It's a network connection's been unplugged, a firewall rule added, a controller when wacky, etc.

DavidRCT commented 4 weeks ago

Really odd, I removed and reinstalled the plugin and it works again. Probably didn't have any coffee this morning ;-)

github-actions[bot] commented 3 weeks ago

This issue is locked to prevent necroposting on closed issues. Please create a new issue for related support requests, bug reports, or feature suggestions.