blakeblackshear / frigate

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

[Support]: Working setup but full of errors #2516

Closed lee-costa closed 2 years ago

lee-costa commented 2 years ago

Describe the problem you are having

I am running the latest version of Frigate but noticed that sometimes when checking the logs, I am seeing a lot of errors and would like to get to the bottom of them.

Version

0.9.4

Frigate config file

# mqtt
mqtt:
host: 192.168.141.21
user: REDACTED
password: REDACTED

database:
path: /db/frigate.db

# detectors
detectors:
cpu1:
  type: cpu
cpu2:
  type: cpu

# Optional: birdseye configuration
birdseye:
enabled: True
width: 1920
height: 1080
quality: 8
mode: motion

record:
enabled: True
retain_days: 0
events:
  max_seconds: 240
  pre_capture: 5
  post_capture: 5

cameras:
driveway_cam:
  objects:
    track:
      - person
      - car  
  ffmpeg:
    inputs:
      - path: rtsp://REDACTED:REDACTED@192.168.141.14:554/cam/realmonitor?channel=1&subtype=0
        # Required: list of roles for this stream. valid values are: detect,record,rtmp
        roles:
          - detect
          - rtmp
          - record

  detect:
    width: 1920
    height: 1080
    fps: 5
    enabled: True

  record:
    events:
      required_zones:
        - street_driveway
        - main_driveway

  snapshots:
    required_zones:
      - street_driveway
      - main_driveway

  zones:
    street_driveway:
      coordinates: 1846,759,1812,842,1370,681,1475,637
      objects:
        - person
        - car
    main_driveway:
      coordinates: 1463,1080,1173,931,1065,586,1831,873,1744,1080
      objects:
        - person
        # - car

  motion:
    mask:
      - 1005,606,1177,832,476,1080,397,768
      - 1920,0,1920,739,933,490,683,0
      - 0,246,228,248,261,726,0,782

backyard_cam:
  objects:
    track:
      - person
      - cat
      - dog
      - bear
      - mouse
  ffmpeg:
    inputs:
      - path: rtsp://REDACTED:REDACTED@192.168.141.17:554/cam/realmonitor?channel=1&subtype=0
        # Required: list of roles for this stream. valid values are: detect,record,rtmp
        roles:
          - detect
          - rtmp
          - record

  detect:
    width: 1920
    height: 1080
    fps: 5
    enabled: True

  motion:
    mask:
      - 1152,399,1920,414,1920,337,1920,0,809,0,0,0,0,546

Relevant log output

