blakeblackshear / frigate

NVR with realtime local object detection for IP cameras
https://frigate.video
MIT License
19.15k stars 1.75k forks source link

[Camera Support]: Tapo C320WS crashing HA #8457

Closed froniusMW closed 11 months ago

froniusMW commented 1 year ago

Describe the problem you are having

If I add my C320WS to frigate it crashes HA and reboots whole HA. Been running my C310 for almost an year without any problems. It reebots HA aproximatly 4times per day. If I remove the C320WS from config no reboots. Nothing in the HA core log before the crash and reboot. Tried both Frigate and the beta, same problem. Latest crash/reboot was at 14:54

Version

0.13.0 beta

Frigate config file

mqtt:
  host: 192.168.0.141
  user: mqtt
  password: '********'

cameras:
  uppfart_frigate:
    enabled: True
    ffmpeg:
      hwaccel_args: preset-vaapi
      inputs:
        - path: rtsp://****:*******@192.168.0.166/stream1:554
          roles:
            - rtmp
            - record
            - detect
  bakgard_frigate:
    enabled: True
    ffmpeg:
      hwaccel_args: preset-vaapi
      inputs:
        - path: rtsp://*******:*******@192.168.0.164/stream1:554
          roles:
            - rtmp
            - record
            - detect  
detect:
    width: 1920
    height: 1080
    fps: 5
objects: 
        track:
          - person
          - cat
          - dog
          - horse
        filters:
         person:
          min_area: 0
          max_area: 24000000
          min_ratio: 0
          max_ratio: 24000000
          min_score: 0.5
          threshold: 0.80
record:
      enabled: True
snapshots:
      enabled: true
rtmp:
      enabled: false
detectors:
  ov:
    type: openvino
    device: AUTO
    model:
      path: /openvino-model/ssdlite_mobilenet_v2.xml
model:
  width: 300
  height: 300
  input_tensor: nhwc
  input_pixel_format: bgr
  labelmap_path: /openvino-model/coco_91cl_bkgr.txt      

Relevant log output

