Traktor plus Icecast plus StreamTranscoder plus Shoutcast

I have been running an internet radio station for the greater part of the past year now. Originally I had hooked this up to be a mostly auto pilot project, and my setup consisted of uploading mp3 files to one of my co-located servers, and then having mpd stream to shoutcast, so that it was sort of like iTunes in the sky.

As the year has progressed I have been getting more and more into music in ways I could never have imagined. I have been learning how to mix, and gathering an insane amount of music. Needless to say, after the first few sessions I was determined to figure out how to broadcast traktor straight to shoutcast.

At first this seems trivial right, because Traktor has support for internet radio broadcasting, yay! Wrong. Turns out Traktor did not want to pay royalty fees to license mp3 technology in a way so they can stream it so they decided to cheap out (it's not like Traktor is free, c'mon N.I.!) and only support the less popular (but totally decent) Ogg format.

This being the case, that means that to successfully plug Traktor into shoutcast we have to run a middle man program, via one method or another. The first method I tried was Nice Cast which is a mac friendly application that simply takes the raw output of your soundcard, transcodes it to your desire, then sends it to shoutcast for you. In practice this is not too bad of a solution but there was several reasons I was not feeling it, including added latency, wonky gain levels, occasional distortion, and the fact that its closed source and a mac only app (no running it on a unix server).

More after the break...

 

So, after some more reading, I decided that I was going to take another approach all together. The new approach would introduces 2 more server based applications, but enables me to simply broadcast straight from traktor to my shoutcast station (and shoutcast directory). This approach involves:

  • Setting Up Traktor To Stream To IceCast
  • Setting Up IceCast
  • Setting Up ShoutCast
  • Setting Up StreamTranscoder to pull from IceCast and push to ShoutCast


Before embarking you should have a basic knowledge of whatever unix operating system you are going to be using for the streaming and how to install and configure software for it.

1. Setting Up Traktor To Stream To IceCast
This is the easiest part probably. Head into the configurations and settings are of Traktor. Head to the broadcasting section. The only area we need to change is server settings.
Server Address: YOUR.SHOUTCASTDOMAIN.COM ( for me its radio.spotman.net. this should be the internet hostname of whatever server is doing the icecast/transcoding/shoutcast.)
Server Port: 9000
Mount Path: /listen.ogg
Password: make up a secure password, write it down.

2. Seting Up IceCast
If Icecast is not yet installed on your server, do that now, refer to icecast website or your operating system's packaging system, whether thats pacman, rpm, yum, yast, whatever.

Once installed, open up the icecast.xml configuration file in your favorite text editor. I have removed all commented out sections of mine and posted it here for your reference: Please Note: its better to compare this line by line with yours, instead of copying/pasting, some things like the user in which it runs under or file system paths could be different on your system. The really important parts are in authentication and listen-socket. Make sure to update both of those sections and you should be good to go. Notice that listen-socket is set to port 9000 as we configured traktor above.

<icecast>
    <limits>
        <clients>1200</clients>
        <sources>2</sources>
        <threadpool>5</threadpool>
        <queue-size>524288</queue-size>
        <client-timeout>30</client-timeout>
        <header-timeout>15</header-timeout>
        <source-timeout>10</source-timeout>
        <burst-on-connect>1</burst-on-connect>
        <burst-size>65535</burst-size>
    </limits>

    <authentication>
        <source-password>CHANGEME</source-password>
        <relay-password>CHANGEME</relay-password>
        <admin-user>admin</admin-user>
        <admin-password>CHANGEME</admin-password>
    </authentication>
    <directory>
        <yp-url-timeout>15</yp-url-timeout>
        <yp-url>http://dir.xiph.org/cgi-bin/yp-cgi</yp-url>
    </directory>
    <hostname>YOUR.SHOUTCASTDOMAIN.COMt</hostname>
    <listen-socket>
        <port>9000</port>
    </listen-socket>

    <fileserve>1</fileserve>
    <paths>
	    <basedir>/var/media</basedir>
	    <logdir>/logs</logdir>
	    <webroot>/web</webroot>
	    <adminroot>/admin</adminroot>
            <alias source="/" dest="/status.xsl"/>
    </paths>

    <logging>
        <accesslog>access.log</accesslog>
        <errorlog>error.log</errorlog>
      	<loglevel>3</loglevel> <!-- 4 Debug, 3 Info, 2 Warn, 1 Error -->
      	<logsize>10000</logsize> <!-- Max size of a logfile -->
    </logging>

    <security>
        <chroot>1</chroot>
        <changeowner>
            <user>icecast</user>
            <group>icecast</group>
        </changeowner>
    </security>
</icecast>


Ok now that that is done, go ahead and fire up icecast.

3. Setting Up Shoudcast.
As with icecast, go download shoutcast and install it. Refer to the included readme for instructions on how to run it. Once you get it unpacked open up sc_serv.conf in your favorite text editor. I have included the needed changes here, and left out everything else. Once again just make these changes do not use this as your entire file.

MaxUser=1200
Password=CHANGEME
PortBase=8000
LogFile=sc_serv.log
RealTime=1
ScreenLog=1
ShowLastSongs=10
SrcIP=ANY
DestIP=ANY
Yport=80
NameLookups=0
AutoDumpUsers=0
AutoDumpSourceTime=30
PublicServer=always
AllowRelay=Yes
AllowPublicRelay=Yes

Notice that the port base here is listed as 8000.

4. Setting Up StreamTranscoder to pull from IceCast and Send To Shoutcast.

You can download it here. Once you get it installed, find the following settings in its configuration file and edit appropriately. What we are telling it is to download the stream from our icecast server on localhost at port 9000, then transcode it at 96kbps and send it to shoutcast on localhost port 8000.

SourceURL=http://127.0.0.1:9000/listen.ogg
Server=localhost
Port=8000
ServerPassword=CHANGEME
ServerPublic=1
ServerIRC=CHANGEME
ServerAIM=CHANGEME
ServerICQ=CHANGEME
ServerStreamURL=http://YOUR.SHOUTCASTDOMAIN.COM
ServerDescription=My Awesome Station
ServerGenre=Experiemental
ServerMountpoint=/listen.pls
AutomaticReconnect=1
AutomaticReconnectSecs=10
Encode=LAME
BitrateNominal=96
BitrateMin=96
BitrateMax=96
ServerType=Shoutcast



Thats it! All you need to do now, is start in the following order, shoutcast, icecast, streamtranscoder, then traktor. Once in Traktor click broadcast and watch the icecast log to make sure it connects. If there is a problem the broadcasting icon will blink instead of go solid.

If you run into any hiccups, make sure that your passwords match in all config files, and make sure that port 8000, and 9000 are open to your server. You can always hit port 9000 in a web browser to see icecast status (and admin) , port 8000 to see shoutcast status (and admin).

Happy Streaming!


Comments:

Thanks for the advice bro..........................but my problem is 1. should i have a shoutcast account with a server? 2. should i open another port? if so how u go about doin that?(I only have one port open to 8000). 3. Which program specify the location of the stream? is it the streamtranscoder or is it the shoutcast (mine is the streamtranscoder) Another thing that i hope u can help me with is, that the streamtranscoder settings are assigned to my icecast, without the shoutcast settings. when i copied the destination given by the streamtranscoder into the URL the mp3 player comes up but it only plays for 3secs....should the shoutcast help the stream last longer? Thanks for the tips when u get this
Posted By: J.H, 1 year ago
hey JH, you would need a dedicated server or at least a VPS to run this.. that would also determine the address and things too. Hope this helps! -scott
Posted By: cowboyrushforth, 1 year ago
ok thanks.............................but should i open another port?
Posted By: J.H., 1 year ago
one more thing.....where can i find a FREE dedicated server? if there is such a thing
Posted By: J.H., 1 year ago
Hey i got it to work but not how you described it. first the traktor to icecast setup Address: Localhost Port: 8000 mount path: stream.ogg password: hackme an also u dont actually need the shoutcast program for the icecast setup for the hostname is "localhost" an the port "8000" now for the streamtranscoder the streamtranscoder requires the ip address of the site that u wanna broadcast to as well as the port of the server you are broadcasting to example: servertype:shoutcast server:87.124.455. port: the server's port that u wanna stream to in this case mine is 18188 password: is the password required to access the server that u signed up wid the server that i signed up with to host my stream is listen2myradio.com its free and they give u the server ip needed as well as the port. and thats it
Posted By: J.H., 1 year ago