frigate    | 2021-12-23T20:03:51.105693843Z [2021-12-23 15:03:51] watchdog.backyard_cam          ERROR   : FFMPEG process crashed unexpectedly for backyard_cam.
frigate    | 2021-12-23T20:03:51.105772786Z [2021-12-23 15:03:51] watchdog.backyard_cam          ERROR   : The following ffmpeg logs include the last 100 lines prior to exit.
frigate    | 2021-12-23T20:03:51.105878118Z [2021-12-23 15:03:51] watchdog.backyard_cam          ERROR   : You may have invalid args defined for this camera.
frigate    | 2021-12-23T20:03:51.106029561Z [2021-12-23 15:03:51] ffmpeg.backyard_cam.detect     ERROR   : [segment @ 0x560c869d9300] Timestamps are unset in a packet for stream 0. This is deprecated and will stop working in the future. Fix your code to set the timestamps properly
frigate    | 2021-12-23T20:03:51.106133433Z [2021-12-23 15:03:51] ffmpeg.backyard_cam.detect     ERROR   : [flv @ 0x560c869d7e80] Timestamps are unset in a packet for stream 0. This is deprecated and will stop working in the future. Fix your code to set the timestamps properly
frigate    | 2021-12-23T20:03:51.106238673Z [2021-12-23 15:03:51] ffmpeg.backyard_cam.detect     ERROR   : [segment @ 0x560c869d9300] Non-monotonous DTS in output stream 0:0; previous: 0, current: 0; changing to 1. This may result in incorrect timestamps in the output file.
frigate    | 2021-12-23T20:03:51.106309936Z [2021-12-23 15:03:51] ffmpeg.backyard_cam.detect     ERROR   : av_interleaved_write_frame(): Connection reset by peer
frigate    | 2021-12-23T20:03:51.106416008Z [2021-12-23 15:03:51] ffmpeg.backyard_cam.detect     ERROR   : [flv @ 0x560c869d7e80] Failed to update header with correct duration.
frigate    | 2021-12-23T20:03:51.106518541Z [2021-12-23 15:03:51] ffmpeg.backyard_cam.detect     ERROR   : [flv @ 0x560c869d7e80] Failed to update header with correct filesize.
frigate    | 2021-12-23T20:03:51.106620271Z [2021-12-23 15:03:51] ffmpeg.backyard_cam.detect     ERROR   : Error writing trailer of rtmp://127.0.0.1/live/backyard_cam: Connection reset by peer
frigate    | 2021-12-23T20:07:29.770297226Z [2021-12-23 15:07:29] frigate.video                  INFO    : backyard_cam: ffmpeg sent a broken frame. memoryview assignment: lvalue and rvalue have different structures
frigate    | 2021-12-23T20:07:29.770387768Z [2021-12-23 15:07:29] frigate.video                  INFO    : backyard_cam: ffmpeg process is not running. exiting capture thread...
frigate    | 2021-12-23T20:07:31.114077309Z [2021-12-23 15:07:31] watchdog.backyard_cam          ERROR   : FFMPEG process crashed unexpectedly for backyard_cam.
frigate    | 2021-12-23T20:07:31.114338675Z [2021-12-23 15:07:31] watchdog.backyard_cam          ERROR   : The following ffmpeg logs include the last 100 lines prior to exit.
frigate    | 2021-12-23T20:07:31.114352912Z [2021-12-23 15:07:31] watchdog.backyard_cam          ERROR   : You may have invalid args defined for this camera.
frigate    | 2021-12-23T20:07:31.114356751Z [2021-12-23 15:07:31] ffmpeg.backyard_cam.detect     ERROR   : [segment @ 0x559d626eee40] Timestamps are unset in a packet for stream 0. This is deprecated and will stop working in the future. Fix your code to set the timestamps properly
frigate    | 2021-12-23T20:07:31.114359856Z [2021-12-23 15:07:31] ffmpeg.backyard_cam.detect     ERROR   : [flv @ 0x559d6270b300] Timestamps are unset in a packet for stream 0. This is deprecated and will stop working in the future. Fix your code to set the timestamps properly
frigate    | 2021-12-23T20:07:31.114362789Z [2021-12-23 15:07:31] ffmpeg.backyard_cam.detect     ERROR   : [segment @ 0x559d626eee40] Non-monotonous DTS in output stream 0:0; previous: 0, current: 0; changing to 1. This may result in incorrect timestamps in the output file.
frigate    | 2021-12-23T20:07:31.114365876Z [2021-12-23 15:07:31] ffmpeg.backyard_cam.detect     ERROR   : av_interleaved_write_frame(): Connection reset by peer
frigate    | 2021-12-23T20:07:31.114376035Z [2021-12-23 15:07:31] ffmpeg.backyard_cam.detect     ERROR   : [flv @ 0x559d6270b300] Failed to update header with correct duration.
frigate    | 2021-12-23T20:07:31.114421627Z [2021-12-23 15:07:31] ffmpeg.backyard_cam.detect     ERROR   : [flv @ 0x559d6270b300] Failed to update header with correct filesize.
frigate    | 2021-12-23T20:07:31.114443882Z [2021-12-23 15:07:31] ffmpeg.backyard_cam.detect     ERROR   : Error writing trailer of rtmp://127.0.0.1/live/backyard_cam: Connection reset by peer
frigate    | 2021-12-23T20:08:17.749925632Z [2021-12-23 15:08:17] frigate.video                  INFO    : backyard_cam: ffmpeg sent a broken frame. memoryview assignment: lvalue and rvalue have different structures
frigate    | 2021-12-23T20:08:17.750381765Z [2021-12-23 15:08:17] frigate.video                  INFO    : backyard_cam: ffmpeg process is not running. exiting capture thread...
frigate    | 2021-12-23T20:08:21.127490964Z [2021-12-23 15:08:21] watchdog.backyard_cam          ERROR   : FFMPEG process crashed unexpectedly for backyard_cam.
frigate    | 2021-12-23T20:08:21.127535289Z [2021-12-23 15:08:21] watchdog.backyard_cam          ERROR   : The following ffmpeg logs include the last 100 lines prior to exit.
frigate    | 2021-12-23T20:08:21.127625450Z [2021-12-23 15:08:21] watchdog.backyard_cam          ERROR   : You may have invalid args defined for this camera.
frigate    | 2021-12-23T20:08:21.127722978Z [2021-12-23 15:08:21] ffmpeg.backyard_cam.detect     ERROR   : [segment @ 0x55c16b11ed80] Timestamps are unset in a packet for stream 0. This is deprecated and will stop working in the future. Fix your code to set the timestamps properly
frigate    | 2021-12-23T20:08:21.127805634Z [2021-12-23 15:08:21] ffmpeg.backyard_cam.detect     ERROR   : [flv @ 0x55c16b123300] Timestamps are unset in a packet for stream 0. This is deprecated and will stop working in the future. Fix your code to set the timestamps properly
frigate    | 2021-12-23T20:08:21.127859443Z [2021-12-23 15:08:21] ffmpeg.backyard_cam.detect     ERROR   : [segment @ 0x55c16b11ed80] Non-monotonous DTS in output stream 0:0; previous: 0, current: 0; changing to 1. This may result in incorrect timestamps in the output file.
frigate    | 2021-12-23T20:08:21.127955580Z [2021-12-23 15:08:21] ffmpeg.backyard_cam.detect     ERROR   : av_interleaved_write_frame(): Connection reset by peer
frigate    | 2021-12-23T20:08:21.128007369Z [2021-12-23 15:08:21] ffmpeg.backyard_cam.detect     ERROR   : [flv @ 0x55c16b123300] Failed to update header with correct duration.
frigate    | 2021-12-23T20:08:21.128084187Z [2021-12-23 15:08:21] ffmpeg.backyard_cam.detect     ERROR   : [flv @ 0x55c16b123300] Failed to update header with correct filesize.
frigate    | 2021-12-23T20:08:21.128156990Z [2021-12-23 15:08:21] ffmpeg.backyard_cam.detect     ERROR   : Error writing trailer of rtmp://127.0.0.1/live/backyard_cam: Connection reset by peer
frigate    | 2021-12-23T20:08:23.803042223Z [2021-12-23 15:08:23] frigate.video                  INFO    : backyard_cam: ffmpeg sent a broken frame. memoryview assignment: lvalue and rvalue have different structures
frigate    | 2021-12-23T20:08:23.803156890Z [2021-12-23 15:08:23] frigate.video                  INFO    : backyard_cam: ffmpeg process is not running. exiting capture thread...
frigate    | 2021-12-23T20:08:31.135131987Z [2021-12-23 15:08:31] watchdog.backyard_cam          ERROR   : FFMPEG process crashed unexpectedly for backyard_cam.
frigate    | 2021-12-23T20:08:31.135217928Z [2021-12-23 15:08:31] watchdog.backyard_cam          ERROR   : The following ffmpeg logs include the last 100 lines prior to exit.
frigate    | 2021-12-23T20:08:31.135308059Z [2021-12-23 15:08:31] watchdog.backyard_cam          ERROR   : You may have invalid args defined for this camera.
frigate    | 2021-12-23T20:08:31.135382737Z [2021-12-23 15:08:31] ffmpeg.backyard_cam.detect     ERROR   : [segment @ 0x560fa5abc8c0] Timestamps are unset in a packet for stream 0. This is deprecated and will stop working in the future. Fix your code to set the timestamps properly
frigate    | 2021-12-23T20:08:31.135466928Z [2021-12-23 15:08:31] ffmpeg.backyard_cam.detect     ERROR   : [flv @ 0x560fa5aba4c0] Timestamps are unset in a packet for stream 0. This is deprecated and will stop working in the future. Fix your code to set the timestamps properly
frigate    | 2021-12-23T20:08:31.135544883Z [2021-12-23 15:08:31] ffmpeg.backyard_cam.detect     ERROR   : [segment @ 0x560fa5abc8c0] Non-monotonous DTS in output stream 0:0; previous: 0, current: 0; changing to 1. This may result in incorrect timestamps in the output file.
frigate    | 2021-12-23T20:08:31.135622342Z [2021-12-23 15:08:31] ffmpeg.backyard_cam.detect     ERROR   : av_interleaved_write_frame(): Connection reset by peer
frigate    | 2021-12-23T20:08:31.135692324Z [2021-12-23 15:08:31] ffmpeg.backyard_cam.detect     ERROR   : [flv @ 0x560fa5aba4c0] Failed to update header with correct duration.
frigate    | 2021-12-23T20:08:31.135774670Z [2021-12-23 15:08:31] ffmpeg.backyard_cam.detect     ERROR   : [flv @ 0x560fa5aba4c0] Failed to update header with correct filesize.
frigate    | 2021-12-23T20:08:31.135841868Z [2021-12-23 15:08:31] ffmpeg.backyard_cam.detect     ERROR   : Error writing trailer of rtmp://127.0.0.1/live/backyard_cam: Connection reset by peer

FFprobe output from your camera

Not sure?

Frigate stats

No response

Operating system

Debian

Install method

Docker Compose

Coral version

CPU (no coral)

Network connection

Wired

Camera make and model

Amcrest IP8M-2496

Any other information that may be helpful

No response

lee-costa commented 2 years ago

Closing and reopening with more information.