regular xrun on ardour 2.8.7 ubuntu 8.04 64 bit

19 replies [Last post]
ben280
User offline. Last seen 8 weeks 23 hours ago. Offline
Joined: 2010-01-25
Posts:

hello,
i have regular xrun on my computer when i use ardour. I think it's a problem on my hard disk (i use a western digital velociraptor)... when i do "lspci -v" i have this (the bios configure in raid):

00:1f.2 RAID bus controller: Intel Corporation 82801 SATA RAID Controller
Subsystem: ASUSTeK Computer Inc. Unknown device 82d4
Flags: bus master, 66MHz, medium devsel, latency 0, IRQ 508
I/O ports at bc00 [size=8]
I/O ports at b880 [size=4]
I/O ports at b800 [size=8]
I/O ports at b480 [size=4]
I/O ports at b400 [size=32]
Memory at fbffe800 (32-bit, non-prefetchable) [size=2K]
Capabilities: [80] Message Signalled Interrupts: Mask- 64bit- Queue=0/4 Enable+
Capabilities: [70] Power Management version 3
Capabilities: [a8] #12 [0010]
Capabilities: [b0] Vendor Specific Information

i see "latency 0", i think this is the problem.
What can do for change this ?

thank you

benjamin

motherboard Asus P5Q
Quadcore 2.6ghz
8 go ram
harddisk seagate (for my system)
harddisk western digital (for my sound project in ardour)
i have modified the file limits.conf...

peder
User offline. Last seen 49 weeks 3 days ago. Offline
Joined: 2007-05-08
Posts:

...and added your user to the audio group and logged out and in again?

I really doubt it's the disk. What kind of soundcard do you use?
If it's a built-in Intel you can try changing Jacks Periods/Buffer to 3

Also, which version of Jack are you using? The one in 8.04 is oooold.

ben280
User offline. Last seen 8 weeks 23 hours ago. Offline
Joined: 2010-01-25
Posts:

yes! my user is in audio group... I install ubuntu 9.10 (2.6.31-9-rt) and i have the problem too... I have a rme hammerfall hdsp 96/52... Actually, i use the 0.3.6 version of jack. I can't change Periods/Buffer to 3 i have error... and it's an intel.

peder
User offline. Last seen 49 weeks 3 days ago. Offline
Joined: 2007-05-08
Posts:

The Hammerfall shouldn't need P/B=3. And 0.3.6 is the version of QjackCtl not Jack (run ' jackd --version' in a terminal) but if you installed 9.10 you should have a fairly recent one.

With that CPU, soundcard and kernel you should be able to run jack at more or less zero latency without xruns...

Did you check the Realtime box in QjackCtl and set the value to ,say, 70 ?
What does your .jackdrc contain?

paul
paul's picture
User offline. Last seen 15 hours 26 min ago. Offline
Joined: 2006-03-16
Posts:

There is almost never any reason to set the realtime *priority* value. Please leave it alone.

ben280
User offline. Last seen 8 weeks 23 hours ago. Offline
Joined: 2010-01-25
Posts:

hello,
thank you for your attention,

when i install jack 1.9.5 i do this:

/waf configure --prefix=/usr

