Open zhongzilu opened 1 week ago
上述问题是查询并播放 2024-06-07 00:00:00
到 2024-06-08 00:00:00
期间的录像文件出现的
接下来的是查询并播放 2024-06-06 00:00:00
到 2024-06-07 00:00:00
期间的录像文件
这一天的录像文件数量只有8个,但连续播放到第2个文件结束的时间点时,画面就卡住了,通过 /gb28181/api/records
API 获取到的录像列表如下:
[
{
"DeviceID": "34020000001320000001",
"Name": "Camera 01",
"FilePath": "file_path",
"Address": "Address 1",
"StartTime": "2024-06-06T09:21:26",
"EndTime": "2024-06-06T09:21:41",
"Secrecy": 0,
"Type": "alarm"
},
{
"DeviceID": "34020000001320000001",
"Name": "Camera 01",
"FilePath": "file_path",
"Address": "Address 1",
"StartTime": "2024-06-06T09:22:13",
"EndTime": "2024-06-06T09:22:31",
"Secrecy": 0,
"Type": "alarm"
},
{
"DeviceID": "34020000001320000001",
"Name": "Camera 01",
"FilePath": "file_path",
"Address": "Address 1",
"StartTime": "2024-06-06T09:27:08",
"EndTime": "2024-06-06T09:27:27",
"Secrecy": 0,
"Type": "alarm"
},
{
"DeviceID": "34020000001320000001",
"Name": "Camera 01",
"FilePath": "file_path",
"Address": "Address 1",
"StartTime": "2024-06-06T09:28:07",
"EndTime": "2024-06-06T09:28:21",
"Secrecy": 0,
"Type": "alarm"
},
// 省略...
]
通过海康摄像头管理后台查看录像文件如下图:
查看日志发现并没有出现上述问题的情况,而是 timeout
问题,具体日志如下:
16:05:35.174+0800 INFO GB28181 RecoverDevice {"id": "34020000001320000001", "deviceIp": "192.168.50.203:5060", "servIp": "3402000000", "sipIP": "192.168.50.66", "mediaIp": "192.168.50.66"}
16:06:12.184+0800 INFO GB28181 QueryDeviceInfo {"id": "34020000001320000001", "status code": 200}
16:14:17.654+0800 INFO GB28181 invite response {"id": "34020000001320000001", "channel": "34020000001320000001", "status code": 200}
16:14:17.654+0800 INFO created {"stream": "34020000001320000001/34020000001320000001/1717603200-1717689600", "id": 5}
16:14:17.654+0800 INFO publish {"stream": "34020000001320000001/34020000001320000001/1717603200-1717689600", "id": 5, "type": "PSPublisher", "ptr": "0xc000d62a08"}
16:14:17.654+0800 INFO ⌛->🟡 {"stream": "34020000001320000001/34020000001320000001/1717603200-1717689600", "id": 5, "action": "publish"}
16:14:17.654+0800 INFO tcp listen 1 at :58200
16:14:17.659+0800 INFO start receive ps stream from {"stream": "34020000001320000001/34020000001320000001/1717603200-1717689600", "id": 5, "type": "PSPublisher", "tcp": "192.168.50.66:58200"}
16:14:17.943+0800 INFO attach video track {"stream": "34020000001320000001/34020000001320000001/1717603200-1717689600", "id": 5, "type": "PSPublisher", "track": "h264", "width": 1280, "height": 720}
16:14:17.943+0800 INFO video track attached {"stream": "34020000001320000001/34020000001320000001/1717603200-1717689600", "id": 5, "type": "PSPublisher", "track": "h264", "width": 1280, "height": 720}
16:14:17.943+0800 INFO 🟡->🟢 {"stream": "34020000001320000001/34020000001320000001/1717603200-1717689600", "id": 5, "action": "track available"}
16:14:17.944+0800 INFO audio track attached {"stream": "34020000001320000001/34020000001320000001/1717603200-1717689600", "id": 5, "type": "PSPublisher", "track": "pcma", "sample rate": 8000}
16:14:23.556+0800 INFO subscribe {"stream": "34020000001320000001/34020000001320000001/1717603200-1717689600", "id": 5, "type": "WebRTCSubscriber", "ID": "824647586688"}
16:14:23.557+0800 INFO suber +1 {"stream": "34020000001320000001/34020000001320000001/1717603200-1717689600", "id": 5, "type": "WebRTCSubscriber", "ID": "824647586688", "remains": 1}
16:14:23.557+0800 INFO track+1 {"stream": "34020000001320000001/34020000001320000001/1717603200-1717689600", "id": 5, "type": "WebRTCSubscriber", "ID": "824647586688", "name": "h264"}
16:14:23.557+0800 INFO track+1 {"stream": "34020000001320000001/34020000001320000001/1717603200-1717689600", "id": 5, "type": "WebRTCSubscriber", "ID": "824647586688", "name": "pcma"}
16:14:23.557+0800 INFO candidate:2111806186 1 tcp 1671430143 192.168.50.66 9000 typ host tcptype passive {"stream": "34020000001320000001/34020000001320000001/1717603200-1717689600", "id": 5, "type": "WebRTCSubscriber", "ID": "824647586688"}
16:14:23.557+0800 INFO candidate:2027898665 1 tcp 1671430143 172.19.0.1 9000 typ host tcptype passive {"stream": "34020000001320000001/34020000001320000001/1717603200-1717689600", "id": 5, "type": "WebRTCSubscriber", "ID": "824647586688"}
16:14:23.558+0800 INFO candidate:2954730683 1 tcp 1671430143 172.17.0.1 9000 typ host tcptype passive {"stream": "34020000001320000001/34020000001320000001/1717603200-1717689600", "id": 5, "type": "WebRTCSubscriber", "ID": "824647586688"}
16:14:23.558+0800 INFO candidate:1873040234 1 tcp 1671430143 172.18.0.1 9000 typ host tcptype passive {"stream": "34020000001320000001/34020000001320000001/1717603200-1717689600", "id": 5, "type": "WebRTCSubscriber", "ID": "824647586688"}
16:14:23.574+0800 INFO Connection State has changed:connected {"stream": "34020000001320000001/34020000001320000001/1717603200-1717689600", "id": 5, "type": "WebRTCSubscriber", "ID": "824647586688"}
16:14:23.574+0800 INFO playblock {"stream": "34020000001320000001/34020000001320000001/1717603200-1717689600", "id": 5, "type": "WebRTCSubscriber", "ID": "824647586688", "subType": 1}
16:14:23.574+0800 INFO start read {"stream": "34020000001320000001/34020000001320000001/1717603200-1717689600", "id": 5, "type": "WebRTCSubscriber", "ID": "824647586688", "track": "h264", "mode": 0}
16:14:23.574+0800 INFO first frame read {"stream": "34020000001320000001/34020000001320000001/1717603200-1717689600", "id": 5, "type": "WebRTCSubscriber", "ID": "824647586688", "track": "h264", "firstTs": "5.320829685s", "firstSeq": 123}
16:14:23.614+0800 INFO start read {"stream": "34020000001320000001/34020000001320000001/1717603200-1717689600", "id": 5, "type": "WebRTCSubscriber", "ID": "824647586688", "track": "pcma", "mode": 0}
16:14:23.614+0800 INFO first frame read {"stream": "34020000001320000001/34020000001320000001/1717603200-1717689600", "id": 5, "type": "WebRTCSubscriber", "ID": "824647586688", "track": "pcma", "firstTs": "5.320829685s", "firstSeq": 122}
16:14:24.824+0800 INFO jump {"stream": "34020000001320000001/34020000001320000001/1717603200-1717689600", "id": 5, "type": "WebRTCSubscriber", "ID": "824647586688", "track": "h264", "skipSeq": 49, "skipTs": "6.108829685s"}
16:14:24.972+0800 INFO jump {"stream": "34020000001320000001/34020000001320000001/1717603200-1717689600", "id": 5, "type": "WebRTCSubscriber", "ID": "824647586688", "track": "pcma", "skipSeq": 48, "skipTs": "6.030829685s"}
16:14:32.988+0800 WARN track dts reset {"stream": "34020000001320000001/34020000001320000001/1717603200-1717689600", "id": 5, "type": "PSPublisher", "track": "h264", "delta1": 2882430, "delta2": 2882430}
16:14:32.988+0800 WARN track dts reset {"stream": "34020000001320000001/34020000001320000001/1717603200-1717689600", "id": 5, "type": "PSPublisher", "track": "pcma", "delta1": 2883600, "delta2": 2883600}
16:14:51.282+0800 WARN track dts reset {"stream": "34020000001320000001/34020000001320000001/1717603200-1717689600", "id": 5, "type": "PSPublisher", "track": "h264", "delta1": 24906510, "delta2": 27788940}
16:15:02.956+0800 WARN track timeout {"stream": "34020000001320000001/34020000001320000001/1717603200-1717689600", "id": 5, "name": "pcma", "last writetime": "16:14:50.969+0800", "timeout": "10s"}
16:15:02.956+0800 INFO 🟢->⌛ {"stream": "34020000001320000001/34020000001320000001/1717603200-1717689600", "id": 5, "action": "timeout"}
16:15:02.973+0800 INFO track back online {"stream": "34020000001320000001/34020000001320000001/1717603200-1717689600", "id": 5, "type": "PSPublisher", "track": "h264", "delta": "27.79254ms"}
16:15:10.533+0800 WARN track dts reset {"stream": "34020000001320000001/34020000001320000001/1717603200-1717689600", "id": 5, "type": "PSPublisher", "track": "h264", "delta1": 3601170, "delta2": 31393710}
16:15:12.957+0800 INFO ⌛->🔴 {"stream": "34020000001320000001/34020000001320000001/1717603200-1717689600", "id": 5, "action": "timeout"}
16:15:12.957+0800 INFO close {"stream": "34020000001320000001/34020000001320000001/1717603200-1717689600", "id": 5, "type": "WebRTCSubscriber", "ID": "824647586688", "event": "close"}
16:15:12.957+0800 INFO close {"stream": "34020000001320000001/34020000001320000001/1717603200-1717689600", "id": 5, "type": "PSPublisher", "event": "close"}
16:15:12.957+0800 WARN rtcp read error {"stream": "34020000001320000001/34020000001320000001/1717603200-1717689600", "id": 5, "type": "WebRTCSubscriber", "ID": "824647586688", "error": "EOF"}
16:15:12.958+0800 INFO Connection State has changed:closed {"stream": "34020000001320000001/34020000001320000001/1717603200-1717689600", "id": 5, "type": "WebRTCSubscriber", "ID": "824647586688"}
16:15:12.958+0800 INFO stop receive ps stream from {"stream": "34020000001320000001/34020000001320000001/1717603200-1717689600", "id": 5, "type": "PSPublisher", "tcp": "192.168.50.66:58200"}
应该是录像流出现了异常
我也不太确定,通过海康摄像头管理后台进行录像回放,以及把录像文件下载下来播放似乎都没什么问题
你用最新版本试试呢
在预览播放历史录像文件时出现的该问题。
摄像头品牌是海康,Monibuca 使用的是 Linux 平台, docker 部署,GB28181的版本号为
"v4.4.5-0.20240521112210-a207352fe6e4
,使用的配置是在默认配置的基础上,只修改了invitemode
属性值为0
操作流程:
/gb28181/api/records
API接口查询到了录像文件,返回有36条记录/gb28181/api/invite
API 加上startTime
和endTime
进行拉流/preview/
进行在线预览播放录像文件,type
为webrtc
一开始播放很正常,直到连续播放到大约第20个录像文件的中途时,画面不动了,通过海康摄像头管理后台查看录像文件列表如下图所示:![图片](https://github.com/Monibuca/plugin-gb28181/assets/4704240/5e9e3a86-2ed2-4cc0-a293-d5e23ef76d9f)
查看 Monibuca 容器日志输出大致如下:
以上日志中存在1个
ERROR
等级错误,请作者帮忙查看一下