s6-rc: info: service s6rc-fdholder: starting
s6-rc: info: service s6rc-oneshot-runner: starting
s6-rc: info: service s6rc-oneshot-runner successfully started
s6-rc: info: service fix-attrs: starting
s6-rc: info: service s6rc-fdholder successfully started
s6-rc: info: service fix-attrs successfully started
s6-rc: info: service legacy-cont-init: starting
s6-rc: info: service legacy-cont-init successfully started
s6-rc: info: service log-prepare: starting
s6-rc: info: service log-prepare successfully started
s6-rc: info: service nginx-log: starting
s6-rc: info: service go2rtc-log: starting
s6-rc: info: service frigate-log: starting
s6-rc: info: service nginx-log successfully started
s6-rc: info: service go2rtc-log successfully started
s6-rc: info: service go2rtc: starting
s6-rc: info: service frigate-log successfully started
s6-rc: info: service go2rtc successfully started
s6-rc: info: service go2rtc-healthcheck: starting
s6-rc: info: service frigate: starting
s6-rc: info: service go2rtc-healthcheck successfully started
s6-rc: info: service frigate successfully started
s6-rc: info: service nginx: starting
2023-11-04 19:24:11.761271730  [INFO] Preparing Frigate...
s6-rc: info: service nginx successfully started
s6-rc: info: service legacy-services: starting
2023-11-04 19:24:11.766242786  [INFO] Starting NGINX...
2023-11-04 19:24:11.766326121  [INFO] Preparing go2rtc config...
s6-rc: info: service legacy-services successfully started
2023-11-04 19:24:11.777387554  [INFO] Starting Frigate...
2023-11-04 19:24:11.813659368  [INFO] Got IP address from supervisor: 192.168.0.141
2023-11-04 19:24:11.857502030  [INFO] Got WebRTC port from supervisor: 8555
2023-11-04 19:24:12.138383577  [INFO] Starting go2rtc...
2023-11-04 19:24:12.228766611  20:24:12.228 INF go2rtc version 1.8.1 linux/amd64
2023-11-04 19:24:12.229106512  20:24:12.229 INF [api] listen addr=0.0.0.0:1984
2023-11-04 19:24:12.229359374  20:24:12.229 INF [rtsp] listen addr=0.0.0.0:8554
2023-11-04 19:24:12.229621021  20:24:12.229 INF [webrtc] listen addr=0.0.0.0:8555/tcp
2023-11-04 19:24:13.456780371  [2023-11-04 20:24:13] frigate.app                    INFO    : Starting Frigate (0.13.0-cd64399)
2023-11-04 19:24:13.456861792  [2023-11-04 20:24:13] frigate.app                    INFO    : Creating directory: /tmp/cache
2023-11-04 19:24:13.484264388  [2023-11-04 20:24:13] frigate.config                 WARNING : Customizing more than a detector model path is unsupported.
2023-11-04 19:24:13.496197163  [2023-11-04 20:24:13] peewee_migrate.logs            INFO    : Starting migrations
2023-11-04 19:24:13.501262591  [2023-11-04 20:24:13] peewee_migrate.logs            INFO    : There is nothing to migrate
2023-11-04 19:24:13.505784822  [2023-11-04 20:24:13] frigate.app                    INFO    : Recording process started: 305
2023-11-04 19:24:13.508753571  [2023-11-04 20:24:13] frigate.app                    INFO    : go2rtc process pid: 89
2023-11-04 19:24:13.535759617  [2023-11-04 20:24:13] frigate.app                    INFO    : Output process started: 317
2023-11-04 19:24:13.545644893  [2023-11-04 20:24:13] detector.ov                    INFO    : Starting detection process: 315
2023-11-04 19:24:13.556972900  [2023-11-04 20:24:13] frigate.app                    INFO    : Camera processor started for uppfart_frigate: 322
2023-11-04 19:24:13.561836455  [2023-11-04 20:24:13] frigate.app                    INFO    : Camera processor started for bakgard_frigate: 324
2023-11-04 19:24:13.566648789  [2023-11-04 20:24:13] frigate.app                    INFO    : Capture process started for uppfart_frigate: 325
2023-11-04 19:24:13.575590816  [2023-11-04 20:24:13] frigate.app                    INFO    : Capture process started for bakgard_frigate: 326
2023-11-04 19:24:13.900388608  [2023-11-04 20:24:13] frigate.detectors.plugins.openvino INFO    : Model Input Shape: [1,300,300,3]
2023-11-04 19:24:13.900452975  [2023-11-04 20:24:13] frigate.detectors.plugins.openvino INFO    : Model Output-0 Shape: [1,1,100,7]
2023-11-04 19:24:13.900559714  [2023-11-04 20:24:13] frigate.detectors.plugins.openvino INFO    : Model has 1 Output Tensors
2023-11-04 19:24:21.761511397  [INFO] Starting go2rtc healthcheck service...
2023-11-04 19:24:30.657256574  172.30.32.2 - - [04/Nov/2023:20:24:30 +0100] "GET // HTTP/1.1" 200 6693 "http://homeassistant.local:8123/hassio" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/118.0.0.0 Safari/537.36" "192.168.0.38, 172.30.32.1"
2023-11-04 19:24:30.691262947  172.30.32.2 - - [04/Nov/2023:20:24:30 +0100] "GET /api/config HTTP/1.1" 200 13155 "http://homeassistant.local:8123/api/hassio_ingress/_KPYU-4dLEfKFEZE5D1hUCxqxdwbeawlYSduAGaKf9Y//" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/118.0.0.0 Safari/537.36" "192.168.0.38, 172.30.32.1"
2023-11-04 19:24:30.751042250  172.30.32.2 - - [04/Nov/2023:20:24:30 +0100] "GET /api/bakgard_frigate/latest.jpg?h=100 HTTP/1.1" 200 4829 "http://homeassistant.local:8123/api/hassio_ingress/_KPYU-4dLEfKFEZE5D1hUCxqxdwbeawlYSduAGaKf9Y//" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/118.0.0.0 Safari/537.36" "192.168.0.38, 172.30.32.1"
2023-11-04 19:24:30.757343692  172.30.32.2 - - [04/Nov/2023:20:24:30 +0100] "GET /api/uppfart_frigate/latest.jpg?h=100 HTTP/1.1" 200 3836 "http://homeassistant.local:8123/api/hassio_ingress/_KPYU-4dLEfKFEZE5D1hUCxqxdwbeawlYSduAGaKf9Y//" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/118.0.0.0 Safari/537.36" "192.168.0.38, 172.30.32.1"
2023-11-04 19:24:30.802223747  172.30.32.2 - - [04/Nov/2023:20:24:30 +0100] "GET /api/uppfart_frigate/latest.jpg?h=202 HTTP/1.1" 200 11780 "http://homeassistant.local:8123/api/hassio_ingress/_KPYU-4dLEfKFEZE5D1hUCxqxdwbeawlYSduAGaKf9Y//" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/118.0.0.0 Safari/537.36" "192.168.0.38, 172.30.32.1"
2023-11-04 19:24:30.804698368  172.30.32.2 - - [04/Nov/2023:20:24:30 +0100] "GET /api/bakgard_frigate/latest.jpg?h=202 HTTP/1.1" 200 17289 "http://homeassistant.local:8123/api/hassio_ingress/_KPYU-4dLEfKFEZE5D1hUCxqxdwbeawlYSduAGaKf9Y//" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/118.0.0.0 Safari/537.36" "192.168.0.38, 172.30.32.1"
2023-11-04 19:24:32.979459254  172.30.32.2 - - [04/Nov/2023:20:24:32 +0100] "GET /api/config HTTP/1.1" 200 13155 "http://homeassistant.local:8123/api/hassio_ingress/_KPYU-4dLEfKFEZE5D1hUCxqxdwbeawlYSduAGaKf9Y//" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/118.0.0.0 Safari/537.36" "192.168.0.38, 172.30.32.1"
2023-11-04 19:24:33.210674476  172.30.32.2 - - [04/Nov/2023:20:24:33 +0100] "GET /api/logs/frigate HTTP/1.1" 200 589 "http://homeassistant.local:8123/logs" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/118.0.0.0 Safari/537.36" "192.168.0.38, 172.30.32.1"
2023-11-04 19:24:33.214441969  172.30.32.2 - - [04/Nov/2023:20:24:33 +0100] "GET /api/logs/go2rtc HTTP/1.1" 200 319 "http://homeassistant.local:8123/logs" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/118.0.0.0 Safari/537.36" "192.168.0.38, 172.30.32.1"
2023-11-04 19:24:33.214999634  172.30.32.2 - - [04/Nov/2023:20:24:33 +0100] "GET /api/logs/nginx HTTP/1.1" 200 527 "http://homeassistant.local:8123/logs" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/118.0.0.0 Safari/537.36" "192.168.0.38, 172.30.32.1"
2023-11-04 19:24:42.518904519  172.30.32.2 - - [04/Nov/2023:20:24:42 +0100] "GET /api/config/raw HTTP/1.1" 200 514 "http://homeassistant.local:8123/config" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/118.0.0.0 Safari/537.36" "192.168.0.38, 172.30.32.1"
2023-11-04 19:24:42.696452692  172.30.32.2 - - [04/Nov/2023:20:24:42 +0100] "GET /api/config/schema.json HTTP/1.1" 200 29375 "http://homeassistant.local:8123/api/hassio_ingress/_KPYU-4dLEfKFEZE5D1hUCxqxdwbeawlYSduAGaKf9Y/assets/yaml.worker.bundle.js" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/118.0.0.0 Safari/537.36" "192.168.0.38, 172.30.32.1"
2023-11-04 19:25:57.398532179  172.30.32.2 - - [04/Nov/2023:20:25:57 +0100] "GET / HTTP/1.1" 200 6636 "-" "HomeAssistantSupervisor/2023.10.1 aiohttp/3.8.6 Python/3.11" "-"
2023-11-04 19:26:09.625008319  172.30.32.2 - - [04/Nov/2023:20:26:09 +0100] "GET /api/config HTTP/1.1" 200 13155 "http://homeassistant.local:8123/config" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/118.0.0.0 Safari/537.36" "192.168.0.38, 172.30.32.1"
2023-11-04 19:26:09.626034793  172.30.32.2 - - [04/Nov/2023:20:26:09 +0100] "GET /api/config/raw HTTP/1.1" 200 514 "http://homeassistant.local:8123/config" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/118.0.0.0 Safari/537.36" "192.168.0.38, 172.30.32.1"
2023-11-04 19:26:11.729290888  172.30.32.2 - - [04/Nov/2023:20:26:11 +0100] "GET /api/logs/frigate HTTP/1.1" 200 589 "http://homeassistant.local:8123/logs" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/118.0.0.0 Safari/537.36" "192.168.0.38, 172.30.32.1"
2023-11-04 19:26:11.730103773  172.30.32.2 - - [04/Nov/2023:20:26:11 +0100] "GET /api/logs/go2rtc HTTP/1.1" 200 319 "http://homeassistant.local:8123/logs" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/118.0.0.0 Safari/537.36" "192.168.0.38, 172.30.32.1"
2023-11-04 19:26:11.734783559  172.30.32.2 - - [04/Nov/2023:20:26:11 +0100] "GET /api/logs/nginx HTTP/1.1" 200 773 "http://homeassistant.local:8123/logs" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/118.0.0.0 Safari/537.36" "192.168.0.38, 172.30.32.1"
2023-11-04 19:26:14.593553926  172.30.32.2 - - [04/Nov/2023:20:26:14 +0100] "GET /ws HTTP/1.1" 101 8060 "-" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/118.0.0.0 Safari/537.36" "192.168.0.38, 172.30.32.1"

