[Icecast] Problems with Ices

Craig Meyer craig at fdllug.org
Sun May 22 20:18:37 UTC 2005


Karl,

I installed icecast/ices from the latest stable ebuild on gentoo 
portage. It appears from the log file that ices is only version 2.0.0 
even though the ebuild is version 2.1.0. I just reinstalled icecast with 
the newest (unstable) ebuild and it still doesn't seem to have version 
2.0.1 of ices. Do you recommend that I manually compile or that I find a 
way to use a wrapper for ALSA to make it look like OSS? Either way I 
will post my ices log and my ices and icecast config files. Maybe there 
is more to this than I understand.

-Craig

ices log:
[2005-05-22  10:11:26] INFO ices-core/main IceS 2.0.0 started...
[2005-05-22  10:11:26] INFO input-alsa/alsa_open_module Opened audio 
device plughw:0,0
[2005-05-22  10:11:26] INFO input-alsa/alsa_open_module using 2 
channel(s), 44100 Hz, buffer 371 ms (2 periods)
[2005-05-22  10:11:26] INFO input-alsa/alsa_open_module Starting 
metadata update thread
[2005-05-22  10:11:26] INFO signals/signal_usr1_handler Metadata update 
requested
[2005-05-22  10:11:26] DBUG metadata/metadata_thread_signal reading 
metadata from "test"
[2005-05-22  10:11:26] INFO metadata/metadata_thread_signal tag 1 is testing
[2005-05-22  10:11:26] INFO metadata/metadata_thread_signal Updating 
metadata
[2005-05-22  10:11:26] INFO audio/downmix_initialise Enabling 
stereo->mono downmixing
[2005-05-22  10:11:26] INFO audio/resample_initialise Initialised 
resampler for 1 channels, from 44100 Hz to 22050 Hz
[2005-05-22  10:11:26] INFO encode/encode_initialise Encoder 
initialising in VBR mode: 1 channel(s), 22050 Hz, quality 0.000000
[2005-05-22  10:11:26] INFO stream/ices_instance_stream Saving stream to 
file output.wav
[2005-05-22  10:11:26] INFO stream/ices_instance_stream Connected to 
server: localhost:8000/tobin.ogg
[2005-05-22  10:11:26] INFO audio/resample_initialise Initialised 
resampler for 1 channels, from 44100 Hz to 22050 Hz
[2005-05-22  10:11:26] DBUG encode/encode_clear Clearing encoder engine
[2005-05-22  10:11:26] INFO encode/encode_initialise Encoder 
initialising in VBR mode: 1 channel(s), 22050 Hz, quality 0.000000
[2005-05-22  10:11:44] INFO signals/signal_int_handler Shutdown requested...
[2005-05-22  10:11:44] DBUG stream-shared/stream_wait_for_data Shutdown 
signalled: thread shutting down
[2005-05-22  10:11:44] DBUG encode/encode_clear Clearing encoder engine
[2005-05-22  10:11:44] DBUG input/input_loop An instance died, removing it
[2005-05-22  10:11:44] DBUG input/input_flush_queue Input queue flush 
requested
[2005-05-22  10:11:44] INFO input/input_loop All instances removed, 
shutting down...
[2005-05-22  10:11:44] INFO metadata/metadata_thread_signal metadata 
thread shutting down
[2005-05-22  10:11:44] INFO ices-core/main Shutdown complete

ices config:
<ices>
<!-- run in background  -->
<background>0</background>
<!-- where logs go. -->
<logpath>/home/icecast/log</logpath>
<logfile>ices.log</logfile>
<logsize>2048</logsize>
<!-- 1=error, 2=warn, 3=infoa ,4=debug -->
<loglevel>4</loglevel>
<!-- logfile is ignored if this is set to 1 -->
<consolelog>0</consolelog>
<!-- optional filename to write process id to -->
<!-- <pidfile>/home/ices/ices.pid</pidfile> -->
-
    <stream>
<!-- metadata used for stream listing -->
-
    <metadata>
<name>TobinRadio</name>
<genre>FM Tuner</genre>
<description>Radio Machine for Tobin Machining</description>
<url>localhost</url>
</metadata>
-
    <!--
    Input module.

            This example uses the 'oss' module. It takes input from the
            OSS audio device (e.g. line-in), and processes it for live
            encoding. 
-->
-
    <input>
<module>alsa</module>
<param name="rate">44100</param>
<param name="channels">2</param>
<param name="device">plughw:0,0</param>
<!-- Read metadata (from stdin by default, or -->
-
    <!--
 filename defined below (if the latter, only on SIGUSR1)
-->
<param name="metadata">1</param>
<param name="metadatafilename">test</param>
</input>
-
    <!--
    Stream instance.

            You may have one or more instances here.  This allows you to
            send the same input data to one or more servers (or to different
            mountpoints on the same server). Each of them can have different
            parameters. This is primarily useful for a) relaying to multiple
            independent servers, and b) encoding/reencoding to multiple
            bitrates.

            If one instance fails (for example, the associated server goes
            down, etc), the others will continue to function correctly.
            This example defines a single instance doing live encoding at
            low bitrate. 
-->
-
    <instance>
-
    <!--
    Server details.

                You define hostname and port for the server here, along
                with the source password and mountpoint. 
-->
<hostname>localhost</hostname>
<port>8000</port>
<password>icecast</password>
<mount>/tobin.ogg</mount>
<savefile>output.wav</savefile>
<yp>1</yp>
<!-- allow stream to be advertised on YP,
default 0 -->
-
    <!--
    Live encoding/reencoding:

                channels and samplerate currently MUST match the channels
                and samplerate given in the parameters to the oss input
                module above or the remsaple/downmix section below. 
-->
-
    <encode>
<quality>0</quality>
<samplerate>22050</samplerate>
<channels>1</channels>
</encode>
-
    <!--
 stereo->mono downmixing, enabled by setting this to 1
-->
<downmix>1</downmix>
-
    <!--
 resampling.
           
                Set to the frequency (in Hz) you wish to resample to,
-->
-
    <resample>
<in-rate>44100</in-rate>
<out-rate>22050</out-rate>
</resample>
</instance>
</stream>
</ices>

icecast config:
<icecast>
-
    <limits>
<clients>100</clients>
<sources>2</sources>
<threadpool>5</threadpool>
<queue-size>102400</queue-size>
<client-timeout>30</client-timeout>
<header-timeout>15</header-timeout>
<source-timeout>10</source-timeout>
-
    <!--
 If enabled, this will provide a burst of data when a client
             first connects, thereby significantly reducing the startup
             time for listeners that do substantial buffering. However,
             it also significantly increases latency between the source
             client and listening client.  For low-latency setups, you
             might want to disable this.
-->
<burst-on-connect>1</burst-on-connect>
-
    <!--
 same as burst-on-connect, but this allows for being more
             specific on how much to burst. Most people won't need to
             change from the default 64k. Applies to all mountpoints 
-->
<burst-size>65535</burst-size>
</limits>
-
    <authentication>
<!-- Sources log in with username 'source' -->
<source-password>icecast</source-password>
<!-- Relays log in username 'relay' -->
<relay-password>icecast</relay-password>
<!-- Admin logs in with the username given below -->
<admin-user>admin</admin-user>
<admin-password>icecast</admin-password>
</authentication>
<!-- Uncomment this if you want directory listings -->
-
    <!--

    <directory>
        <yp-url-timeout>15</yp-url-timeout>
        <yp-url>http://dir.xiph.org/cgi-bin/yp-cgi</yp-url>
    </directory>
    <directory>
        <yp-url-timeout>15</yp-url-timeout>
        <yp-url>http://www.oddsock.org/cgi-bin/yp-cgi</yp-url>
    </directory>
    
-->
-
    <!--
 This is the hostname other people will use to connect to your server.
    It affects mainly the urls generated by Icecast for playlists and yp
    listings.
-->
<hostname>radio</hostname>
-
    <!--
 You can use these two if you only want a single listener
-->
<!--<port>8000</port> -->
<!--<bind-address>127.0.0.1</bind-address>-->
<!-- You may have multiple <listener> elements -->
-
    <listen-socket>
<port>8000</port>
<!-- <bind-address>127.0.0.1</bind-address> -->
</listen-socket>
-
    <!--

    <listen-socket>
        <port>8001</port>
    </listen-socket>
   
-->
<!--<master-server>127.0.0.1</master-server>-->
<!--<master-server-port>8001</master-server-port>-->
-
    <!--
<master-update-interval>120</master-update-interval>
-->
<!--<master-password>hackme</master-password>-->
-
    <!--

    <relay>
        <server>127.0.0.1</server>
        <port>8001</port>
        <mount>/example.ogg</mount>
        <local-mount>/different.ogg</local-mount>

        <relay-shoutcast-metadata>0</relay-shoutcast-metadata>
    </relay>
   
-->
-
    <!--
 Only define a <mount> section if you want to use advanced options,
         like alternative usernames or passwords
    <mount>
        <mount-name>/example-complex.ogg</mount-name>

        <username>othersource</username>
        <password>hackmemore</password>

        <max-listeners>1</max-listeners>
        <dump-file>/tmp/dump-example1.ogg</dump-file>
        <burst-size>65536</burst-size>
        <fallback-mount>/example2.ogg</fallback-mount>
        <authentication type="htpasswd">
                <option name="filename" value="myauth"/>
                <option name="allow_duplicate_users" value="0"/>
        </authentication>
    </mount>
   
-->
<fileserve>1</fileserve>
-
    <paths>
<!-- basedir is only used if chroot is enabled -->
<basedir>/usr/share/icecast</basedir>
-
    <!--
 Note that if <chroot> is turned on below, these paths must both
             be relative to the new root, not the original root
-->
<logdir>/home/icecast/log</logdir>
<webroot>/usr/share/icecast/web</webroot>
<adminroot>/usr/share/icecast/admin</adminroot>
-
    <!--
 <pidfile>/usr/share/icecast/icecast.pid</pidfile>
-->
-
    <!--
 Aliases: treat requests for 'source' path as being for 'dest' path
             May be made specific to a port or bound address using the 
"port"
             and "bind-address" attributes.
         
-->
-
    <!--

        <alias source="/foo" dest="/bar"/>
         
-->
-
    <!--
 Aliases: can also be used for simple redirections as well,
             this example will redirect all requests for 
http://server:port/ to
             the status page
         
-->
<alias source="/" dest="/status.xsl"/>
</paths>
-
    <logging>
<accesslog>access.log</accesslog>
<errorlog>error.log</errorlog>
<loglevel>4</loglevel>
<!-- 4 Debug, 3 Info, 2 Warn, 1 Error -->
</logging>
-
    <security>
<chroot>0</chroot>
-
    <!--

        <changeowner>
            <user>icecast</user>
            <group>icecast</group>
        </changeowner>
       
-->
</security>
</icecast>



Karl Heyes wrote:

>On Sun, 2005-05-22 at 19:55, Craig Meyer wrote:
>  
>
>>I am having problems getting Ices to work with ALSA. If I use arecord 
>>(arecord -D plughw:0,0 output.wav) I can record the input from my 
>>microphone into a file. The playback works perfectly. However, if I use 
>>Ices with the same values I hear nothing on the receiving end of my 
>>broadcast (although I can connect to it). In order to do a further test, 
>>I setup a <savefile> tag in my ices-live.conf file so that Ices would 
>>write to a file the sound it was sending to icecast. The output file it 
>>creates has only static. I will post the input section of my ices config 
>>file below. Any help would be appreciated. I am sure I haven't provided 
>>enough information to solve the problem, just tell me what you need...
>>    
>>
>
>The keys bits for us to know are the ices version (2.0.1 had ALSA
>updates), the XML file and maybe the log file.  If there was a stream to
>connect to then that would indicate that something is being read.
>
>karl.
>
>
>
>  
>




More information about the Icecast mailing list