Linux detected
Checking for program g++ : ok /usr/bin/g++
Checking for compiler version : ok 4.4.1
Checking for program cpp : ok /usr/bin/cpp
Checking for program ar : ok /usr/bin/ar
Checking for program ranlib : ok /usr/bin/ranlib
Checking for g++ : ok
Checking for program gcc : ok /usr/bin/gcc
Checking for compiler version : ok 4.4.1
Checking for program ar : ok /usr/bin/ar
Checking for program ranlib : ok /usr/bin/ranlib
Checking for gcc : ok
Checking for header samplerate.h : ok
Checking for alsa >= 1.0.18 : ok
Checking for libfreebob >= 1.0.0 : ok
Checking for libffado >= 1.999.17 : ok
Checking for header sndfile.h : ok
Checking for header samplerate.h : ok
Checking for celt >= 0.5.0 : ok
Checking for header ncurses.h : ok
Checking for library readline : ok
Checking for celt >= 0.7.0 : ok
JACK 1.9.5 exported from r3909
Build with a maximum of 64 JACK clients
Build with a maximum of 768 ports per application
Install prefix : /usr
Library directory : /usr/lib
Drivers directory : /usr/lib/jack
Build debuggable binaries : no
Build doxygen documentation : no
Build with engine profiling : no
Build with 32/64 bits mixed mode : no
Build standard JACK (jackd) : yes
Build D-Bus JACK (jackdbus) : no
Build with ALSA support : yes
Build with FireWire (FreeBob) support : yes
Build with FireWire (FFADO) support : yes

Configuration finished successfully (00:00:01); project is now ready to build.

and this

./waf
he says
Compilation finished successfully (00:00:17)

and after i do this

sudo ./waf install
he says
Compilation and installation finished successfully (00:00:00)

Normally no problem... When i run "jackd --version"

jackd --version
jackdmp 1.9.5
Copyright 2001-2005 Paul Davis and others.
Copyright 2004-2009 Grame.
jackdmp comes with ABSOLUTELY NO WARRANTY
This is free software, and you are welcome to redistribute it
under certain conditions; see the file COPYING for details
no message buffer overruns
no message buffer overruns
jackdmp version 1.9.5 tmpdir /dev/shm protocol 7

my rtprio in the file limits.conf is 80 and in jack is 79.

For the file .jackdrc :

/usr/bin/jackd -R -P79 -p512 -dalsa -r48000 -p1024 -n2 -D -Chw:0,0 -Phw:0,0

my period is 1024 because if is 128 (for example) i open a big session of ardour (100 tracks...), when i want record i have xrun...

thanks

benjamin

thorgal
User offline. Last seen 1 year 21 weeks ago. Offline
Joined: 2007-08-03
Posts:

salut ben280,

go to your home directory and check again:


cd ~
cat .jackdrc

be careful to add the dot . just before jackdrc. A filename starting with a dot is interpreted in unix as being that of a so-called "hidden" file.

about your rtprio config, why 80 and 79 respectively ? jack does not need to run at an RT prio so close to the limit. I believe I have my limits set to 99 in limits.conf and 70 for jack. There are a few other things that need to run at a higher prio above jack's process thread. You should probably listen to Paul in this matter, since he developed jack in the first place :)

ben280
User offline. Last seen 8 weeks 23 hours ago. Offline
Joined: 2010-01-25
Posts:

hi thorgal,

my jackdrc (i change rtprio...):

/usr/bin/jackd -R -P70 -p512 -dalsa -r48000 -p1024 -n2 -D -Chw:0,0 -Phw:0,0

but the probleme is ever here...

thorgal
User offline. Last seen 1 year 21 weeks ago. Offline
Joined: 2007-08-03
Posts:

note that it won't probably change much but I would rephrase your jackd command:


/usr/bin/jackd -R -P70 -p512 -dalsa -dhw:0 -r48000 -p1024 -n2

do you need that many ports by the way (-p512) ? (just curious, it should not affect anything)

Anyway, don't start jack from qjackctl, run the command above from the therminal.
When you open a big ardour session, run htop in another terminal and see if your CPU is having hard time.

ben280
User offline. Last seen 8 weeks 23 hours ago. Offline
Joined: 2010-01-25
Posts:

I copy your jackd command and I paste in my jackd command ?
I use many ports (512 is good...)
What is the command for run jack in terminal ?
thanks

thorgal
User offline. Last seen 1 year 21 weeks ago. Offline
Joined: 2007-08-03
Posts:

I did not say you should paste anything in the jackdrc file (if this is what you did) but run

