EZSTREAM ( 1 ) OpenBSD Reference Manual EZSTREAM ( 1 )
ezstream - source client for Icecast with external en-/decoder support
ezstream [ -hqVv ] [ -c configfile ]
The ezstream utility is a source client for the Icecast media streaming server. In its basic mode of op- Command line parameters -c configfile -h Print a summary of available command line parameters with short descriptions and exit. -q Be more quiet. Suppress the output that external programs send to standard error. -V Print the ezstream version number and exit. -v Produce more verbose output from ezstream. Use twice for even more verbose output. When the -q and -v parameters are provided simultaneously, an additional line of information about the Runtime control SIGHUP SIGUSR1 |
CONFIGURATION FILE SYNTAX
The ezstream utility uses a simple XML configuration file format. It has a tree-like structure and is made up of XML elements. Of all the possible XML features, only regular elements that contain text or other elements, and comments, appear in an ezstream configuration file. Each element in the configuration file consists of a start tag, its content and an end tag. For ex- ample: <filename>playlist.m3u</filename> |
In this section, each available element is listed and described. Note that for this purpose, elements are in-
troduced in their short, i.e. empty form. In the configuration file, they need to be used as start tag +
content + end tag, like in the introductory example shown above.
OpenBSD 4.1 February 20, 2007 1
EZSTREAM ( 1 ) OpenBSD Reference Manual EZSTREAM ( 1 )
Root element
<ezstream />
( Mandatory. ) The configuration file's root element. It contains all other configuration elements.
Global configuration elements
Each of the global configuration elements have the <ezstream/> element as their parent.
<url />
( Mandatory. ) Specifies the location and mountpoint of the Icecast server, to which the stream will be
sent. The content must be of the form http://server:port/mountpoint For example:
<url>http://example.com:8000/stream.ogg</url>
<sourcepassword />
( Mandatory. ) Sets the source password for authentication with the Icecast server.
<format />
( Mandatory. ) This element has two different meanings, depending on whether reencoding is enabled or
not. It specifies the output format of the stream if reencoding is enabled. Otherwise, it specifies the input
format of all input files. Recognized and supported values are VORBIS, MP3 and THEORA. Other val-
ues will be ignored and cause ezstream to simply pass through the data, which may or may not work.
<filename />
( Mandatory. ) Set the path and name of a single media file, a playlist, the name of an external program
( see below ) , or the keyword stdin for streaming from standard input. Playlists are recognized by their
filename extension and end with either .m3u or .txt.
A playlist consists of filenames, one entry per line. Comments in playlists are introduced by a `#' sign at
the beginning of a line and ignored by ezstream.
<playlist_program />
( Optional. ) Set to 1 ( one ) to indicate that the file in <filename/> is actually an executable program or
script. This program is supposed to print ( to standard output ) one line with the name of a file that should
be streamed next and then exit.
If set to 0 ( zero ) , <filename/> content is assumed to be a media file, playlist file or the keyword stdin
( the default ) .
<shuffle />
( Optional. ) Set to 1 ( one ) to randomly shuffle the entries of the playlist specified in <filename/>. Files
are played sequentially if set to 0 ( zero ) or when the <shuffle/> element is absent. This option will be ig-
nored if <playlist_program/> is set to 1 ( one. )
<stream_once />
Set to 1 ( one ) to stream <filename/> content only once, and to 0 ( zero ) for continuous streaming ( the
default ) .
<reconnect_tries />
Set how many attempts should be made to reconnect to the Icecast server in case the connection is inter-
rupted. The default is to try indefinitely, which is equal to setting this configuration option to 0 ( zero ) .
<svrinfoname <svrinfourl <svrinfogenre OpenBSD |
<svrinfoname /> <svrinfourl /> <svrinfogenre /> 4.1 February 20, 2007 |
2 |
EZSTREAM ( 1 ) <svrinfodescription /> |
OpenBSD Reference Manual the broadcast. Informational only, used for YP. |
EZSTREAM ( 1 ) |
||
<svrinfobitrate /> |
( Optional. ) Set the bitrate of the broadcast. This setting is also purely informational and only used for YP.
The value is set by the user and not ezstream, and should match the bitrate of the stream.
<svrinfoquality />
( Optional. ) Set the quality setting of an Ogg Vorbis broadcast. Informational only and needs to be set by
the user, used for YP.
<svrinfochannels />
( Optional. ) Set the number of audio channels in the broadcast, e.g. 1 ( one ) for mono or 2 for stereo. In-
formational only and needs to be set by the user, used for YP.
<svrinfosamplerate />
( Optional. ) Set the sample rate of the broadcast. Informational only and needs to be set by the user, used
for YP.
<svrinfopublic />
( Optional. ) Set to 1 ( one ) if the broadcast may be listed in a public YP directory. If set to 0 ( zero ) , the
Icecast server will not submit this stream to a YP directory, which is also the default if the <svrinfopublic/>
element is absent.
<reencode />
( Optional. ) Element that contains child elements, which specify if and how reencoding should be done.
Reencoding settings
Each of the reencoding configuration elements have the <reencode/> element as their parent.
<enable />
Set to 1 ( one ) to enable reencoding. If set to 0 ( zero ) , no reencoding will be done, which is also the de-
fault if the <enable/> element is absent.
<encdec />
Element that contains child elements, which specify how to decode and encode a certain media file format
for streaming. Each format is described by a separate <encdec/> element.
Dencoder/Encoder settings
Each of the decoder/encoder configuration elements have the <encdec/> element as their parent.
<format />
This element is used by ezstream to find the appropriate encoder for the output stream format specified
in the <format/> element inside the global configuration. It is recommended that this element is always
supplied, even for currently unsupported output formats, with content such as VORBIS, MP3, THEORA,
FLAC, et cetera.
<match />
Set the filename extension used to identify a given media file format. This allows ezstream to find the
appropriate decoder for a given file. Should be set to .mp3 for MP3, .flac for FLAC, .ogg for Ogg Vorbis,
and so on.
<decode />
Set the command to decode the specified media file format to raw data and send it to standard output.
During runtime, the placeholder `@T@' is replaced with the fully qualified name of the media file, as speci-
fied in the <filename/> element or a playlist file. It should always be enclosed in quotes, to prevent prob-
lems with filenames that contain whitespaces.
OpenBSD 4.1 February 20, 2007 3
EZSTREAM ( 1 ) OpenBSD Reference Manual EZSTREAM ( 1 )
The metadata placeholder, `@M@', is also available in the <decode/> element. That way it can be used
for combined de-/encoder programs that produce readily streamable data.
For example, to decode Ogg Vorbis files using the oggdec utility: <decode>oggdec -R -o - "@T@"</decode> <encode /> For example, to encode an Ogg Vorbis stream using the quality setting 1.5 with the oggenc utility: <encode>oggenc -r -q 1.5 -t "@M@" -</encode> |
\conf Directory containing example configuration files for various uses of
ezstream.
ezstream Ed This OpenBSD |
ezstream was written by: Ed Zaleski <oddsock@oddsock.org> This manual was written by Moritz Grimm. 4.1 February |
20, 2007 4 |