linux 安装流媒体服务器Darwin Streaming Server

奶牛老爹 2011-10-10

近日在做一个关于DarwinStreamingServer的项目,在网上找了一些资料,按部就班的安装,可是总会出现些错误,后来找到了一篇英文的,一路顺风!下面将其摘要出来,亲测可行:

OK,soyoudon’tnecessarilycallrtsponUbuntuQuickTimeStreamingServer.Instead,youcallitDarwinStreamingServer(DSS).ButtheendresultisbasicallywhatyouhaveexposedinMacOSXServer,butrunningonLinux.Youdon’thavethesamefunctionalityinServerAdmin,butitdoeswork.Andthekeytowhatitdoesisusethertspprotocoltostreamsupportedfilesfromtheservertoclients.Itisalittletougherthanjustclickingonthestartbutton,buttoomuchtougherprovidedyoufollowthesedirections(thankstothegoodfolksoftheDSSlistthatI’vebeenamemberofforafewyearsfortakingsuchgoodnotes,makingthismuchsimplertowritewhenIjusthavetomovefromUbuntu7to10.04).

Togetstarted(mostallofthisisgoingtoneedsudoorsu),let’susewgettodownloadallthefilesthatwe’regoingtoneed(except1):

su

wgethttp://static.macosforge.org/dss/downloads/DarwinStreamingSrvr6.0.3-Source.tar

wgethttp://dss.macosforge.org/trac/raw-attachment/ticket/6/dss-6.0.3.patch

wgethttp://dss.macosforge.org/trac/raw-attachment/ticket/6/dss-hh-20080728-1.patch

Nowlet’sextractthetarfile:

tar-xvfDarwinStreamingSrvr6.0.3-Source.tar

Nowlet’screateourqtssuserandgroup:

addgroup-systemqtss

adduser-system-no-create-home-ingroupqtssqtss

We’regoingtoneedthebuild-essentialpackagefromapt-get,solet’sinstallthatbeforemovingon:

apt-getinstallbuild-essential

Thebase6.0.3installerwasonlybuiltforMacOSX,solet’sapplythepatchesweusedwgettopulldown:

patch-p0<dss-6.0.3.patch

patch-p0<dss-hh-20080728-1.patch

Nowlet’scdintotheactualdssinstallerdirectoryandthengrabapatchedinstallerfile,getridoftheoldInstallscriptandthengrabanewone:

cdDarwinStreamingSrvr6.0.3-Source

mvInstallInstall.old

wgethttp://dss.macosforge.org/trac/raw-attachment/ticket/6/Install

Thenwe’llmaketheInstallscriptexecutableandruntheBuildit(no,notConfigure)thenInstallscripts:

chmod+xInstall

./Buildit

./Install

Finally,fireuptheDSS:

/usr/local/sbin/DarwinStreamingServer

NowyoushouldbeabletogotoastandardMacOSXclientandrunaportscanofthertspport,554usingstroke(swapthe192.168.210.254IPherewithwhateverIPorhostnamethatyou’reusing):

/Applications/Utilities/Network\Utility.app/Contents/Resources/stroke192.168.210.254554554

DSSinstallssomesamplemoviesinto/usr/local/movies.Providedthattheportisopen,let’sopenSafariandprovidethefollowinglinktoseeifoneofthestocksamplemovieswillopen:

rtsp://192.168.210.254/sample_h264_300kbit.mp4

ProvidedthatyouseethesamplemoviefromApplethenyoucanmovethesamplemovieselsewhereanddropyourowninhere.You’venowgotafullyfunctionalDSS.TheDSSwillstream.mov,.mp4and.3gpfiles.IfyouenabletheQTSSHttpFileModuleyoucanalsostreammp3files.Ifyougointothe/etc/streamingfolderyouwillseeanumberoffilesthatlooksimilartowhatyouhavebeenworkingwithonMacOSXServer(assumingyou’vebeenworkingwithMacOSXServer).Inhere,you’llfindtheqtusersandqtgroupsfilesformanagingusersandgroupsinrtspaswellasthestreamingserver.xmlfile,whichiswherethemodulesareloadedandunloaded.In/var/streamingyou’llalsofindadirectorycalledlogs,whichisinterestinglyenoughwherethelogsresideandanotherdirectorycalledplaylists,whichiswhereyouwilldropplaylistsintheeventthatyoudecidetomakeyourownradiostation.MymusictastesarebadenoughwhereI’veneverreallyconsideredthis,butfeelfreetogetallWKRPinCincinnatiifyousochoose,Ipromisenottojudge(ormaybejustalittle)…

You’llalsoenduplikelylookingtoembedthesertspstreams(thatseemstobewhateveryonedoes).Ifso,gettoknowtheXMLstructure:

<?xmlversion=”1.0″?>

<?quicktimetype=”application/x-quicktime-media-link”?>

<embedsrc="/blog/”rtsp://192.168.210.254/sample_h264_300kbit.mp4"″autoplay=”true”/>

Ultimately,buildingandusingQuickTimeStreamingonMacOSXServerisfarsuperiorinanumberofwaystodoingsoinLinux.Forstarters,thestepsherearealldonebyclickingonaStartbuttoninMacOSXServer.Butevenfurtherthanthat,updatesareevenmoreraretoDSS.Ifyou’reintherackdensitygame,anumberofMacminiserversintherightsizedrackmightjustgetyoumorebangforyoursquareinch!

http://krypted.com/mac-os-x-server/quicktime-streaming-server-on-ubuntu-10/

另参考:

http://doutdex.wordpress.com/2008/03/12/install-instalar-darwin-streaming-server-555-dss-in-ubuntu/

相关推荐