Apple’s Darwin Streaming Server On Centos 5.2 - Page 2

Want to support HowtoForge? Become a subscriber!
 
Submitted by Jam3s (Contact Author) (Forums) on Mon, 2008-09-29 17:32. ::

Encoding Video with QuickTime Pro for use with DSS

Before a video can be streamed with DSS the file must be hinted and then exported to the server. Without the video being hinted streaming the file can be unpredictable and suffer a loss of sound. I bought QuickTime pro for £20 GBP, however the same process can be achieved using ffmpeg and mpeg4ip described in the next section.

Open the video in QuickTime Pro then go to File > Export and select Movie to hinted movie shown below.

Exporting File IMAGE

Click options and select "Optimize hints for Server (creates larger file)":

optimize checkbox IMAGE

Save the file and upload the file to server. Move the file to /var/dss/movies; open QuickTime and select File > Open URL and type rtsp://192.168.0.110/movie.mov and the file should stream.

streaming IMAGE

 

Encoding Video with ffmpeg and mpeg4ip

Encoding Video with ffmpeg and mpeg4ip seems to work just as well and is free. ffmpeg has far more features and I prefer using this method so I can script the encoding at night. It may be recommended to encode on a seprate server with less load depending on your situation.

rpm -Uhv http://apt.sw.be/redhat/el5/en/i386/rpmforge/RPMS/rpmforge-release-0.3.6-1.el5.rf.i386.rpm
yum install ffmpeg --enable rpmforge
rpm -e faad2 –nodeps
rpm -e faac –nodeps
yum install SDL-devel
wget http://garr.dl.sourceforge.net/sourceforge/mpeg4ip/mpeg4ip-1.5.0.1.tar.gz
tar xzvf mpeg4ip-1.5.0.1.tar.gz
cd mpeg4ip-1.5.0.1
./bootstrap --disable-mp4live --disable-player
make
make install

To encode a video using ffmpeg and mp4creator use the following commands (my file was an mpeg2 called movie.mpg captured from a TV card):

ffmpeg -i movie.mpg -b 300000 -s 320×240 -vcodec mpeg4 -acodec aac movie.mp4
mp4creator -optimize movie.mp4
mp4creator -hint=1 movie.mp4
mp4creator -hint=2 movie.mp4
mp4creator -list movie.mp4

To take a thumbnaill of your video for your webpage, issue the following command:

ffmpeg -y -an -i movie.mp4 -v 0 -ss starttime -t 0.001 -f image2 "thumbnail.jpg"

Move the newly created mpeg4 file to /var/dss/movies and open QuickTime; select File > Open URL and type rtsp://192.168.0.110/movie.mp4 and the file should stream.

 

References

http://www.mikehillyer.com/linux/compiling-darwin-streaming-server-for-centos-52-x86_64/
http://ffmpeg.mplayerhq.hu/ffmpeg-doc.html
http://mpeg4ip.sourceforge.net/documentation/index.php


Please do not use the comment function to ask for help! If you need help, please use our forum.
Comments will be published after administrator approval.
Submitted by Anonymous (not registered) on Thu, 2013-09-26 12:32.

this command is not running in my PC.
rpm -Uhv http://apt.sw.be/redhat/el5/en/i386/rpmforge/RPMS/rpmforge-release-0.3.6-1.el5.rf.i386.rpm

 error shown :

Retriving http://apt.sw.be/redhat/el5/en/i386/rpmforge/RPMS/rpmforge-release-0.3.6-1.el5.rf.i386.rpm

error: skiping http://apt.sw.be/redhat/el5/en/i386/rpmforge/RPMS/rpmforge-release-0.3.6-1.el5.rf.i386.rpm - transfer failed - unknown or unexpected error

warning: u 0*912b928 ctrl 0*912c740 nrefs!=0(apt.sw.be http)

could anyone please give me any solution?

Submitted by Matthias (not registered) on Wed, 2009-05-06 15:30.

This tutorial worked great for me. Although I'd prefer Opensuse over CentOS, I set up a server, following these instructions and it worked out of the box. The hinting routine described above can/needs also be used for streaming 3gp files.
One additional tip from me: If you do this, you are running Darwin under the user account, not as root.I found by adding the user to the qtss group, Darwin starts to populate the access logs :-)
Thanks again!

Submitted by Ken (not registered) on Mon, 2009-01-19 12:35.
I have followed this instructions and the install worked brilliantly. But when trying to stream the sample videos I got "Not Found" message on Quick time. I did google and found several people encountering the same problem. Any ideas why this could be happening?
Submitted by clackend (not registered) on Fri, 2009-03-20 01:29.
I have the same error occurs.
"not found"
Submitted by gral10 (not registered) on Thu, 2009-03-26 15:19.
same here =(
Submitted by Anonymous (not registered) on Wed, 2009-09-02 11:19.
make sure your file location
Submitted by Anonymous (not registered) on Tue, 2010-05-11 19:44.

Same problem.  It only worked when using ffplay and streamed from 127.0.0.1 address like this

ffplay rtsp://127.0.0.1/sample_100kbit.mov

 I have checked and made sure the firewall and SELinux were both off. 

Does anyone have an idea what was wrong here?

 

Submitted by David (not registered) on Thu, 2010-05-20 03:10.
I had the same problem and then spent a day or two learning more about hinting.  Once I started to correctly hint my mp4 files everything seemed to work.
Submitted by Anonymous (not registered) on Thu, 2013-09-26 09:20.
how did you solve it?.....I cann't solve......
Submitted by Anonymous (not registered) on Wed, 2010-05-19 21:08.

The problem may be if you are using NAT to access your server from the internet.

 

There is a configuration file in /etc/dss/

edit /etc/dss/streamingserver.xml

add your external NAT IP to the following:

<PREF NAME="alt_transport_src_ipaddr" ></PREF>

 

like this

<PREF NAME="alt_transport_src_ipaddr" >xxx.xxx.xxx.xxx</PREF>

 

then restart DSS 

/etc/init.d/dss restart

 

This worked for me. 

good luck.