# Updates
# 06/22/11 – Updated guide to use the latest version of Icecast (2.3.2)

*Note – This does NOT work on 64 bit CentOS (x86_64); it will only install for 32 bit (i386). If you need to install on 64 bit, use the guide found here: http://support.cast-control.net/index.php?_m=knowledgebase&_a=viewarticle&kbarticleid=69. Once you got it installed, you can start from my Step #3 – Configuration. I tested their guide on my personal server and it worked perfectly.
Icecast Logo

Icecast Installation Guide for CentOS 5

I ran across a request from a customer recently asking me to install Icecast. I didn’t find any easy guides out there that had the entire process laid out. So, here is my contribution to the Internet. I hope one of you find this useful. With this guide, you can set it up in a mere 10 minutes.

#1 – First off, What is Icecast?

Per the official website (http://www.icecast.org): Icecast is free server software for streaming multimedia. In particular, icecast streams audio to listeners over the Internet, and is compatible with Nullsoft’s Shoutcast.

#2 – Installation

The first thing to do is install the dependencies that are needed run icecast:

yum install curl-devel libtheora-devel libvorbis-devel libxslt-devel speex-devel

Next, grab the SRPM:

rpm -ivh http://downloads.xiph.org/releases/icecast/icecast-2.3.2-0.src.rpm

****If you get the following error:

Retrieving http://downloads.xiph.org/releases/icecast/icecast-2.3.2-0.src.rpm
error: cannot create %sourcedir /usr/src/redhat/SOURCES

You will need to install the development dependencies:

yum groupinstall 'Development Tools'

Now build the binary package using the newly acquired specs:

rpmbuild -bb /usr/src/redhat/SPECS/icecast.spec

And then install the RPM:

rpm -ivh /usr/src/redhat/RPMS/i386/icecast-2.3.2-0.i386.rpm

#3 – Configuration

You need to modify the /etc/icecast.xml file and change the default passwords for the users: source, relay,  admin. The Icecast developers definitely have a sense of humor; The default passwords are ‘hackme’.

         
              
              NEW-PASSWORD
              
              NEW-PASSWORD
     
              
              admin
              NEW-PASSWORD
         

You will have to change the user that the icecast service runs as. It cannot be initiated as root. It’s very picky and will give an error message:

[root ~]# ERROR: You should not run icecast2 as root

So simply change it to something else. The most intuitive solution would be to use ‘icecast’:

         
             icecast
             nogroup
         

And the last modification is to change the log directory from /usr/var/log/icecast to –> /var/log/icecast:

         <logdir>/var/log/icecast</logdir>

#4 – Add user and log folder

Almost done. Now add the icecast user and create the log path we specified above:

mkdir /var/log/icecast
useradd icecast
chown icecast:icecast /var/log/icecast/

#5 – Run Icecast

This is it, the moment you’ve been waiting for:

su icecast -c 'icecast -c /etc/icecast.xml -b'

Make sure port 8000 is opened in your firewall. Now you can test it by accessing: http://yourdomain.com:8000. You will see a black screen:

Icecast status page

The front page for Icecast server

#6 – Add to system start up

You will want icecast to start when the server boots. Take the command to run the service (listed above) and place it in your:

/etc/rc.local
A linux web hosting administrator, a professional production sound man, and a renegade cop without nothing left to lose.... Ok, that last part is made up. In all seriousness, my passion in life is to help people; whether that be with help running their sites or with their productions. The name Boom Shadow was given to me by a great group of filmmakers called Star Wipe Films. back in 2005 and has been with me since. One of these days, I will post the full story, and many more, here. As a side note, I love my mac for video editing, my CentOS for web hosting, and my Windows box for Stepmania. Don't give me any OS hate, cause I don't care :P Also, nano is still the bomb!

Latest posts by Jacob "Boom Shadow" Tirey (see all)