EdgeRouter 4 Install msd_lite / msd



Deprecated, but recommended!!! You can also use Multi Stream daemon (msd)


1 Clone code on computer, because my ER-4 reports dpkg errors, due to the outdated debian stretch. Then upload to ER-4

git clone --recursive https://github.com/rozhuk-im/msd_lite.git
tar zcvf msd_lite.tar.gz msd_lite
scp msd_lite.tar.gz ubnt@

2 On ER-4, install build-essential, cmake

For build-essential, read EdgeRouter 4 Build & Install udpxy

# apt install cmake
Reading package lists... Done
Building dependency tree       
Reading state information... Done
You might want to run 'apt --fix-broken install' to correct these.
The following packages have unmet dependencies:
 cmake : Depends: cmake-data (= 3.7.2-1) but it is not going to be installed
         Depends: libarchive13 (>= 3.0.4) but it is not going to be installed
         Depends: libjsoncpp1 (>= 1.7.4) but it is not going to be installed
         Depends: libuv1 (>= 1.4.2) but it is not going to be installed
 dpkg-dev : Depends: xz-utils but it is not going to be installed
E: Unmet dependencies. Try 'apt --fix-broken install' with no packages (or specify a solution).

# apt install cmake cmake-data  libarchive13 libjsoncpp1 libuv1 

3 build on ER-4

tar xvf /tmp/msd_lite.tar.gz
cd msd_lite
mkdir build
cd build
cmake ..
make install

4 configure and run


<?xml version="1.0" encoding="utf-8"?>

 Sizes in kb, time in seconds

<skt> <rcvLoWatermark>XXXX</rcvLoWatermark> - DOES NOT WORK on Linux!
man socket(7):
The select(2) and poll(2) system calls currently do not respect the SO_RCVLOWAT
setting on Linux, and mark a socket readable when even a single byte of data is


		<threadsCountMax>1</threadsCountMax> <!-- 0 = auto -->
		<fBindToCPU>yes</fBindToCPU> <!-- Bind threads to CPUs. -->
		<fCacheGetTimeSyscall>yes</fCacheGetTimeSyscall> <!-- Cache gettime() syscalls.. -->
		<timerGranularity>100</timerGranularity> <!-- 1/1000 sec -->

<!-- HTTP server -->

		<hostnameList> <!-- Host names for all bindings. -->

	<hubProfileList> <!-- Stream hub profiles templates. -->
			<fDropSlowClients>no</fDropSlowClients> <!-- Disconnect slow clients. -->
			<fSocketHalfClosed>no</fSocketHalfClosed> <!-- Enable shutdown(SHUT_RD) for clients. -->
			<fSocketTCPNoDelay>yes</fSocketTCPNoDelay> <!-- Enable TCP_NODELAY for clients. -->
			<fSocketTCPNoPush>yes</fSocketTCPNoPush> <!-- Enable TCP_NOPUSH / TCP_CORK for clients. -->
			<precache>4096</precache> <!-- Pre cache size. Can be overwritten by arg from user request. -->
			<ringBufSize>1024</ringBufSize> <!-- Stream receive ring buffer size. Must be multiple of sndBlockSize. -->
				<sndBuf>512</sndBuf> <!-- Max send block size, apply to clients sockets only, must be > sndBlockSize. -->
				<sndLoWatermark>64</sndLoWatermark>  <!-- Send block size. Must be multiple of 4. -->
				<congestionControl>htcp</congestionControl> <!-- TCP_CONGESTION: this value replace/overwrite(!) all others cc settings: cc from http req args, http server settings, OS default -->
			<headersList> <!-- Custom HTTP headers (sended before stream). -->
				<header>Pragma: no-cache</header>
				<header>Content-Type: video/mpeg</header>
				<header>ContentFeatures.DLNA.ORG: DLNA.ORG_OP=01;DLNA.ORG_CI=0;DLNA.ORG_FLAGS=01700000000000000000000000000000</header>
				<header>TransferMode.DLNA.ORG: Streaming</header>

	<sourceProfileList> <!-- Stream source profiles templates. -->
				<rcvBuf>512</rcvBuf> <!-- Multicast recv socket buf size. -->
				<rcvLoWatermark>48</rcvLoWatermark> <!-- Actual cli_snd_block_min if polling is off. -->
				<rcvTimeout>2</rcvTimeout> <!-- STATUS, Multicast recv timeout. -->
			<multicast> <!-- For: multicast-udp and multicast-udp-rtp. -->
				<ifName>br0</ifName> <!-- For multicast receive. -->

I only modified the multicast -> ifName to br0.


msd_lite -c /etc/msd_lite.conf -v



Same as msd_lite, but powerful.

Leave a Reply

Your email address will not be published. Required fields are marked *