Setup SHOUTcast Radio server on Linux


Hits: 3127  

Download and install SHOUTcast DNAS server software

Create new user for running SHOUTCast:

# useradd shoutcast

Download Shoutcast DNAS package: http://download.nullsoft.com/shoutcast/tools/

# wget http://download.nullsoft.com/shoutcast/tools/sc_serv2_linux_x64-latest.tar.gz

Extract SHOUTcast files:

# mkdir sc
# tar -xvf sc_serv2_linux_x64-latest.tar.gz -C sc

Change the ownership from root to the SHOUTcast user:

# chown -R shoutcast:shoutcast sc

Configuring SHOUTcast Server

# cd sc
# nano sc_serv.conf

Copy below content to file sc_serv.conf

adminpassword=password
password=password1
requirestreamconfigs=1
streamadminpassword_1=password2
streamid_1=1
streampassword_1=password3
streampath_1=http://Server-IP-Address:8000
logfile=sc_serv.log
w3clog=sc_w3c.log
banfile=sc_serv.ban
ripfile=sc_serv.rip

Start SHOUTcast server

# ./sc_serv sc_serv.conf

sc2

Please make sure shoutcast port must be open in server firewall

Manage SHOUTcast Server and Create Daemon script

# ps aux | grep sc_serv ## Get Server PID
# killall sc_serv ## Stop server

# vi /usr/local/bin/shoutcast

Content of /usr/local/bin/shoutcast

#!/bin/bash
case $1 in
start)
cd /root/sc/
./sc_serv &
;;
stop)
killall sc_serv
;;
start_daemon)
cd /root/sc/
./sc_serv daemon
;;
*)
echo “Usage shoutcast start|stop”
;;
esac

# chmod +x /usr/local/bin/shoutcast
# /usr/local/bin/shoutcast start
# /usr/local/bin/shoutcast stop

Automatically start the Shoutcast server after server reboot
# echo “/usr/local/bin/shoutcast start_daemon” >> ~/.bashrc

Published by

Sandeep Verma

I’m an Entrepreneur. I’m proud to work as Blogger, LAMP Programmer, Linux Admin, Web Consultant, Cloud Manager, Apps Developer, Searcher. Concentrate > Observe > Imagine > Launch

Leave a Reply

Your email address will not be published.

*