Re: [mistserver] Write to FTP

10 views
Skip to first unread message

Balder Vietor

unread,
Jul 2, 2025, 6:55:41 AMJul 2
to mists...@googlegroups.com
Hey Bart,

You're close, but at the wrong place to set this up.
Instead of using a stream process you'll want to set this up as an "Automatic push". 
Automatic pushes are meant to start when a stream comes online and if no start/end is given stay active for as long as the stream is active.
Stream processes are meant to ingest back whatever the process is starting as Matroska and then add this to the stream. So MistServer is not doing anything there as it's ingesting the log messages of FFmpeg and determining this is not video.

At the Push panel to the left, create an automatic push:
image.png

mkv-exec will work in a similar fashion as the stream process version of mkv-exec. It will send Matroska stream data to the standard in of whatever application is launched right after the :. So you'll most likely want to use the following push target:

mkv-exec:ffmpeg -loglevel quiet -hide_banner -fflags nobuffer -i - -c:v mpeg2video -b:v 50M -minrate 50M -maxrate 50M -bufsize 1M -c:a pcm_s16le -ar 48000 -ac 2 -f mxf ftp://IPADDRESS/output.mxf

Note that there's currently an issue that bash-styled argument quoting isn't implemented. This will be in the upcoming release and development builds already support it. This roughly means that if you're using a ' or " it will fail unless you use a script that then runs the command. You'd have to do:
mkv-exec:/path/to/script
in that case.

Best,

Balder Vietor | Supreme tester



On Tue, Jul 1, 2025 at 9:12 PM Bart Jenn <bart.je...@gmail.com> wrote:
Hi All,

For live broadcasting I would like to write the incoming stream to an FTP endpoint as an MXF file. (The editor can import the MXF into the video timeline and do live editing while de video file grows as long as the livestream is running.) 

For this I can use FFMPEG:

ffmpeg -loglevel quiet -hide_banner -fflags nobuffer -i 'https://IPADDRESS/stream.webm' -c:v mpeg2video -b:v 50M -minrate 50M -maxrate 50M -bufsize 1M -c:a pcm_s16le -ar 48000 -ac 2 -f mxf 'ftp://IPADDRESS/output.mxf'

When I run the above ffmpeg command on the command line of the MistServer, ffmpeg runs perfectly and the output is written to the FTP server. 

I've tried to run this ffmpeg command as executable parameter within Stream process but it doesn't want to run and no output stream is created because the goal is to automate this with the stream:

ffmpeg -loglevel quiet -hide_banner -fflags nobuffer -i - -c:v mpeg2video -b:v 50M -minrate 50M -maxrate 50M -bufsize 1M -c:a pcm_s16le -ar 48000 -ac 2 -f mxf 'ftp://IPADDRESS/output.mxf'
Schermafbeelding 2025-07-01 205928.png
I'm probably not following the correct implementation for Matroska. 

What is the correct way to kick-off this ffmpeg code when the stream starts?

Thank you in advanced!
Regards,
Bart 

--
You received this message because you are subscribed to the Google Groups "Mistserver.org" group.
To unsubscribe from this group and stop receiving emails from it, send an email to mistserver+...@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/mistserver/18612ba7-ccd8-4f76-a64b-b3d900e90e7cn%40googlegroups.com.
Reply all
Reply to author
Forward
0 new messages