Atlantic.Net Blog

How to Install Icecast Audio Streaming Server on Ubuntu 20.04

Hitesh Jethva
by Atlantic.Net (345 posts) under Dedicated Server Hosting
0 Comments

Icecast is an open-source audio/video streaming server that can be used to create your Internet radio stations. It supports Ogg, Opus, WebM, and MP3 streaming formats. You can also stream your media from your server and access it over the internet. It is optimized for MP3 streaming and allows to handle large music collections.

In this tutorial, we will show you how to install Icecast Audio Streaming Server on Ubuntu 20.04.

Prerequisites

  • A fresh Ubuntu 20.04 VPS on the Atlantic.net Cloud Platform
  • A root password configured on your server

Step 1 – Create an Atlantic.Net Cloud Server

First, log in to your Atlantic.Net Cloud Server. Create a new server, choosing Ubuntu 20.04 as the operating system with at least 4 GB RAM, and install the Gnome desktop environment. Connect to your Cloud Server via SSH and log in using the credentials highlighted at the top of the page.

Once you are logged in to your Ubuntu 20.04 server, run the following command to update your base system with the latest available packages.

apt-get update -y

Step 2 – Install Icecast

By default, the Icecast package is available in the Ubuntu 20.04 default repository. You can install it by just running the following command:

apt-get install icecast2 -y

During the installation, you will be asked to configure Icecast as shown below:

Select Yes and hit Enter to continue. You will be asked to provide a fully qualified domain name:

Provide your valid domain name and hit Enter to continue. You will be asked to set the password to control access to media resources:

Provide your password and hit Enter to continue. You will be asked to set a password to control access to stream relays:

Provide your password and hit Enter to continue. You will be asked to set your administrator password:

Provide your password and hit Enter to finish the installation.

Once Icecast is installed, start the Icecast service and enable it to start at system reboot with the following command:

systemctl start icecast2
systemctl enable icecast2

At this point, Icecast is started and listening on port 8000. You can check it with the following command:

ss -tunelp | grep 8000

You should get the following output:

tcp LISTEN 0 5 0.0.0.0:8000 0.0.0.0:* 
users:(("icecast2",pid=1264,fd=4)) uid:108 ino:20678 sk:8 <->

Step 3 – Configure Nginx as a Reverse Proxy for Icecast

Next, you will need to install and configure Nginx as a reverse proxy to access Icecast.

First, install the Nginx server with the following command:

apt-get install nginx -y

Once installed, create an Nginx virtual host configuration file:

nano /etc/nginx/sites-available/icecast.conf

Add the following lines:

server {
listen 80;
listen [::]:80;
server_name icecast.example.com;
access_log /var/log/nginx/access.log;
error_log /var/log/nginx/error.log;
location / {
proxy_pass http://localhost:8000;
}
}

Save and close the file, then enable the virtual host with the following command:

ln -s /etc/nginx/sites-available/icecast.conf /etc/nginx/sites-enabled/

Next, you will also need to set hash bucket size in Nginx main configuration file:

nano /etc/nginx/nginx.conf

Add the following line inside http {:

server_names_hash_bucket_size 64;

Save and close the file, then restart the Nginx service to apply the changes:

systemctl restart nginx

Step 4 – Access Icecast Web UI

Now, open your web browser and access the Icecast web interface using the URL http://icecast.example.com. You should see the Icecast dashboard on the following page:

Click on the Administration tab. You will be redirected to the Icecast login page:

Provide your admin username and password and click on the Signin button. You should see your Icecast admin dashboard on the following page:

Conclusion

Congratulations! You have successfully installed and configured the Icecast streaming server on Ubuntu 20.04. You can now install the Icecast application on your computer or mobile devices and access your music from everywhere. Install Icecast on dedicated server hosting from Atlantic.Net and start using it today!

Get A Free To Use Cloud VPS

Free Tier Includes:
G3.2GB Cloud VPS Free to Use for One Year
50 GB of Block Storage Free to Use for One Year
50 GB of Snapshots Free to Use for One Year


Looking for a Hosting Solution?

We Provide Cloud, Dedicated, & Colocation.

  • Seven Global Data Center Locations.
  • Flexible Private, Public, & Hybrid Hosting.
  • 24x7x365 Security, Support, & Monitoring.
Contact Us Now! Med Tech Award FTC
SOC Audit HIPAA Audit HITECH Audit

Recent Posts

How to Install Python 3.10 on Rocky Linux 8
How to Install TaskBoard on Rocky Linux 8
How to Set Up Pritunl VPN Server on Rocky Linux 8
How to Install Teampass Password Manager on Rocky Linux 8
How to Install and Configure RabbitMQ Server on Rocky Linux 8

Get started with 12 months of free cloud VPS hosting

Free Tier includes:
G3.2GB Cloud VPS Server Free to Use for One Year
50 GB of Block Storage Free to Use for One Year
50 GB of Snapshots Free to Use for One Year


New York, NY

100 Delawanna Ave, Suite 1

Clifton, NJ 07014

United States

San Francisco, CA

2820 Northwestern Pkwy,

Santa Clara, CA 95051

United States

Dallas, TX

2323 Bryan Street,

Dallas, Texas 75201

United States

Ashburn, VA

1807 Michael Faraday Ct,

Reston, VA 20190

United States

Orlando, FL

440 W Kennedy Blvd, Suite 3

Orlando, FL 32810

United States

Toronto, Canada

20 Pullman Ct, Scarborough,

Ontario M1X 1E4

Canada

London, UK

14 Liverpool Road, Slough,

Berkshire SL1 4QZ

United Kingdom

Resources