Skip to content

OpenCV Error on startup #231

@markdegrootnl

Description

@markdegrootnl

Affected Version
v3.3.7.0

Describe the bug
When running the docker container and restarting the host platform, the container fails to start with the following error:

agentdvr    | Unhandled exception. Emgu.CV.Util.CvException: OpenCV: key_ != -1 && "Can't fetch data from terminated TLS container."
agentdvr    |    at Emgu.CV.CvInvoke.CvErrorHandler(Int32 status, IntPtr funcName, IntPtr errMsg, IntPtr fileName, Int32 line, IntPtr userData)
agentdvr    |    at Emgu.CV.CvInvoke.cveResize(IntPtr src, IntPtr dst, Size& dsize, Double fx, Double fy, Inter interpolation)
agentdvr    |    at Emgu.CV.CvInvoke.Resize(IInputArray src, IOutputArray dst, Size dsize, Double fx, Double fy, Inter interpolation)
agentdvr    |    at CoreLogic.Compositors.Compositor.FillFrame(Mat frame, Rectangle rectObj, Rectangle containerRect, IAgentControl control, String message, Boolean modified)
agentdvr    |    at CoreLogic.Compositors.Compositor._NewFramePostProcessHandler(Object sender, NewFrameEventArgs e)
agentdvr    | Fatal error. Internal CLR error. (0x80131506)
agentdvr    |    at Emgu.CV.CvInvoke.cveResize(IntPtr, IntPtr, System.Drawing.Size ByRef, Double, Double, Emgu.CV.CvEnum.Inter)
agentdvr    |    at Emgu.CV.CvInvoke.cveResize(IntPtr, IntPtr, System.Drawing.Size ByRef, Double, Double, Emgu.CV.CvEnum.Inter)
agentdvr    |    at Emgu.CV.CvInvoke.Resize(Emgu.CV.IInputArray, Emgu.CV.IOutputArray, System.Drawing.Size, Double, Double, Emgu.CV.CvEnum.Inter)
agentdvr    |    at CoreLogic.Compositors.Compositor.FillFrame(Emgu.CV.Mat, System.Drawing.Rectangle, System.Drawing.Rectangle, CoreLogic.Objects.IAgentControl, System.String, Boolean)
agentdvr    |    at CoreLogic.Compositors.Compositor._NewFramePostProcessHandler(System.Object, CoreLogic.Sources.NewFrameEventArgs)
agentdvr    |    at CoreLogic.Objects.Camera.VideoSourceNewFrame(System.Object, CoreLogic.Sources.NewFrameEventArgs)
agentdvr    |    at CoreLogic.Sources.Combined.MediaStream.ReadFrames()
agentdvr    |    at System.Threading.ThreadHelper.ThreadStart_Context(System.Object)
agentdvr    |    at System.Threading.ExecutionContext.RunInternal(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object)
agentdvr    |    at System.Threading.ThreadHelper.ThreadStart()
agentdvr exited with code 143

Steps To Reproduce
Steps to reproduce the behavior:

  1. Start the container
  2. Reboot the host os

Expected behavior
Should start up

Reproduction rate
100%

Screenshots
N/a

Host System Information (where ispy agent is running/hosted):

  • OS: Ubuntu 20.04.1 LTS

Client System Information (device accessing the web portal, if applicable):
N/A

Additional Information
docker-compose file:

version: '3'

services:
  agentdvr:
    image: doitandbedone/ispyagentdvr:latest
    container_name: agentdvr
    volumes:
      - /storage/config/:/agent/Media/XML/
      - /storage/media/:/agent/Media/WebServerRoot/Media/
      - /storage/commands:/agent/Commands/
    ports:
      - "80:8090"
      - "3478:3478/udp"
      - "50000-50010:50000-50010/udp"

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions