Catch up on stories from the past week (and beyond) at the Slashdot story archive


Forgot your password?
Linux Software

Ask Slashdot: Full Shoutcast on Linux? 82

A friend of mine had asked me this question: "it seems that if I want to run a full "Radio station" on Linux only, I can't, since the streamer needs Windows. Is there a way to do it using Linux Only from top to bottom? and what hardware is needed? What software?" I'm sure many others would like to know also how..
This discussion has been archived. No new comments can be posted.

Ask Slashdot: Full Shoutcast on Linux?

Comments Filter:
  • by Anonymous Coward
    We're working on it at two levels. First, at the reproduce-what-they-have level, and second at the do-it-the-right-way level. We'd like lots of input. Consider joining (send subscribe outcast-dev to
  • its called multicasting in case you wanted to know.
  • Everyone talks about real audio and http streams but I want a shoutcast answer, the perl guy is what i'm talking about. He's writing a perl scipt to do the job. I want answers!!!
  • Why would any Linux user waste time futzing around with wine and winamp?

    Just run x11amp...

    Because, when last I checked, the x11amp people have streaming audio (which is the topic here) so far down the todo list that it has to leap on a pogo stick to touch bottom. Streaming .m3u (used by WCSB and WCLV) files via mpg123 has been hit-and-miss for me (v0.59o and v0.59k - haven't tried v0.59p yet...). I would really love for this sort of stuff to work, since it promises to be far more open than RealAudio, which - as someone has pointed out here - doesn't have clients for Alpha and PPC Linux (et mucho alia, I'll bet). Hell, Real doesn't even have the G2 Player ported to x86 Linux yet, AFAIK (RSN... RSN... we promise... RSN... RSN... don't call us, we'll call you...).


  • How many other sites use Audioactive?

    I suspect it's an ever-dwindling list. My hometown station WABC is no longer listed, and KFJC's server was down when last I checked.

    What's the URL for the list of sites?

    Try here []; there's probably a few more out there, like hr-XXL [] and WVTC [], that use mp3 or Audioactive for their streams.


  • you can do so with a regular old http server. The method for doing so is buried in Real's site somewhere. Try searching for "http streaming" or streaming without realserver.

    I'll go look for it and see if I can find the URL.
  • I don't know if used used Shoutcast yet, but sounds quality is much better than RA. Remember, these are mp3's goin' across. I can finally get something listenable with my 56k, when I couldn't with RA.
  • Sure, sounds good. Can you throw up a URL
    once you've got something workable?

  • Me and some friends will try to write sth. like that the next weekend, since we had the same idea some time ago... If we're successful we'll release it.
  • Point-to-point streaming is very hardware & network intensive. It's also (necessarily) very poor quality. You're better off setting up a radio station which uses multicasting, and RAT. Then you need virtually no additional hardware or software, and you'll end up with a radio station vastly superior to all those RealAudio ones.
  • Shoutcast is not an mp3->raw->mp3 converter !

    It takes _any_ audio in (mp3, mic, line in, cd or mixed) so IMHO They're doing it the right way ...

    Anyway, even if it was just a mp3 broadcasting engine, the decoding&encoding would be needed because you don't want to stream a 128kbps file to modem users and it must be encoded to a lower bitrate.
  • I can state with some authority that a large fraction of the live radio stations on the internet are 100% linux-based. RealAudio encoding, and serving. NOT http-based (you
    cannot do live streaming via http)

    And there's a Linux player, as well.

    All of the above available for free (for personal
    use) at
  • You could do a slightly-cheesy (no true "live" broadcast) one w/an ftp or http server and many mp3 players. mpg123 certainly will play off a URL. I don't know if winamp does, but if you only care that linux people can listen :)

    I believe it's possible to set up real streams off any http server (as the above poster mentioned) but I don't know what software is required from Real for realtime-audio compression for "live" radio. I imagine it takes up a good bit of processor power -- their player is certainly slow enough (though considering how much faster my mp3 player is, a good open-source rewrite of realplayer could speed things up a great deal...)
  • Sure, full quality mp3 would be too expensive to compress. But most streamed audio isn't anywhere near 128kbit, stereo, 44khz. A typical real stream is like 8 or 16kbit to be easy on the modems -- and I bet at that low level mp3's get relatively cheap to compress...
  • This is somewhat similar to the horrible ResRocket DRGN [] situation. All of their servers are Linux-based, but they have no plans of supporting Linux for a client. They say that if you can get it to work under an emulator, great (which won't happen until Wine does proper lowlevel MIDI support, rather than just remapping the MCI device - if this is no longer the case, PLEASE let me know!) and one guy who used to work there almost did a shell of a half-assed port of the client to Linux... which didn't work. :P

    So until then, it's not worth the effort to reboot into Windoze just to try to jam semi-live with people online and find out that everyone on is only listening, nobody's playing. A song of mine on there ("Lackluster") was still sitting there, untouched and undeleted (obviously), for several months last time I connected. I think it was in studio 17. Also last time I connected, I tried to get people to jam with me, and I just ended up recording a solo jazz improv for a while, and then gave up, lonely and depressed.

    If I want to do that, there's several Linux MIDI sequencers already. :P
  • There are a number of ways to broadcast live audio over the net without Windows. Real Audio has already been mentioned.

    However, I'm the admin for WCSB's ( audioactive streaming linux server> The audioactive unit ( is a piece of hardware that does real time mpeg3 encoding in hardware. It is made by telos systems, a well known name in the radio business.

    The system was designed to run with linux. The servers to stream the mp3 stream was originally designed to run on Linux.

    ** Martin
  • Of course, since you didn't read the rest of my post you didn't notice that it simply streams mp3. Almost any mp3 player that can handle mp3 streams will play audioactive.

    ** Martin
  • xaudio works.

    it'ld be a breeze to add it to x11amp if they'ld just release the source code or give it to me to add. . .

    I should add streaming to freeamp. . .

    ** Martin
  • Can't live stream via http? Odd. Audioactive does exactly that. WCSB uses it. It can be done.

    ** Martin
  • How about broadcasting to a subnet, or at least everyone in your collision domain (such as an office network), via UDP packets? This would allow everyone on that subnet to listen to your mp3's (or whatever) with only the bandwidth that it takes for one person to play one mp3.

    I had this idea before SHOUTcast came out...not that I think it's better :) My idea would necessitate a new client app to play the stream :(

  • They have a Basic Server G2 for Linux that you can download for free: l?program=basic
  • For HIP'97 [] (the big hackers meeting in August 1997 in the Netherlands) we've done something similar as shoutcast. Named HIP Radio [], a radio station on the network.

    We adapted mpg123 to transmit the mpeg frames in udp broadcast packets from an mp3 at the same rate as it fed them to the audio system.

    The client was a quite simple UDP packet receiver that fed the data again to stdout which could then be played with mpg123 -.

    The software (mpg123 patches and client) is still available, if someone wants to adopt this to Shoutcast format, be our guest. I'll ask Remco to put the patches for the 'transmitter' on the above HIPradio page.

  • OK
    I'm wondering,
    I attend New Mexico Tech, and to be brutally honest, our campus radio station has one of the shittiest selections of music in the world. I was thinking, since mostly everyone on campus who listens also has a connectin to the LAN, I'd like to start an MP3 streaming radio station which could cycle through a playlist which I could easily have created and updated in realtime through user selection on my webpage on my box. I would also like the ability to breakin and make comments via the mic in on my soundcard not necessarily during songplay, but maybe between songs bandwidth doesn't matter as listeners would only be on campus on the LAN, but I would like less cpu usage or a program which would take advantage of my second processor so as not to slow down my GIMP/XMAMEing. What server/clients /etc exist which might meet my needs, or could be easily modified to do so?

  • shoutcast is just an http server with a modified header that will pipe out a streaming mp3. Infact they're so similar it should be easily possible to modify apache to serve both web pages and shoutcast streams.
    linux lacks a good way to encode a streaming mp3 in realtime but for development purposes i'm sure we could play around with just sending a static file to anyone that connects.

    anyone interested in starting an apache/shoutcast project with me?
    - MbM
  • You are correct that fifos may be used for streaming encoding but there are a few problems, for one there really isn't any encoders that will go 24 or 32 hz for encoding a low end mp3 as needed and those that can to it do it very slow and the encoded stream will lag over 30 seconds from the input (which imho is terrible). There's not much that can be done about this because of patent issues on encoders and most encoders being closed source.
    I think there's also extra header information that is intered in the stream at key intervals so if a client joins late they are able to read the next header and pick up the stream from there. I don't think there is support for this in linux encoders.

    I'm planning mostly on getting the webserver to understand the shoutcast headers and play a pre generated file and afterwards let someone else fill in the encoder part.

    basic http header:

    HTTP/1.1 200 OK
    Content-Type: text/html

    shoutcast header:

    ICY 200 OK
    This stream requires Winamp []

    icy-notice2:SHOUTcast Distributed Network Audio Server/win32 v1.0b

    icy-name: something
    icy-genre: something

    Note that even the connection accept codes (200 OK) are the same, all that really needs to be done now is to figure out what winamp sends to the server and how to tell that apart from a web page request at which point you can use the shoutcast header above as a template and send it any mp3 stream you want. This is also why you can use mpg123 to play a shoutcast stream.

    - MbM
  • Freeamp is kinda ok. But right now it takes roughly about 50-85% CPU usage on my shitty Cyrix box. While mpg123 and x11amp.. hang around a nice 32-40. With that type of on the fly mp3 decoding and encoding, I dont think my machine would be able to handle freeamp anymore.

    What I'd say is.. first fix your software so that it's as optimized as it is for any platform out there.. then think about plugins and streamers..
  • You can see the protocol (hehe) by looking at the headers

    lynx -source http://localhost:8000/

    For a nice jigtter free mpg123 based shoutcast stream do

    lynx -source http://localhost:8000/ | mpg123 -

    Ofcourse you should be running a server on localhost or reflecting another server through it.. Use mpg123 59p.. if you have a k6-2.. you can compile this with 3Dnow.. and a lot of other options.. (there is optimization for 386, 486 and pentiums also support for esound, nas and a lot of o other such beasts).

    Hmmm.. on the fly mp3 decompression/encoding? hmm... have no clue :)
  • I beleive the freeamp developers were looking into doing this at some point, though freeamp still needs plenty of work to catch up to the likes of winamp.

    Actually I've put together an informal survey [] of a number of mp3 player engines, and I'd like some feedback before seriously testing them all with a proper set of mp[123] streams. Check it out.

  • That's pretty much what the survey I did found. Personally, I think the authors of these projects should have a go at talking to each other to try to develop a single decoder library so they can all get on with designing UI's that suit the myriad of uses people have.
  • There seems to be a Real Audio server for Linux out there. I installed it for a client once.

  • Because IBM told them not to use it. IBM told them to use Windows NT, not OS/2.

    And what is this product, anyway? How much does it cost? Is it a CLIENT or SERVER type product?

    Oh, and did I say that IBM is responsible for people not wanting to use OS/2.

    BTW, since this thread is about a low cost solution, I can guarantee that if you had a low cost OS/2 solution, then your statement that nobody wants it is false.

    -- Richard R. Klemmer
    WebTrek L.L.C.

  • Check out my summary of streaming to Shoutcast servers at:
    It's really pretty easy..

  • I just sent several hours looking for excatly what you are talking about. With no luck had desided to askslashdot about it when I found someone had done it for me. If you get it to work it would be great for anyone with on a LAN. Please let us know if you get it working
  • Here's the problem..
    Most of the solutions provided so far will work so someone can make a "buddy" radio station... AKA the same thing we did with walkie talkies wher we were 6. If you want to do a real net radio station there are 3 HUGE things that must be met.. #1 the client program has to run on everything.. Linux,Win,Mac,BeOS,Os/2,os-9,.... It has to unless you want to tell a huge chunk of people that they are worthless morons for using the computer they have.
    #2 if you want people to listen to your atation they will not pay for the client program. I wont buy a retail version of real-audio, noone in their right mind would.

    #3 if the free client the listener uses takes 8 hours to download and needs 32meg of hdd space and requires a T-1 line to hear decent audio you will not be listened to. It's a fact! 90% of your listeners will have 33.6 or lower speed modems. real audio sucks for low speed streams, real audio's client is more bloated than win95, and real audio is currently favored because every winbox has it on it!

    So If you can find an audio streamer that compresses as good as mp3, the playback client is tiny, I can listen to a lower quality audio feed at 14.4bps, and the client runs on anything that has a C compiler (non of them damn libs either!) you've got your radio station!!

    only problem is that product dont exist...
    if it did, Real Audio would be dead.
  • Hm, actually I've heard from people who have used winamp+wine under linux, it runs with less cpu load than do some of the linux mp3 players. (unfortunately i have no experience here because i don't listen to mp3's, no sound card)

  • The question I have, related to the original question, is: How to replace WinAMP + linerec.dll + shoutcast.dll with a Linux solution. I don't care if the Shoutcast server is running on Linux, Win32, or whatever. Or even if it's Shoutcast for that matter (could be any software that will relay what I'm playing to the rest of the world via "standard" http streaming audio).

    The first piece of the puzzle would be the real-time encoding to low bit-rate MP3 files. How can I read the line-in in Linux? Next, how can I take that line-in and pipe it to l3enc (or something faster -- and something that supports the smaller bitrates too) to create MP3 files in realtime? Next, how do I take that output of l3enc and feed it to Shoutcast server (or whatever server)?

    Looks like three steps need to be accomplished. Those first two haven't been discussed at all...
  • I was running Linux-only "radio station" using RedHat-5.1. It was two-boxes set: our intranet server was running pnserver, and my desktop box, equipped with Aztech FM card and ESS1868 sound card, was running rmenc. It took about 20%cpu on P166. Why it was stopped? rmenc dumps core with ess1868 on every kernel greater than 2.0.35. Yes, it works with SB16, and I'm waiting for it :)
  • I've written some software which does live mp3 "radio station" type streaming. Listeners can choose what songs they'd like to hear via the web or an IRC bot. They can also submit URLs, and the server will fetch the mp3 and stream it out to everyone. Each user has a specific queue and equal priority when it comes to who's song gets played next. A buddy of mine is working on a mysql index backend which will be pretty cool too. Oh yeah -- its all written in perl. :)

    My software differs from shoutcast in that it doesn't re-encode the mp3s it streams out. It just reads pre-encoded files off the disk and streams them out to everyone. You don't need a winamp frontend to make my stuff work, tho you can't do voiceovers as easily as with the shoutcast stuff.

    I'm probably going to package everything up and release it for people to play with. Anyone interested?


  • I am writing a perl program to feed mp3 data to a shoutcast server. I have got it to log in. send server info and stream data. I just to to make it slowly feed the data to shoutcast. If some wants it i'll release it.

  • I run a fully functional station using win95 and mp3 file library. It is easy to do. Find a mp3 player (one that has playlist editor) that will run on one of the many xwindows managers. The only problem is encoding all of the station's CD's into mp3s. Very time consuming. Of course you can alway just play music using the CD-rom (i'd put two on that machine) or use a mixer and hook up whatever you want to the mixer and plug it into the sound card. Simple enough. As for software, I haven't seen very much out in the world of freeware or shareware. Plenty of companies make very expensive software for radio stations and specific platforms. Good luck and make sure you have all of the apropiate liscenses needed for broadcasting over the airwaves or the Internet. I promise, you don't want the FCC or RIAA after you.
  • These are all streaming protocols and still being tested and such. The sip protocol has a mailing list on (don't remember the exact address, but you may be able to find more info on and search for rtsp or sip info).
  • I could have sworn that FP had a something like this for Linux.
  • Unfortunately, mpg123 is not GPL, so we can't use it (and, we believe splay (which is GPL) is based too heavily on amp (which means if we use it in our software it could leave us open to a lawsuit from the people who now own amp).

    As far as working on the speed of the decoder, we have someone doing that. Unfortunately, writing hand optimized assembly is not something that happens overnight. I personally would rather work on other stuff while this other guy we have works on the optimization.

    I am personally interested in seeing what engine X11amp uses whenever they release.

If I have not seen so far it is because I stood in giant's footsteps.