Add Comment:

Your Name:
Your E-Mail:
(Not Displayed)
Comment:
Security Code:14c7f47f87a2a13f5e32e8ab8a90a22ec65ca3f7
Type Security Code:


Back

Tag cloud

  1. 1 entries are tagged with 2007
  2. 1 entries are tagged with 2008
  3. 1 entries are tagged with 2009
  4. 2 entries are tagged with 2010
  5. 1 entries are tagged with altly
  6. 2 entries are tagged with applevalley
  7. 1 entries are tagged with archlinux
  8. 1 entries are tagged with artichoke
  9. 1 entries are tagged with automation
  10. 1 entries are tagged with batcountry
  11. 1 entries are tagged with beats
  12. 1 entries are tagged with bigsur
  13. 3 entries are tagged with bm2009
  14. 1 entries are tagged with bm2010
  15. 8 entries are tagged with burningman
  16. 2 entries are tagged with c
  17. 1 entries are tagged with christmas
  18. 8 entries are tagged with code
  19. 1 entries are tagged with consistent
  20. 1 entries are tagged with cplusplus
  21. 1 entries are tagged with desert
  22. 1 entries are tagged with drinks
  23. 1 entries are tagged with dspam
  24. 2 entries are tagged with dunes
  25. 1 entries are tagged with energy
  26. 1 entries are tagged with esplanade
  27. 5 entries are tagged with europe
  28. 1 entries are tagged with evdo
  29. 2 entries are tagged with flv
  30. 1 entries are tagged with gadgets
  31. 1 entries are tagged with government
  32. 1 entries are tagged with haiku
  33. 1 entries are tagged with hashring
  34. 1 entries are tagged with icecast
  35. 1 entries are tagged with internetradio
  36. 1 entries are tagged with iphone
  37. 1 entries are tagged with linkfinder
  38. 2 entries are tagged with losangeles
  39. 1 entries are tagged with math
  40. 1 entries are tagged with minespotter
  41. 1 entries are tagged with minesweeper
  42. 3 entries are tagged with mix
  43. 1 entries are tagged with motivation
  44. 1 entries are tagged with moving
  45. 3 entries are tagged with music
  46. 1 entries are tagged with newserver
  47. 4 entries are tagged with node.js
  48. 1 entries are tagged with obama
  49. 1 entries are tagged with oil
  50. 1 entries are tagged with productivity
  51. 1 entries are tagged with radio
  52. 1 entries are tagged with rails
  53. 3 entries are tagged with recipe
  54. 1 entries are tagged with redmine
  55. 2 entries are tagged with reflections
  56. 1 entries are tagged with rmine
  57. 8 entries are tagged with ruby
  58. 1 entries are tagged with salmon
  59. 1 entries are tagged with salsa
  60. 1 entries are tagged with shoutcast
  61. 3 entries are tagged with site
  62. 2 entries are tagged with snow
  63. 1 entries are tagged with spill
  64. 1 entries are tagged with spotmanradio
  65. 1 entries are tagged with streamtranscoder
  66. 1 entries are tagged with summer
  67. 1 entries are tagged with tecate
  68. 1 entries are tagged with technology
  69. 1 entries are tagged with thanksgiving
  70. 1 entries are tagged with thoughts
  71. 6 entries are tagged with travel
  72. 1 entries are tagged with trip
  73. 1 entries are tagged with turkey
  74. 3 entries are tagged with twitter
  75. 1 entries are tagged with website
  76. 1 entries are tagged with wordsquared
  77. 4 entries are tagged with work
  78. 1 entries are tagged with x4200
  79. 3 entries are tagged with yz250
  80. 1 entries are tagged with zeromq

Twitter Updates

Links to check out

Subscribe RSS