bluenviron / mediamtx

Ready-to-use SRT / WebRTC / RTSP / RTMP / LL-HLS media server and media proxy that allows to read, publish, proxy, record and playback video and audio streams.
MIT License
11.41k stars 1.45k forks source link

configuration file not found, using an empty configuration #1788

Closed Ninja-Spotted closed 1 year ago

Ninja-Spotted commented 1 year ago

Which version are you using?

v0.22.2

Which operating system are you using?

Describe the issue

After I extracted the mediamtx_v0.22.2_linux_amd64.tar.gz in my Download folder, running the executable with ./mediamtx_v0.22.2_linux_amd64/mediamtx shows me the following message in the Logs:

    2023/05/11 13:10:14 INF MediaMTX / rtsp-simple-server v0.22.2
    2023/05/11 13:10:14 WAR configuration file not found, using an empty configuration
    2023/05/11 13:10:14 INF [RTSP] listener opened on :8554 (TCP), :8000 (UDP/RTP), :8001 (UDP/RTCP)
    2023/05/11 13:10:14 INF [RTMP] listener opened on :1935
    2023/05/11 13:10:14 INF [HLS] listener opened on :8888
    2023/05/11 13:10:14 INF [WebRTC] listener opened on :8889 (HTTP)

Not finding the configuration file. After starting the stream some more messages appeared:

    2023/05/11 13:34:32 INF [RTSP] [conn 192.168.30.232:54176] opened
    2023/05/11 13:34:32 INF [RTSP] [conn 192.168.30.232:54176] closed (path 'mystream' is not configured)

The weird aspect is that this issue only showed up today. I have been running mediamtx for about 2 weeks before and never had this problem starting the streaming.

Describe how to replicate the issue

  1. start the server
  2. start the stream with ffmpeg: ffmpeg -f v4l2 -i /dev/video0 -profile:v high -pix_fmt yuvj420p -level:v 4.1 -preset ultrafast -tune zerolatency -vcodec libx264 -r 10 -b:v 512k -s 1920x1080 -strict -2 -ac 2 -ab 32k -ar 44100 -f mpegts -f rtsp -rtsp_transport tcp rtsp://192.168.30.232:8554/mystream (the command I have been using)
  3. Check the configuration file located in ./mediamtx_v0.22.2_linux_amd64/mediamtx.yml after searching on the internet for a solution I tried to edit the end of the file where paths are specified and left only:

    paths:
        mystream:
            source: Camera

Did you attach the server logs?

no

Did you attach a network dump?

no

Tokolosh commented 1 year ago

try going into the folder where you have mediamtx and mediamtx.yml

example: cd /path/to/mediamtx_v0.22.2_linux_amd64 ./mediamtx

or follow the instructions to add it as a service that will auto start on boot... https://github.com/bluenviron/mediamtx#linux

Ninja-Spotted commented 1 year ago

Thank you so much! This resolved the issue I was having.

github-actions[bot] commented 9 months ago

This issue is being locked automatically because it has been closed for more than 6 months. Please open a new issue in case you encounter a similar problem.