[linux-audio-user] jackd --realtime eats my memory.

From: Jan Holst Jensen <jhje00@email-addr-hidden>
Date: Sat Feb 26 2005 - 23:04:35 EET

Hi.

Being quite a newbie to audio on Linux, I am trying to
get rid of xruns when I record using ardour and jackd.
I start jackd with
 
  jackd -d alsa --device hw:1 --rate 44100 --period
8192 --nperiods 2

but this max. buffer size is still not enough to
completely prevent xruns. I see xruns often when I
switch between windows and so thought that this is
caused by Xfree86 stealing CPU from jackd, since
xfree86 runs with nice factor -10.

I tried to run jackd as root so I could use the
"--realtime" option but my system is then sadly
reduced to a thrashing heap of rubble.

After loading a recorded session (approx. 45 minutes
of audio - 830 MB data) "top" tells me that

  ardour is using 69.5 %MEM
  jackd is using 25.6 %MEM

and the loading of the session has taken several
minutes due to thrashing (kswapd is on heavy work here
according to "top"). The system is very unresponsive
and I am unable to use ardour for anything useful.

If I don't use the "--realtime" option, "top" says

  ardour is using 20.4 %MEM
  jackd is using 2.1 %MEM

after the session is loaded (in 2-3 seconds), and the
system runs quite well (except for the occasional
xruns of course).

Is "--realtime" forcing jackd and its clients to lock
all of their memory in RAM ? I would then need quite a
lot of RAM to use the "--realtime" option. Is it
really necessary to use _that_ much RAM ?

I also tried to renice jackd with -20 so it runs with
priority 0. Will the "--realtime" option give me
better stability than the renicing ?

Cheers

-- Jan Holst Jensen, Copenhagen, Denmark

____________________________

System info:

Debian Sarge with a custom-built unpatched kernel
2.6.10. Kernel config includes "Pre-emptible kernel"
and pure ALSA - no OSS emulation.

Compaq Evo N400C laptop. 700 MHz Pentium III with 128
MB RAM. I know this is not top-of-the-pops but I have
used it for two years to do stereo recording and
8-track mixing on Windows 2000 quite nicely.

jackd version:

  bonham:~# jackd --version
  jackd version 0.99.0 tmpdir /dev/shm protocol 13
  bonham:~#

                
__________________________________
Do you Yahoo!?
Yahoo! Mail - Helps protect you from nasty viruses.
http://promotions.yahoo.com/new_mail
Received on Sun Feb 27 00:15:15 2005

This archive was generated by hypermail 2.1.8 : Sun Feb 27 2005 - 00:15:16 EET