Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

recordDeleteAfter parameter not being applied correctly #3557

Closed
1 of 13 tasks
anktx opened this issue Jul 16, 2024 · 2 comments · Fixed by #3741
Closed
1 of 13 tasks

recordDeleteAfter parameter not being applied correctly #3557

anktx opened this issue Jul 16, 2024 · 2 comments · Fixed by #3741
Labels
bug Something isn't working record playback

Comments

@anktx
Copy link

anktx commented Jul 16, 2024

Which version are you using?

v1.8.4

Which operating system are you using?

  • Linux amd64 standard
  • Linux amd64 Docker
  • Linux arm64 standard
  • Linux arm64 Docker
  • Linux arm7 standard
  • Linux arm7 Docker
  • Linux arm6 standard
  • Linux arm6 Docker
  • Windows amd64 standard
  • Windows amd64 Docker (WSL backend)
  • macOS amd64 standard
  • macOS amd64 Docker
  • Other (please describe)

Describe the issue

Hi Team,

I am experiencing an issue with the recordDeleteAfter parameter in the MediaMTX configuration file. Despite setting a specific value for a path, the recordings are still being deleted based on the default value.

Here is my configuration file:

pathDefaults:
  record: no
  recordSegmentDuration: 1h
  recordDeleteAfter: 168h

paths:
  office:
    source: rtsp://go2rtc:8554/office-main
    recordDeleteAfter: 336h

  office-sub:
    source: rtsp://go2rtc:8554/office-sub
    record: yes

In this configuration, I expect the recordings for the office path to be stored for 336 hours and the recordings for the office-sub path to be stored for 168 hours. However, both paths seem to follow the default recordDeleteAfter value of 168 hours.

Additionally, I enable recording for the office path via the API.

Could you please help me understand why the recordDeleteAfter parameter is not being applied correctly for the office path? Is there something wrong with my configuration, or could this be a bug?

Thank you for your assistance.

Describe how to replicate the issue

Steps to reproduce the issue:

  1. Start the MediaMTX server with the provided configuration file.
  2. Observe the recordings for both office and office-sub paths.
  3. Verify the duration of stored recordings for both paths after 168 hours.

Expected Result:

Recordings for the office path should be stored for 336 hours.
Recordings for the office-sub path should be stored for 168 hours.

Actual Result:

Both paths follow the default recordDeleteAfter value of 168 hours.

Did you attach the server logs?

no

Did you attach a network dump?

no

@aler9
Copy link
Member

aler9 commented Sep 5, 2024

Thanks for reporting the bug, it seems like the server is deleting recording segments by considering just recordPath, without checking whether the segment belongs to the path associated with that specific recordPath.

This is fixed by #3741

Copy link
Contributor

This issue is mentioned in release v1.9.1 🚀
Check out the entire changelog by clicking here

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working record playback
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants