Icecast Streaming Media Server Forum Index Icecast Streaming Media Server
Icecast is a Xiph Foundation Project
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

clients not moving correctly to fallback

 
Post new topic   Reply to topic    Icecast Streaming Media Server Forum Index -> Icecast Server
View previous topic :: View next topic  
Author Message
marky



Joined: 01 Aug 2013
Posts: 2

PostPosted: Wed Mar 08, 2017 3:18 pm    Post subject: clients not moving correctly to fallback Reply with quote

When I lose a source stream, the listening clients don't appear to be transferred successfully to the fallback
(2.4.0-kh4 0-gf4141fa)

Code:
[2017-03-08  15:00:09] INFO source/source_add_listener max on /stream1 is -1 (cur 22)
[2017-03-08  15:00:10] WARN source/source_read Disconnecting /stream1 due to socket timeout
[2017-03-08  15:00:10] WARN slave/relay_read stream for /stream1 timed out, skipping server for now
[2017-03-08  15:00:10] INFO slave/relay_read fallback on /stream1 not attempted
[2017-03-08  15:00:10] INFO source/source_shutdown Source "/stream1" exiting
[2017-03-08  15:00:10] INFO slave/relay_read standing by to restart relay on /stream1
[2017-03-08  15:00:10] INFO slave/relay_startup starting on-demand relay /stream1
[2017-03-08  15:00:10] INFO slave/start_relay_stream Starting relayed source at mountpoint "/stream1"
[2017-03-08  15:00:10] INFO slave/open_relay skipping main-server:8000 for /stream1
[2017-03-08  15:00:10] INFO slave/start_relay_stream listener count remaining on /stream1 is 22
[2017-03-08  15:00:10] INFO slave/relay_reset servers to be retried on /stream1
[2017-03-08  15:00:10] INFO slave/relay_read fallback on /stream1 attempted
[2017-03-08  15:00:10] INFO source/source_shutdown Source "/stream1" exiting
[2017-03-08  15:00:10] INFO source/source_set_fallback fallback set on /stream1 to /stream1fb(0) with 22 listeners
[2017-03-08  15:00:10] INFO slave/relay_startup starting on-demand relay /stream1fb
[2017-03-08  15:00:10] INFO slave/start_relay_stream Starting relayed source at mountpoint "/stream1fb"
[2017-03-08  15:00:10] INFO slave/open_relay_connection connecting to 127.0.0.1:8000 for /stream1fb
[2017-03-08  15:00:10] INFO source/source_init Source /stream1fb initialised
[2017-03-08  15:00:10] INFO slave/start_relay_stream source /stream1fb is ready to start
[2017-03-08  15:00:10] INFO source/source_read listener count on /stream1fb now 22
[2017-03-08  15:00:10] INFO source/source_set_override no override for /stream1fb set
[2017-03-08  15:00:10] INFO slave/relay_read standing by to restart relay on /stream1 in 3 seconds
[2017-03-08  15:00:10] INFO slave/relay_reset servers to be retried on /stream1
[2017-03-08  15:00:10] INFO source/source_read listener count on /stream1fb now 0


It looks like it tries to transfer them but then they disappear?

configuration:
Code:
    <relay>
        <server>127.0.0.1</server>
        <port>8000</port>
        <mount>/blank</mount>
        <local-mount>/stream1fb</local-mount>
        <relay-shoutcast-metadata>0</relay-shoutcast-metadata>
        <on-demand>1</on-demand>
    </relay>

    <relay>
        <server>main-server</server>
        <port>8000</port>
        <mount>/stream1</mount>
        <local-mount>/stream1</local-mount>
        <on-demand>1</on-demand>
    </relay>
   
    <mount>
        <mount-name>/stream1</mount-name>
        <password>xxx</password>
        <authentication type="url">
            <option name="listener_add" value="http://localhost:81/listener_add.php"/>
            <option name="listener_remove" value="http://localhost:81/listener_remove.php"/>
            <option name="auth_header" value="icecast-auth-user: 1"/>
            <option name="timelimit_header" value="icecast-auth-timelimit:"/>
            <option name="presume_innocent" value="yes"/>
        </authentication>

        <fallback-mount>/stream1fb</fallback-mount>
        <fallback-override>1</fallback-override>
        <burst-size>300000</burst-size>
        <bitrate>128</bitrate>
        <charset>UTF-8</charset>
        <mp3-metadata-interval>4096</mp3-metadata-interval>
    </mount>

    <mount>
        <mount-name>/stream1fb</mount-name>
        <hidden>0</hidden>
        <burst-size>100000</burst-size>
        <bitrate>128</bitrate>
        <charset>UTF-8</charset>
    </mount>


/blank is fed from ezstream locally on the server.
any help appreciated.
Back to top
View user's profile Send private message
marky



Joined: 01 Aug 2013
Posts: 2

PostPosted: Thu Mar 09, 2017 11:07 am    Post subject: Reply with quote

this appears to be due to the

Code:
if (client->connection.error)

in source/send_listener

I can force connection.error to 0 before this check & the transfer happens as expected.
It's definitely not a good code change though (completely breaks other things) but I'm a little stuck getting much further than this.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    Icecast Streaming Media Server Forum Index -> Icecast Server All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2002 phpBB Group
subRebel style by ktauber