Tag: shoutcast

  • Start shoutcast on boot

    This method is for CentOS 6. On newer systems, you may need to use systemd or enable rc-local service for /etc/rc.local to work./

    vi /home/shoutcast/shoutcast.sh
    

    Add

    #!/bin/bash
    
    killall sc_serv
    killall sc_trans_linux
    cd /home/shoutcast/
    ./sc_serv  >/dev/null &
    cd /home/shoutcast/sc_trans_040
    ./sc_trans_linux >/dev/null &
    
    

    Set permission

    chmod 755 /home/shoutcast/shoutcast.sh
    

    To start on boot, we add it to /etc/rc.local

    vi /etc/rc.local
    

    At the end of the file add as new line

    /home/shoutcast/shoutcast.sh
    

    See Shoutcast

  • Shoutcast sc trans

    sc_trans can play list of mp3 files to shoutcast server so your online radio station will be online even if you are not online.

    Install sc_trans

    cd /home
    mkdir shoutcast
    cd shoutcast
    wget http://yp.shoutcast.com/downloads/sc_trans_posix_040.tgz
    tar -zxvf sc_trans_posix_040.tgz
    cd sc_trans_040
    

    Create Play List of mp3 Files

    Upload your MP3 files to folder

    /home/shoutcast/sc_trans_040/mp3

    To create a play list, run

    find ./mp3 -type f -name "*.mp3" > playlist.lst
    

    Edit sc_trans.conf

    Find

    PlaylistFile=example.lst
    

    Replace With

    PlaylistFile=playlist.lst
    

    Find

    ServerIP=myserver.com
    

    Replace with IP of server on which you run shoutcast server.

    ServerIP=server28.hosthat.com
    

    Find

    ServerPort=8000
    

    8000 is default shoutcast server port. Change it if you use non default port.

    Find

    Password=
    

    Set the password you set in shoutcast server in Password= line.

    Start sc_trans

    Run

    ./sc_trans_linux
    

    Listening to Online Radio

    In Windows Media player, file > open url, enter

    http://server28.hosthat.com:8000

    start playing the songs.

    See shoutcast

  • Install shoutcast server

    Download linux version from site

    http://www.shoutcast.com/download-files

    cd /home
    mkdir shoutcast
    cd shoutcast
    wget http://yp.shoutcast.com/downloads/sc1-9-8/sc_serv_1.9.8_Linux.tar.gz
    tar -zxvf sc_serv_1.9.8_Linux.tar.gz
    

    Now edit sc_serv.conf

    vi sc_serv.conf
    

    Find

    Password=changeme
    

    Replace changeme with secure password.

    Other important options are

    MaxUser
    PortBase
    

    To start, run

    ./sc_serv 
    

    To start in background, run

    ./sc_serv &
    

    After you run, you will see

    [root@server28 shoutcast]# ./sc_serv
    *******************************************************************************
    ** SHOUTcast Distributed Network Audio Server
    ** Copyright (C) 1998-2004 Nullsoft, Inc.  All Rights Reserved.
    ** Use "sc_serv filename.ini" to specify an ini file.
    *******************************************************************************
    
    Event log:
    <08/14/09@18:37:38> [SHOUTcast] DNAS/Linux v1.9.8 (Feb 28 2007) starting up...
    <08/14/09@18:37:38> [main] pid: 27910
    <08/14/09@18:37:38> [main] loaded config from sc_serv.conf
    <08/14/09@18:37:38> [main] initializing (usermax:32 portbase:8000)...
    <08/14/09@18:37:38> [main] No ban file found (sc_serv.ban)
    <08/14/09@18:37:38> [main] No rip file found (sc_serv.rip)
    <08/14/09@18:37:38> [main] opening source socket
    <08/14/09@18:37:38> [main] source thread starting
    <08/14/09@18:37:38> [main] opening client socket
    <08/14/09@18:37:38> [source] listening for connection on port 8001
    <08/14/09@18:37:38> [main] Client Stream thread [0] starting
    <08/14/09@18:37:38> [main] client main thread starting
    <08/14/09@18:38:05> [dest: 59.98.136.119] server unavailable, disconnecting
    <08/14/09@18:38:06> [dest: 59.98.136.119] Invalid resource request(/favicon.ico)
    <08/14/09@18:39:45> [sleeping] 0 listeners (0 unique)
    

    By default shoutcast run on port 8000.

    If you go to

    http://server28.hosthat.com:8000/

    You will get

    ICY 401 Service Unavailable icy-notice1:
    SHOUTcast Distributed Network Audio Server/Linux v1.9.8
    icy-notice2:The resource requested is currently unavailable
    

    See shoutcast