luis4god / darkice

Automatically exported from code.google.com/p/darkice
0 stars 0 forks source link

failed to write to ring ruffer #11

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
Darkice crashes after a few days claiming many lines of 
"failed to write to ring ruffer"
We are broadcasting 3 different outputs of different bitratio, the input is
from jack source. 

What version of the product are you using? On what operating system?
DarkIce 0.20.1, Ubuntu Feisty

Please provide any additional information below.
    [general]
    duration        = 0
    bufferSecs      = 10
    reconnect       = yes

    [input]
    device          = jack_auto
    sampleRate      = 44100     
    bitsPerSample   = 16        
    channel         = 2        

    [icecast2-0]
    bitrateMode     = abr
    format          = mp3
    bitrate         = 96
    server          = stream.xxx.org.uk
    port            = 8000
    password        = xxx
    mountPoint      = xxx_high.mp3
    name            = xxx
    description     = xxx
    url             = http://www.xxx.org.uk
    genre           = music
    public          = yes

    [icecast2-1]
    bitrateMode     = abr
    format          = mp3
    bitrate         = 32
    server          = stream.xxx.org.uk
    port            = 8000
    password        = xxx
    mountPoint      = xxx_low.mp3
    name            = xxx
    description     = xxx
    url             = http://www.xxx.org.uk
    genre           = music
    public          = yes

    [icecast2-2]
    bitrateMode     = abr
    format          = mp3
    bitrate         = 16
    server          = stream.xxx.org.uk
    port            = 8000
    password        = xxxx
    mountPoint      = xxx_punk.mp3
    name            = xxx
    description     = xxx
    url             = http://www.xxx.org.uk
    genre           = music
    public          = yes

/usr/local/bin/jackd -Z -v -d oss -r 44100 -p 4096 -w 16 -i 2

Original issue reported on code.google.com by marcel.hecko@gmail.com on 14 Dec 2009 at 12:27

GoogleCodeExporter commented 9 years ago
Can you please try darkice from svn trunk?

Original comment by rafael2k...@gmail.com on 22 Dec 2009 at 1:46

GoogleCodeExporter commented 9 years ago
ok, downloaded and installed today:

DarkIce 0.20.1 live audio streamer, http://code.google.com/p/darkice/
Copyright (c) 2000-2007, Tyrell Hungary, http://tyrell.hu/
Copyright (c) 2008-2009, Akos Maroy and Rafael Diniz

Using config file: /etc/darkice/darkice.cfg
Using JACK audio server as input device.
Using POSIX real-time scheduling, priority 98
Registering as JACK client darkice-4271

start command: screen -l -d -m /usr/local/bin/darkice -c 
/etc/darkice/darkice.cfg

there is also `rotter` running in the background

Original comment by marcel.hecko@gmail.com on 22 Dec 2009 at 10:18

GoogleCodeExporter commented 9 years ago
crashed today in the morning again with the same message : 

failed to write to ring ruffer
failed to write to ring ruffer
failed to write to ring ruffer
failed to write to ring ruffer
failed to write to ring ruffer
failed to write to ring ruffer
failed to write to ring ruffer
failed to write to ring ruffer
failed to write to ring ruffer
failed to write to ring ruffer
failed to write to ring ruffer
failed to write to ring ruffer
failed to write to ring ruffer
failed to write to ring ruffer
failed to write to ring ruffer
failed to write to ring ruffer
failed to write to ring ruffer
failed to write to ring ruffer

Original comment by marcel.hecko@gmail.com on 28 Dec 2009 at 9:55

GoogleCodeExporter commented 9 years ago
still crashing, can this possibly be caused by older kernel?
Linux streamer 2.6.20-16-generic #2 SMP Tue Feb 12 02:11:24 UTC 2008 x86_64 
GNU/Linux
standard kernel from Ubuntu Feisty

/usr/local/bin/jackd -Z -v -d oss -r 44100 -p 4096 -w 16 -i 2

`rotter` works perfectly fine

Original comment by marcel.hecko@gmail.com on 14 Jan 2010 at 11:46

GoogleCodeExporter commented 9 years ago
It would be good to shutdown darkice when this problem occurs? It helps to 
restart stream via scripts.

Original comment by timpur...@gmail.com on 24 Jan 2010 at 3:54

GoogleCodeExporter commented 9 years ago
that's what I do right now - restart darkice every time the problem occurs, 
however
this is not a solution since it interrupts the radio stream - not good at all

btw also occuring with the SVN version on Ubuntu 9.10

again - `rotter` works splendidly well

marcel

Original comment by marcel.hecko@gmail.com on 24 Jan 2010 at 4:51

GoogleCodeExporter commented 9 years ago
I experienced the same. (I'm not using darkice that often)

I think it's the realtime priority. It doesn't make sense to give the encoder a
higher priority than jackd, because this way, the encoder might block jackd from
running and fetching data from the soundcard which would finally lead to a 
buffer
underrun in darkice.

I'll file a ticket to make the realtime priority configurable. Jackd normally 
runs at
RTPRIO 15 in SCHED_FIFO, so make darkice use 10 or something like this. Right 
now, 98
(which is RTPRIO_MAX - 1) surely is wrong.

If you want to give it a whirl right now, change DarkIce.cpp:1120 from

   param.sched_priority = high_priority - 1;

to

   param.sched_priority = 10;

(and report back if this solves your problem)

HTH

PS: I assume you're running jackd with realtime prios.

Original comment by a...@drcomp.erfurt.thur.de on 16 May 2010 at 6:58

GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
Check the comments and proposed patch in issue 21. For jackd users, there's 
usually
no need to set the new rtprio config item, it's only important to have the 
encoder
using a lower priority than the jackd client thread. (that's the thread who's 
getting
the input data from jackd)

HTH

Original comment by a...@drcomp.erfurt.thur.de on 16 May 2010 at 7:57

GoogleCodeExporter commented 9 years ago
this works...so far with today's checkout

Original comment by marcel.hecko@gmail.com on 1 Jun 2010 at 11:25

GoogleCodeExporter commented 9 years ago
I took a look in the patch, and it seems ok.
Do you confirm it's working ok?

Original comment by rafael2k...@gmail.com on 19 Jul 2010 at 8:25

GoogleCodeExporter commented 9 years ago
I just applied it.
Can I close this issue?

Original comment by rafael2k...@gmail.com on 19 Jul 2010 at 8:56

GoogleCodeExporter commented 9 years ago
Yes, this issue can be closed.

Original comment by marcel.hecko@gmail.com on 19 Jul 2010 at 9:22

GoogleCodeExporter commented 9 years ago
This solution doesn't work for me...

No way to use darkice 0.20, it shows me "failed to write to ring ruffer" after 
less than an hour.

I tried to compile 1.0 from sources, but nothing to do, same error...

Any Solution?

Original comment by overshoo...@gmail.com on 30 Sep 2010 at 7:21

GoogleCodeExporter commented 9 years ago
Got the same problem, I downloaded the patch and darkice1.0 source, patched it, 
compiled, everything is fine, darkice connects to my icecast2 server and jack, 
but after a few seconds it shows "failed to write to ring ruffer". I run debian 
6.0.1 and got jackd1, also i'm quite new, so i'm probably doing something 
wrong. Any ideas?

Original comment by unbuffoc...@gmail.com on 1 Apr 2011 at 3:31