The Stream Targets feature in Wowza Streaming Engine™ media server software allows you to send live streams to widely distributed destinations. For example, you can send a live audio stream from Wowza Streaming Engine to a SHOUTcast 1, SHOUTcast 2, or Icecast 2 server.
This article explains how to set up Wowza Streaming Engine so that you can send an audio stream to a SHOUTcast 1, SHOUTcast 2, or Icecast 2 server.
Contents
Configure SHOUTcast or Icecast to receive and distribute the stream Create a stream target to send the stream to the target application
Enable Stream Targets
Test the connection
More resources
Configure SHOUTcast or Icecast to receive and distribute the stream
In order for Wowza Streaming Engine to send a stream to an Icecast 2, SHOUTcast 1, or SHOUTcast 2 server, it must be configured to receive the stream from Wowza Streaming Engine.
Configure an Icecast 2 server
The following instructions are for version 2.4.2 of Icecast 2.- Download and install an Icecast 2 server from Icecast.
- Edit one of the example icecast.xml templates in the [install-dir]/conf/ folder to add an additional mount point with the following core settings:
- mount-name - Enter a mount point name. This is used as the stream's Mount Point/ID when creating the Icecast stream target in Wowza Streaming Engine Manager.
Note: The mount-name MUST begin with a forward slash (/) in the mount point entry and when entered in the Wowza Streaming Engine Manager as the Mount Point/ID. - source-password - Enter a password to use for source connections made to this stream.
- max-listeners - Enter the maximum number of simultaneous connections the mount point will allow.
The following example shows a mount point entry:<mount type="normal"> <mount-name>/example-simple.mp3</mount-name> <source-password>examplepassword</source-password> <password>examplepassword</password> <max-listeners>100</max-listeners> <burst-size>65536</burst-size> <hidden>0</hidden> <public>0</public> </mount>
- mount-name - Enter a mount point name. This is used as the stream's Mount Point/ID when creating the Icecast stream target in Wowza Streaming Engine Manager.
- Save your changes to the icecast.xml file, and start your Icecast 2 server.
Configure a SHOUTcast 2 server
The following instructions are for the current version of SHOUTcast (SHOUTcast 2).- Download and install a SHOUTcast DNAS from SHOUTcast.
- In a terminal, change directories to [install-dir]/SHOUTcast and run the Setup tool. This should open SHOUTcast DNAS Setup in a web browser automatically; if it does not, open 127.0.0.1:8000/setup in a web browser.
- Complete the following core settings:
- Source Password - Enter a server-level password that is used for source connections where a stream specific password was not set. This can't be the same as the server-level Admin Password or any previous password.
- Admin Password - Enter a server-level password that you'll used to access all server and SHOUTcast stream administrator pages. This can't be the same as the server-level Source Password or any previous password.
- Source Password - Enter a server-level password that is used for source connections where a stream specific password was not set. This can't be the same as the server-level Admin Password or any previous password.
- Click Continue, and then complete the following stream settings:
- Number of Streams - Use the default of 1. Each stream is given a number (in this case, 1), which is used as the stream's Mount Point/ID when creating the SHOUTcast stream target in Wowza Streaming Engine Manager.
- Source Password - Enter a password to use for source connections made to this stream. This can't be the same as the server-level Source Password or the stream's Admin Password.
- Admin Password - Enter a password to use for administrator logins for this stream.
- Maximum Listeners - Enter the maximum number of simultaneous connections the server will allow for the stream.
- Listener Stream Path - Leave empty to use the default path, or enter a custom path that you want servers to use to directly access the stream. Custom paths should use the following format: http://[serveraddress]:[/url][serverport]/[path].
- Stream Authhash - Enter the Authhash if you want the SHOUTcast 2 server to be listed in the SHOUTcast directory. For more information, see SHOUTcast Authhash Management.
- Number of Streams - Use the default of 1. Each stream is given a number (in this case, 1), which is used as the stream's Mount Point/ID when creating the SHOUTcast stream target in Wowza Streaming Engine Manager.
- Click Continue.
- Review the Core and Stream settings, and click Continue.
Note: You'll need this information when you configure Wowza Streaming Engine to send the stream to SHOUTcast. - Click Run Server to run the server with the specified settings and create Stream 1.
Configure a SHOUTcast 1 server
The following instructions are for the legacy version of SHOUTcast (SHOUTcast 1), which is no longer available directly.- In the SHOUTcast 1 installation, open the sc_serv.conf file and edit the following core settings. The file contains specific tags that represent the configuration items, with all comments preceded by a semicolon (;).
- Password - Enter a server-level password to be used for source connections.
- PortBase - The port the server will use. Icecast uses port 8000 by default.
- AdminPassword - Enter a server-level password that you'll used to access all server and SHOUTcast stream administrator pages.
- Password - Enter a server-level password to be used for source connections.
- Save your changes to the sc_serf.conf file, and start your SHOUTcast 1 server.
Create a stream target to send the stream to the target application
After creating a Live application in Wowza Streaming Engine, it must be configured to send the stream to the target application.
- In the contents panel, click Stream Targets and then click Add Stream Target.
- On the Add Stream Target page under Generic Target Destinations, click SHOUTcast or Icecast 2.
- On the SHOUTcast Configuration or Icecast 2 Configuration page, provide the following information:
SHOUTcast only
- SHOUTcast Protocol - Select the protocol Wowza Streaming Engine will use to send the stream to the destination server: SHOUTcast 1 or SHOUTcast 2.
All SHOUTcast and Icecast streams
- Stream Target Name - A descriptive name for this target setup in Wowza Streaming Engine. The name must be unique and can't contain less-than (<), greater-than (>), colon ( : ), quotation (' and "), forward slash (/), backslash (), pipe (|), question mark (?), asterisk (*), double-dot (..), or tilde (~) characters.
- Source Stream Name - The name of the incoming stream that you specified in Wowza Streaming Engine when you set up the video/audio source.
- Destination Host - The hostname or IP address of the SHOUTcast or Icecast server.
- Destination Port - The port number for your connection. SHOUTcast and Icecast connections use port 8000 by default.
- User Name/AuthHash and Password - The user name and password required to connect to the destination server. Note that User Name is only shown and needed for SHOUTcast 2 connections.
- Destination Mount Point/ID - For SHOUTcast 2, this is commonly a number and should be unique per stream on the destination SHOUTcast 2 server. For Icecast 2, this is the mount-name, and must begin with a forward slash (/). This isn't required for SHOUTcast 1 destinations.
- Server Name - The name that is sent to the server. This should be a short name and usually reflects a branding, an example would be 'Wowza Radio'.
- Genre - The type of audio style being sent to the server. For SHOUTcast streams, this should be one of SHOUTcast's supported genres. Icecast 2 streams allow user-defined genres.
- Track Update Format - This defines the format of the updates for track title information. It allows you to define how metadata in the source stream is used. The default is {StreamTitle}. If the source stream contains a metadata element called StreamTitle, then the value of this element is used to update the remote server track name. You can specify any metadata names, which are used if placed within curly braces ({ }). If you specify a name and the metadata isn't found, then it is removed from the update string.
An example would be the following Track Update Format:
{StreamTitle} {StreamArtist}
If only the StreamTitle was received in metadata as Wowza, then the resulting update would only be Wowza. The {StreamArtist} element would be removed from the update string.
- Website URL - A URL to be sent to the destination server. This may be used for display purposes on the destination or made available within the stream itself for some clients to display. It should be a fully qualified name.
- AIM - The AIM number sent to the server when the connection is established.
- ICQ - The ICQ number sent to the server when the connection is established.
- IRC - The IRC number sent to the server when the connection is established.
- Click Add this target.
Enable Stream Targets
Before you stream, you must enable the Stream Targets feature for the Wowza Streaming Engine application or the individual stream target you created.
- In the contents panel of your application, if you don't see a checkmark next to Stream Targets, click Stream Targets in the contents panel and then click Enable Stream Targets.
When Stream Targets is enabled, a checkmark appears next to Stream Targets in the contents panel and the Stream Targets page shows Status is Enabled.
- If the Status of an individual stream target is Disabled, click the Enable icon for the stream in the Actions column.
- When prompted, click Restart Now so your change takes effect.
When a stream target is enabled, its status on the Stream Targets page is one of the following:
- Waiting. The target is enabled but isn't yet pushing the stream to the target Wowza Streaming Engine destination because either the target's configured source stream isn't connected to the source Wowza Streaming Engine input or the source Wowza Streaming Engine instance has not completed initializing the connection to the target Wowza Streaming Engine instance.
- Active. The source Wowza Streaming Engine instance successfully connected to the target Wowza Streaming Engine destination and is actively pushing the stream.
- Error. The source Wowza Streaming Engine instance unsuccessfully tried to connect to the target Wowza Streaming Engine destination. Make sure the target's configured source stream is connected to the Wowza Streaming Engine input. Errors might be due to an invalid target configuration or issue with the destination server.
Test the connection
Configure your encoder and then test the live stream.
Note: Your video stream must include audio. Make sure your encoder has audio enabled. If you encoder doesn't have audio capability, you can add audio to your video-only stream by following the instructions in How to add an audio track to a video-only stream (ModuleAddAudioTrack).
- Start the stream in the H.264 camera or encoder to publish to your application in Wowza Streaming Engine.
The application ingests the stream and sends it to the SHOUTcast or Icecast destination.
- Verify that the stream is working by clicking Incoming Streams in the contents panel in Wowza Streaming Engine Manager, and then clicking the stream name.
The stream details page displays the Status of the stream (Active) as well as details about connections, uptime, and throughput for the live stream.
- Click Stop Stream at the top of the live stream detail page to end your test stream, and then stop the stream in the source camera or encoder.