/usr/bin/jackd -R -P70 -p512 -dalsa -dhw:0 -r48000 -p1024 -n2

from the terminal. Moreover, if you changed /etc/security/limits.conf with a new rtprio limit (99), make sure you log out and in again for the change to take effect.

ben280
User offline. Last seen 8 weeks 23 hours ago. Offline
Joined: 2010-01-25
Posts:

ok i understand !

when i run /usr/bin/jackd -R -P70 -p512 -dalsa -dhw:0 -r48000 -p1024 -n2 no problem (but i have 42.7ms latency...)

bousquet@bousquet-desktop:~$ /usr/bin/jackd -R -P70 -p512 -dalsa -dhw:1 -r48000 -p1024 -n2
jackdmp 1.9.5
Copyright 2001-2005 Paul Davis and others.
Copyright 2004-2009 Grame.
jackdmp comes with ABSOLUTELY NO WARRANTY
This is free software, and you are welcome to redistribute it
under certain conditions; see the file COPYING for details
no message buffer overruns
no message buffer overruns
JACK server starting in realtime mode with priority 70
Cannot lock down memory area (Cannot allocate memory)
creating alsa driver ... hw:1|hw:1|1024|2|48000|0|0|nomon|swmeter|-|32bit
Using ALSA driver H-DSP running on card 1 - RME Hammerfall HDSP 9652 at 0xfebf0000, irq 17
configuring for 48000Hz, period = 1024 frames (21.3 ms), buffer = 2 periods
ALSA: final selected sample format for capture: 32bit integer little-endian
ALSA: use 2 periods for capture
ALSA: final selected sample format for playback: 32bit integer little-endian
ALSA: use 2 periods for playback

Is it normal this information ?: "Cannot lock down memory area (Cannot allocate memory)"

but when i run /usr/bin/jackd -R -P70 -p512 -dalsa -dhw:0 -r48000 -p128 -n2 i have xrun when i record track...

thorgal
User offline. Last seen 1 year 21 weeks ago. Offline
Joined: 2007-08-03
Posts:

just a question: wasn't the semantic of the -R option to jackd reversed ? i.e. if you add it, you run in NON-realtime mode ?

to be sure, run


jackd --help

The help message should tell you whether this is the case.

paul
paul's picture
User offline. Last seen 15 hours 26 min ago. Offline
Joined: 2006-03-16
Posts:

@thorgal: the meaning of -R never changed. However, it is now on by default, and if a user wants non-realtime mode, they need to use -r.

thorgal
User offline. Last seen 1 year 21 weeks ago. Offline
Joined: 2007-08-03
Posts:

ah! OK :)

ben280
User offline. Last seen 8 weeks 23 hours ago. Offline
Joined: 2010-01-25
Posts:

and this message "Cannot lock down memory area (Cannot allocate memory)" when i run jack it's a problem?

thorgal
User offline. Last seen 1 year 21 weeks ago. Offline
Joined: 2007-08-03
Posts:

how much RAM do you have and what's your memlock limit in /etc/security/limits.conf ?

ben280
User offline. Last seen 8 weeks 23 hours ago. Offline
Joined: 2010-01-25
Posts:

i have 8 go ram in my computer and in the file limits.conf i have 500000 for the ram

When i use ardour 2.8.7 and start jack with in the terminal i see "Cannot lock down memory area" and when i want record in my project there are xrun.

I see on htop at the first xrun my CPU4 it's 100%...

ben280
User offline. Last seen 8 weeks 23 hours ago. Offline
Joined: 2010-01-25
Posts:

i have a solution. In the bios of asus I make "disable" in "APIC ACPI support" and i have no xrun when i run ardour... but i have one cpu and not four in my system monitor...

josh24
User offline. Last seen 3 years 40 weeks ago. Offline
Joined: 2010-07-13
Posts:

I use ardour too and also notice many problems on my hard disk, any help would be very much appreciated, thanks!
how to get a girl to like you