| View previous topic :: View next topic |
| Author |
Message |
MHz
Joined: 29 Jun 2008 Posts: 16
|
Posted: Sun Jun 29, 2008 12:14 pm Post subject: Multiple streams |
|
|
Hi all,
I have succesfully setup a stream. Which I can connect to, so everything is fine. The Icecast server and the source are located on the same server. But I want to be able to stream live music from my own PC on the stream. So when stream B (my live stream) comes online, stream A stops and fallsover to stream B without the listener notice it. And when stream B stops, it falls over to stream A again. But how would I accomplish this?
INFORMATION:
OS: Windows Server 2003
Icecast version: Latest
Streams: /stream (main stream) /stream1 (LIVE stream)
Thanks! |
|
| Back to top |
|
 |
karlH Code Warrior

Joined: 13 Jun 2005 Posts: 5476 Location: UK
|
Posted: Sun Jun 29, 2008 1:25 pm Post subject: |
|
|
The fallback/override will be the basis of what you want. If you actually want control the fallback stream as well then you will need to use the triggers of on-[dis]connect or I suspect more effective is the auth url mount add/remove triggers.
karl. |
|
| Back to top |
|
 |
MHz
Joined: 29 Jun 2008 Posts: 16
|
Posted: Sun Jun 29, 2008 1:35 pm Post subject: |
|
|
| Can you explain me how to setup fallback/override? Thanks! |
|
| Back to top |
|
 |
karlH Code Warrior

Joined: 13 Jun 2005 Posts: 5476 Location: UK
|
Posted: Sun Jun 29, 2008 2:13 pm Post subject: |
|
|
When a stream stops then the stream listeners are moved to the fallback mount if active. When a stream starts then any listeners that are on an active fallback mount are moved to it.
karl.
Last edited by karlH on Sun Jun 29, 2008 2:27 pm; edited 1 time in total |
|
| Back to top |
|
 |
MHz
Joined: 29 Jun 2008 Posts: 16
|
Posted: Sun Jun 29, 2008 2:23 pm Post subject: |
|
|
| How to configure the fallback? I cant find any usefull information in the docs. |
|
| Back to top |
|
 |
karlH Code Warrior

Joined: 13 Jun 2005 Posts: 5476 Location: UK
|
Posted: Sun Jun 29, 2008 2:36 pm Post subject: |
|
|
the options are <fallback-mount> and <fallback-override>
karl. |
|
| Back to top |
|
 |
MHz
Joined: 29 Jun 2008 Posts: 16
|
Posted: Sun Jun 29, 2008 3:30 pm Post subject: |
|
|
So this is the part I need to modify:
| Code: |
<mount>
<mount-name>/example-complex.ogg</mount-name>
<username>USER</username>
<password>PASS</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>
<fallback-override>1</fallback-override>
<fallback-when-full>1</fallback-when-full>
<intro>/example_intro.ogg</intro>
<hidden>1</hidden>
<no-yp>1</no-yp>
<authentication type="htpasswd">
<option name="filename" value="myauth"/>
<option name="allow_duplicate_users" value="0"/>
</authentication>
<on-connect>/home/icecast/bin/stream-start</on-connect>
<on-disconnect>/home/icecast/bin/stream-stop</on-disconnect>
</mount>
<mount>
<mount-name>/auth_example.ogg</mount-name>
<authentication type="url">
<option name="mount_add" value="http://myauthserver.net/notify_mount.php"/>
<option name="mount_remove" value="http://myauthserver.net/notify_mount.php"/>
<option name="listener_add" value="http://myauthserver.net/notify_listener.php"/>
<option name="listener_remove" value="http://myauthserver.net/notify_listener.php"/>
</authentication>
</mount> |
Could you help me doing this?
/stream is the main stream and /stream1 is the live stream
What do I need to use as the user and the password?
Thanks in advance! |
|
| Back to top |
|
 |
karlH Code Warrior

Joined: 13 Jun 2005 Posts: 5476 Location: UK
|
Posted: Sun Jun 29, 2008 5:49 pm Post subject: |
|
|
just add/remove the parts you actually need. The only required part of <mount> is <mount-name> and as you have already mentioned, one will be /stream and the other will be /stream1. Whether you want an intro or dump file or burst etc is up to you. Start simple have only what you want then add things as see fit. The docs describe each of those settings, we just shipped samples with that lot uncommented to give people an idea.
karl. |
|
| Back to top |
|
 |
MHz
Joined: 29 Jun 2008 Posts: 16
|
Posted: Mon Jun 30, 2008 10:28 am Post subject: |
|
|
I tried the following but it doesnt work.
| Code: |
<mount>
<mount-name>/stream</mount-name>
<fallback-mount>/stream1</fallback-mount>
</mount>
<mount>
<mount-name>/stream1</mount-name>
<fallback-mount>/stream</fallback-mount>
</mount>
|
the first one is for /stream so it will fallover to /stream1 and the second one is for /stream1 so it will fallover to /stream. Any ideas why this doesnt work?
Oh, and by the way,when I listen to my station, press the stop button on winamp and then press play again, i'm listening to an old buffer or something, because I dont hear the song currently playing. Why does this happen, on shoutcast I dont have this problem. Thanks |
|
| Back to top |
|
 |
karlH Code Warrior

Joined: 13 Jun 2005 Posts: 5476 Location: UK
|
Posted: Mon Jun 30, 2008 12:20 pm Post subject: |
|
|
That snippet will work provided 2 things are true. 1. The xml snippet is not commented out (loading the xml into a browser should show that). 2. The fallback is active at the time the current stream is shutting down.
karl. |
|
| Back to top |
|
 |
|