FFprobe output from your camera

[{"return_code":0,"stderr":"","stdout":{"programs":[],"streams":[{"avg_frame_rate":"15/1","codec_long_name":"H.264/AVC/MPEG-4AVC/MPEG-4part10","height":1080,"width":1920},{"avg_frame_rate":"0/0","bit_rate":"64000","codec_long_name":"PCMA-law/G.711A-law"}]}}]

Frigate stats

No response

Operating system

HassOS

Install method

HassOS Addon

Coral version

CPU (no coral)

Network connection

Wired

Camera make and model

Tapo C320WS

Any other information that may be helpful

Camera is on WIFI, but good rssi, and Unifi AP

NickM-27 commented 1 year ago

what is the name of this new camera?

froniusMW commented 1 year ago

TP-Link Tapo C320WS HW:2.0 FW: 1.0.5

NickM-27 commented 1 year ago

I mean in your config

froniusMW commented 1 year ago

Ah, sorry, its bakgard_frigate

NickM-27 commented 1 year ago

got it, do you happen to have a copy of the logs that aren't saved as one line?

froniusMW commented 1 year ago

Logs for frigate? What do you mean by online?

NickM-27 commented 1 year ago

Both the config and logs above in this post are a single line because the new lines were removed or it was pasted without formatting

NickM-27 commented 1 year ago

one thing I would suggest is using preset-vaapi instead of qsv

NickM-27 commented 1 year ago

the logs are still one long line, you can use the copy button inside the frigate webUI to get them

froniusMW commented 1 year ago

there, I get it now, changed to vaapi though now like Nick said

froniusMW commented 1 year ago

Ran with the camera disabled in config for about a week. No crashes, tried to enable it yesterday, hard reebot of HA an hour later. The frigate logs are wiped on restart. Nothing in the HA core logs.

NickM-27 commented 1 year ago

Without logs there's no way to know why this camera is causing problems.

froniusMW commented 1 year ago

Is there any way to view the frigate addon logs before the restart? The frigate integration is in debug mode now. But HA has chrashed without the integration before

NickM-27 commented 1 year ago

not in HA OS, unless HA OS keeps addon logs (which it might)

github-actions[bot] commented 11 months ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.